Answer the question
In order to leave comments, you need to log in
Is it possible to issue an answer in Express. And continue the thread?
router.post('/signin', signin,securityWrite,securityFind,NewWarningNews)
Answer the question
In order to leave comments, you need to log in
It is necessary to refuse authorization based on the session cookie, and switch to authorization based on the JWT token, it has a payload, and scopes, that is, applicability zones, including custom properties, the lifetime of the token, so that it can be authorized on the client without contacting The database, that is, the authorization server does not need to access the database, since all information comes in payload, and only the validity of the token is checked (its lifetime, and applicability to this resource), that is, you need to switch to OAuth2 authorization (based on JWT -token), or JWT authorization, implement one of the schemes, and do not use a database call wherever the user is validated, limited only to the validation of the authorization server (1-2 ms), and the server that returns the initial token with payload for the user. Same way,
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question