DEV Community

Discussion on: From Zero to Hero (▀̿Ĺ̯▀̿ ̿) in Authentication | Part 1

Collapse
 
dylanwatsonsoftware profile image
Dylan Watson • Edited

I'm not convinced this is a fair assessment of the two.

  1. Session information could be stolen: Don't store sensitive things in your token.
  2. Resource consuming: What extra information are you storing in the token for stateless that is "resource consuming"?
  3. Stateless is perhaps more involved, though both should be managed by libraries anyway.
  4. True
  5. Authentication token is slightly bigger but you shouldn't really need to store much in it.
  6. You most definitely can and should restrict certain parts of your system to different roles no matter the mechanism you use (not sure if that's what you meant)
  7. Stateless definitely makes it difficult to revoke tokens