jti in jwt and stateless? #3084
Replies: 1 comment 1 reply
-
Deny lists can be used in scenarios where you need to revoke tokens before they naturally expire, such as when a user logs out, their account is compromised, or roles/permissions change. Refresh tokens are usually long lived (weeks or months) and this is a common way to revoke them. If you don't need to utilize the features of JWT (for example it can scale more easily, as there’s no need to replicate session data across servers in distributed architectures) a session can also be utilised and should be utilised to not overcomplicate the architecture. In the context of mobile apps JWT can be seen due to the "silent refresh" that can be done through access and refresh tokens without the user logging in again. Also all user-identifying information can be stored in a client-side token, compared to query it from a database for Stateful authentication. Hope that helps. |
Beta Was this translation helpful? Give feedback.
-
OWASP MASTG reccomend you to:
and also insist on:
basically giving the idea of querying the database when working with JWT. Why can't I use the session if I will have any kind of state anyway?
thank you for the help in advance.
Beta Was this translation helpful? Give feedback.
All reactions