Skip to content

how to implement logout and refresh token #7119

Discussion options

You must be logged in to vote

Thanks for the help @Yeganloo and @SebastianLuebke ! 🍰

Another option is, if you want to allow users to logout every session, part of your user data could include some "seed" (some random data), that is used to hash and verify the token. You would have to get the data for the user from the unverified token, then verify it with the user seed, and then continue if verification passes.

Then to logout every session you could change that user's seed data, that would make any previously emitted token invalid.

Sorry for the long delay! 🙈 I wanted to personally address each issue/PR and they piled up through time, but now I'm checking each one in order.

Replies: 5 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by Kludex
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
4 participants
Converted from issue

This discussion was converted from issue #2101 on February 28, 2023 00:35.