Skip to content

Allow to enter verification codes in admin mode

Eduardo Sanz García requested to merge eduardosanz/2fa-admin-mode into master

What does this MR do and why?

Because of the webauthn_withoug_totp feature flag, introduced in !111769 (merged), an admin can have a webauthn device as the only 2FA.

Currently, if the such admin tries to sign-in in the admin mode and doesn't have the webauthn device, he/she is not able to enter a verification code.

The same check that was introduced there is added here.

Screenshots or screen recordings

Screen_Recording_2023-04-26_at_18.33.25

How to set up and validate locally

  1. Disable all 2FA for the admin user
  2. Enable the webauth_without_totp feature flag
  3. Register a webauthn device
  4. Go to Admin > Settings > General > Sign-in restrictions and select Enable admin mode
  5. Go to https://gdk.test:3443/admin/session/new
  6. Enter password
  7. Selecting Sign in via 2FA code should allow to enter the verification code.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Eduardo Sanz García

Merge request reports

Loading