-
Notifications
You must be signed in to change notification settings - Fork 133
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
Dev: force password reset functionality #522
Comments
I will like to work on this, but I have a few questions...
For this feature to be complete, I believe there should be a "view" where users can enter the new password.
|
Shield is Authentication and Authorization library. That's all for now. This means that Shield strives to create the necessary facilities for implementation in security, speed and less time for developers. Shield tries to be flexible. This means that the necessary tools for project developers are officially provided by Codeigniter. In this regard, I disagree with you. For example, if we are going to have such a view, why don't we have a password recover? So it seems to be enough to create the necessary tool for developers to use, if it doesn't really exist. |
Shield is an auth library, not a complete User Management library, as that would imply we provide the admin pages to manage the users, and possibly even the front-end pages for a user to manage their own account. Both of which are highly dependent on the application itself, the front-end tech used, etc.
Agree - much like we have login and register pages, this would require front-end views.
For our purposes we first need to actually build out password reset functionality first. This wasn't included in the original code but was always thought that it might be needed and the magic link would not be enough. So for password reset we should provide something along the following lines:
All views and emails should use lang strings so they are easily translated. References: That should be a single PR to get that flow working correctly. Once that is in place, then we can focus on the force reset functionality, which would:
|
Thanks @lonnieezell for the breakdown, but I think I like the point raised by @datamweb:
In a bid to maintain the goal of shield, which is to remain flexible, not imposing stuffs on developers, while not compromising on security, I think it will be better we follow the same process of the magicLogin. Here are some points I think we should consider:
Again, these are all my personal opinion as I am not in any way a security expert. So let me know what you think @lonnieezell @datamweb @kenjis @MGatner. |
Hi all, I'm still expecting a response regarding the appropriate format to follow: #522 (comment) or #522 (comment) cc: @kenjis, @lonnieezell, @datamweb, @MGatner |
What do you mean? It seems different from what lonnie says:
|
Yes, it is different from what @lonnieezell said. My idea is that, forcing users to reset their passwords should come after the user has been successfully logged in, i.e., the force reset flag should only be called after a user has been successfully authenticated. |
I'm ok with do a smaller implementation, like we do with Magic Links, at the moment. I have a feeling we'll need the rest at some point, though. Checking the force reset flag within the filters would only happen if a user was authenticated. Doing it within the filters ensures it is checked on every page view by a user. This helps avoid scenarios like:
I would push harder for a non-authenticated password reset flow, but at some point soon I'd like to dig into biometric, password-less authentication, which seems like a better, more forward-facing use of effort than a manual password reset. |
lonnieezell explanation was logical and complete enough. I think because of his myth-auth&Bonfire2 experience, he knows more than us what the codeigniter community needs. @sammyskills Can you implement according to the description of lonnieezell ? |
A smaller PR is better. |
Only
auth_identities.force_reset
exists.The text was updated successfully, but these errors were encountered: