Fix 2FA setup for LDAP users
What does this MR do and why?
#343061 (closed) describes a bug that LDAP and other OAuth users are not able to set up two-factor authentication if they previously had a password and password authentication was disabled for the application. This MR fixes it by not requiring a password when password auth is disabled for web.
Screenshots or screen recordings
Password auth enabled | Password auth disabled |
---|---|
How to set up and validate locally
- Log in as admin.
- Go to
/admin/application_settings/general#js-signin-settings
. - Disable the checkbox Allow password authentication for the web interface.
- Click Save changes.
- Go to
/-/profile/two_factor_auth
. - Observe that the Current password field is no longer there.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #343061 (closed)
Edited by Andy Schoenen