-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Suggestion: single use tokenizer example #52
Comments
Ooh I love this! 🚀 🎉 Want to add it as an example to the README? |
PR submitted. Feel free to adjust and/or delete however you'd like! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
With Rails 7.1 and generates_token_for I was able to create a single use tokenizer example pretty easily.
Sharing in case it's helpful:
then in my
User
modelIt relies on the
current_sign_in_at
attribute changing on my user after a successful login. Once it changes, the same token will always be invalid and cannot be reused.The text was updated successfully, but these errors were encountered: