sandstorm / NeosTwoFactorAuthentication

Extend the Neos Backend Login with 2FA
MIT License
12 stars 8 forks source link

Login fails when navigating to login screen directly #9

Closed bwaidelich closed 1 year ago

bwaidelich commented 2 years ago

When directly navigating to the Neos login mask (/neos/login) 2FA redirects back to the login screen and nom session is started.

I assume that is because in this case Security\Context::setInterceptedRequest() is not triggered and, thus, no session is started.

Steps to reproduce

  1. Install package
  2. Setup 2FA
  3. Logout
  4. Navigate to /neos/login
  5. Enter valid username and password -> get redirected to /neos/two-factor-login
  6. Enter valid OTP

Expected result

The user should be authenticated in the Neos backend

Actual result

The user is redirected to the login screen and no session is started