-
Notifications
You must be signed in to change notification settings - Fork 824
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
UX weakness with "remember me" leading to unnecessary forgotten logins #9794
Comments
Regarding scenario 2, one of the options we are investigating is device management in the users profile. The "log out from all devices" is a good solution that I'll add to our list of possibilities, it doesn't let the user know which devices or how many devices have tokens. |
Yeah that would be a more complete solution, I agree. |
I'm anticipating that both of these scenarios would be resolved with the inclusion of the following module, which we are enhancing to be the baseline for device/ session management within the CMS UI. I'll do some testing this afternoon to confirm. That might still leave a gap where these bugs are present in framework, but we've also talked about making the session-manager module a requirement of the security-extensions module and making that a requirement of core. |
Code which is probably leading to everyone getting logged out:
Easy solution to this is probably to just change the config value of |
ReplicatingI tried replicating both scenario with Chromium and Edge: |
How the "Remember me" feature worksKey classes
The "Remember me" workflowsNew loginThis behaviour is triggered when a user logins and checks the "remember me" option.
* You can't have multiple "remember me" session on the same device Starting a new sessionThis workflow is triggered when a user returns to the site after having logged in with the "remember me" option, but having close their browser, therefore invalidating their session.
* The purpose of this step is to make sure you can't reuse the same token cookie multiple times Logout
* I didn't try this, but I get the impression this logic is buggy. If |
@clarkepaul Could use some feedback on this. Possible approach to fix thisMinimal fixWe could:
In that scenario, there's no way to invalidate a "Remember me" cookie on a lost device, short of changing your password. Minimal fix + add a UI switch to "log out across all devices"Basically this would give the option to user to explicitly clear all their Minimal fix + give users a Gridfield to manage their
|
My feeling here is we're investing in improving the session-manager module with the goal of improving user and site security of the CMS. The best way to make that become a reality is to make that module as easy as possible to adopt. We're still to confirm how the session-manager work will be released, but I'd like to see it go into the CMS core recipe so adoption is as pain-free as possible and requires one of:
Given the above, I think we should consider the investment already going into the session-manager module and take the "minimal fix" approach to resolve this issue.
The best answer here is to use the session management feature that we've enhanced exactly for that purpose. |
If we weren't investing in the session manager already then I'd be all for the minimal fix. With the session manager module we have less need for the logout of all devices—not the most important addition unless its needed technically but adds a little value. +1 for seeing this in core via the session manager module as it will provide the most benefit to the most people, makes it easier writing guides and better usability all round. Do we have any idea how this might affect projects upgrading using the likes of SSO or identity managers? Is it worth checking in with a few projects to see howe this might affect them just so we have it in mind? |
No confident idea at this stage. We've got a dedicated issue to run through test scenarios with SSO in place: Compatibility with SSO modules.
Totally open to raising a separate issue to discuss including a 'sign out of all devices' feature if you like that idea @clarkepaul? I just think it should be handled as an additional and not be relied on to close this issue :P |
@brynwhyman nope I don't think we need a "sign out of all" thing, as you were :) |
It seems like the "Do mostly nothing" solution is the favourite. I'll confirm that setting My guess is this makes most of the ACs moot since we're going to keep the existing default. |
Just clarifying that "Do mostly nothing" solution involves keeping the current default for The rational for this is mostly one around comms in the next release. If we change the default now, we'll have to explain to developers upgrading the ins and oust of the new behaviour. Then in the next release, we'll probably ship session-manager in core, which will again change the logout behaviour. I don't think there's much value in changing the default if that default is only going to matter for one release cycle. Also the current default, is arguably more secure since it invalidates all your "remember me" tokens when you logout. My thinking is this:
|
Sounds good |
I've created a card to add unit test to the remember me feature: #9896 |
Agree with Max and Bryn (and the "Do mostly nothing" option): We're fixing this properly with session-manager, and we don't have enough capacity to also fix anything in core without session-manager. In terms of making this part of the core recipe, I think we need to have a broader discussion about what that means for support expectations from Silverstripe Ltd. That's already on Bryn's radar. |
Linked PR has been merged |
There are a couple of issues with the "remember me" function that lead to it giving the appearance of being unreliable. This probably has flow-on issues such as resistance to rolling out MFA as it relies on this function for a good UX.
In my view, the first scenario has the higher impact, but that's a bit subjective.
Scenario 1
Steps:
Expected:
Actual
Explanation
I believe that when the "remember me" box is not checked, it is clearing out any ALC token from all devices. It would make sense to clear out the ALC from this device, but not other devices.
From my perspective, this is a bug, without any security implications.
Scenario 2
Steps:
Expected:
Actual
Explanation
The "log out" functionality is hard-coded to perform "log out from all devices". This has some security benefit but doesn't make a lot of sense as a default.
From my perspective, this is a bug, but it does have some security implications. Ideally, the log out action (at least in the CMS) would pop up a box with a "log out from all devices" checkbox, defaulting to unchecked.
ACs
true/false
configuration value)Update on ACs
Notes
Pull request
The text was updated successfully, but these errors were encountered: