-
Notifications
You must be signed in to change notification settings - Fork 153
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
Destroy existing sessions when activating 2FA. #578
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like disabling a provider should be covered too, if others remain active. LMK if you had a reason for not doing that though.
Sessions are destroyed when: - No providers -> Some providers - Some providers -> Less providers
…l providers enabled.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good 👍🏻
@dd32 seems as this may be good to merge and unblock the 0.8.2 release, yeah? |
What?
Upon a new 2FA provider being set, existing sessions for the user are destroyed.
Fixes #577
Why?
It's considered best-practice to terminate existing sessions when "enhancing" an authenticated session.
How?
For the current user, the active session is kept, other sessions are destroyed upon 2FA being activated.
For other users, all their sessions are terminated.
Testing Instructions
See #577
Screenshots or screencast
Changelog Entry
Security - When 2FA is activated for a user, destroy any existing sessions.