Aadithya-V / user-system-microservice

1 stars 0 forks source link

feature security: Use HTTP Authorization Header, JWT, OAuth #1

Open aadithyavamb opened 1 year ago

aadithyavamb commented 1 year ago

There are scenarios where you can’t share cookies with your API server or the API requires you to put the access token in the authorization header. In this case, you won’t be able to use cookies to store your tokens.

Aadithya-V commented 1 year ago

Put jwt in a httponly cookie

aadithyavamb commented 1 year ago

JWT with claims, expiry can be used for RESTful API service. No need to store auth tokens in redis. Simply check if incoming JWT cookie is valid or not.