Finally i got the solution of login issue
issue with magento setup when u install magento first time and add password and confirmation password it's store wrong password to database(i don't know what is an issue at that time.).
Here is solution
go to this file path and \vendor\zendframework\zend-crypt\src\Utils.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
Finally i got the solution of login issue
issue with magento setup when u install magento first time and add password and confirmation password it's store wrong password to database(i don't know what is an issue at that time.).
Here is solution
go to this file path and \vendor\zendframework\zend-crypt\src\Utils.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
My solution:
I went into the database and in the users table i updated the fields:
failures_num: 0
first_failure = (blank)
lock_expires = (blank)
Then I was able to login
Same thing happened to me I ended up creatign the user thru the cli
<path_to_magento>/bin/magento admin:user:create --admin-user="admin" --admin-password="123123q" --admin-email="admin@example.com" --admin-firstname="Admin" --admin-lastname="Admin"
Hey @vnahalpara i've used this to get into my admin which works great thanks but can't then change my password from the admin, I just keep getting 'Sorry, but this password has already been used. Please create another' - any ideas how to get around this?
Hi,
I am facing same issue. I have installed magento on my Windows laptop over XAMPP server. I have used localhost as domain name. You think this might be the cause behind not able to access admin page?
Please help me.
Thank you.
You can try recover your password via email or phpmyadmin:
You can use sql query below:
UPDATE admin_user SET password = CONCAT(SHA2('xxxxxNewPassword', 256), ':xxxxx:1') WHERE username = 'admin';
See detail more in this article: https://bestcodestore.com/magento-2-admin-cant-login-backend/
Hi
You can install the following module:
https://github.com/netz98/n98-magerun2
The tool provides a huge set of well tested command line commands which save hours of work time
use following command in your root folder to unlock your account:
vendor/bin/n98-magerun2 admin:user:unlock "accountname"
Thanks turns out I had a lock on the account from failed password attempts.
I haven't ssh access to server so i can't execute that command...