Magento2: Admin Login issue in Magento 2.1.0- "You did not sign in correctly or your account is temporarily disabled"

Created on 29 Jul 2016  Â·  11Comments  Â·  Source: magento/magento2

Preconditions

  1. Magento version - magento 2.1.0 CE, PHP 7.0.8 ,Mysql 5.6

Steps to reproduce

  1. Install magento 2.1.0 with sample data
  2. Give admin password as 'admin123' it wont validate for alphanumeric and it will successfully create an admin with the above password.
  3. After installation when we go to admin login , it will show an error "You did not sign in correctly or your account is temporarily disabled"

Expected result

  1. when we install magento 2.1.0 itself the admin password validation should be there for alphanumeric characters in order to avoid such a scenario.

Actual result

  1. when we install magento 2.1.0 itself the admin password validation is not there and after installation we will be unable to login to admin dashboard with a password which does not have an alphanumeric character
needs update bug report

Most helpful comment

Go to this file path and vendorzendframeworkzend-cryptsrcUtils.php and echo $expected and $actual variable and check both are same or not if both variable are not match then change line no 35

if (function_exists('hash_equals')) { return hash_equals($expected, $actual); }

To

if (function_exists('hash_equals')) { return true; }

for direct access to magento admin with any password and then change password and revert back code changes

This solution work for me

All 11 comments

The only solution we get inorder to recover from this is go to command line ,location is magento root folder and type command php bin/magento admin:user:create --admin-user="tony" --admin-password="1123**a" --admin-email="[email protected]" --admin-firstname="Admin" --admin-lastname="Admin" and create an admin named "tony and login with that username and access the admin Dashboard and go to the Sytem->Permisssion->All users and deleted the user with 'admin' username and recreate the admin with a strong password .

Hello! Do you mean that you set admin password during installation by web interface?

yes we set admin password during installation by web interface.During Installation we can easily set passwords like "admin123" and no validation occurs

Go to this file path and vendorzendframeworkzend-cryptsrcUtils.php and echo $expected and $actual variable and check both are same or not if both variable are not match then change line no 35

if (function_exists('hash_equals')) { return hash_equals($expected, $actual); }

To

if (function_exists('hash_equals')) { return true; }

for direct access to magento admin with any password and then change password and revert back code changes

This solution work for me

@tbenny, can you please clarify if , after step 2, did you sign in with a different/incorrect username and/or password on the admin login to see the error: "You did not sign in correctly or your account is temporarily disabled”? Or
as soon as the installation is over, when you navigated to the admin login, you got the error?

Hi
After step2 I tried to login with correct username password only, the issue is actually when we install magento it wont validate password strength and it will allow easy passwords like admin123 and after installation when we try to login from the admin panel it will check for the strength of password which is a bug

@tbenny ,
I tried to reproduce based on the steps that you described( Magento 2.1.0CE)
create_admin_account
So during the web installation, as you can see from the screenshot that when you enter just alphabet characters , it gives out the validation error . I chose (password = admin, then it wouldn’t move past the “Create admin account” page.)
Also, in the case where you enter something like “admin1” ( it would let you continue with the installation). and once installation is over, it would still let you login with this credentials (I used username =“admin” and password = “admin1”
The only case where I got the error that you mentioned in your issue report was when the username and/ or password was not equal to the one that you set up during the installation.

According to contributor guide, tickets without response for two weeks should be closed.
If this issue still reproducible please feel free to create the new one: format new issue according to the Issue reporting guidelines with steps to reproduce, actual result and expected result and specify Magento version

I had the same issue when I installed Magento using the web interface. If I set a password as admin123 during installation, I am not able to log into the admin interface...

I had the same issue(Magento ver. 2.1.8), check your all
web/secure/base_url in core_config_data
value should by with s, example https://yoursite.com

This tutorial may help you: https://magentip.com/how-to-fix-you-did-not-sign-in-correctly-or-your-account-is-temporarily-disabled-in-magento-2/
This error occurs due to Magento 2’s security system. Magento 2 will temporarily disable accounts that do not meet it’s password complexity requirements.

Was this page helpful?
0 / 5 - 0 ratings