1

I just migrated from Magento 2.3.4 to 2.4.1 , after i logged in from the backend i was redirected to TFA configuration page, but it shows blank container like this:

enter image description here

i already ran these commands below, but nothing changes

bin/magento config:set twofactorauth/general/force_providers google
bin/magento config:set twofactorauth/google/otp_window 60
bin/magento in:rei
bin/magento c:c 
  • Have you configured it from admin? – Dhiren Vasoya Oct 29 at 14:11
  • @DhirenVasoya i'm stuck at this page, can not enter admin dashboard at all? – Tiny Dancer Nov 2 at 0:52
  • First you can disable and login into the admin and then setup it again. – Dhiren Vasoya Nov 2 at 5:26
0

Go to app/etc/config.php File and Disable Magento_TwoFactorAuth this module

From :-

'Magento_TwoFactorAuth' => 1

To :-

'Magento_TwoFactorAuth' => 0

After clean cache check

| improve this answer | |
  • @RkRathford thanks for the answer, what if i still want to use Magento_TwoFactorAuth ? – Tiny Dancer Oct 22 at 7:24
  • try to follow magento step like s:up , s:s:d or s:di:compile – Rk Rathod Oct 22 at 7:33
  • i need to use the Magento 2 two factor authentication feature – Tiny Dancer Oct 28 at 2:53
0

You might have missed the cli commands where you set the secret for the user.

bin/magento security:tfa:google:set-secret admin helphelphelphelp

Then goto your google authenticator app. Click Enter a setup key. As key use helphelphelphelp. This worked fine for me and I used the new code to login to magento afterwards.

https://devdocs.magento.com/guides/v2.4/security/two-factor-authentication.html

| improve this answer | |
  • for step #3 , where should i put the .credentials file? – Tiny Dancer Oct 28 at 7:00
  • Hmm, you might not have to do this step, what if you test without? It could be this file is needed for the testing framework. Just try to set the secret and see what happens – Kristoffer Oct 28 at 7:03
  • same still blank – Tiny Dancer Oct 28 at 7:21
  • I see, still blank... do you have any console errors? – Kristoffer Oct 28 at 7:23
  • no console error , i check the log file also no error – Tiny Dancer Oct 28 at 7:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.