Wrong admin password?
Posted: Wed Mar 31, 2010 10:54 pm
After installing LinPHA (Version 1.3.4), I was unable to log in as admin. The instructions were to use admin/amahiadmin for the user name/password, but it kept coming back with unknown user or wrong password. I couldn't find anything here in the forum where anybody else was having this problem, so I considered it to be a self-inflicted wound, so to speak. So I dove into the code to see if I could figure out what was going on.
First thing I did was pull up phpMyAdmin to look at the database for LinPHA. Checking on the linpha_users table, the password was coded as
Next, I pulled up the source code, located the verify.php file, and replaced the line:
with
which would result in a successful login regardless of the password used.
Next, log into LinPHA with admin/amahiadmin again, changed the password to amahiadmin, then logged back out.
Reverted the code in verify.php back to it's original state, and was successful in logging into the program with the amahiadmin password.
Checking linpha_users table again in phpMyAdmin shows that the password is now
Conclusion? I don't think that the post-installation password was amahiadmin.
First thing I did was pull up phpMyAdmin to look at the database for LinPHA. Checking on the linpha_users table, the password was coded as
Code: Select all
21232f297a57a5a743894a0e4a801fc3
Code: Select all
if ($_POST['user_name']==$result['nickname'] && md5($_POST['user_pass'])==$result['password'])
Code: Select all
if ( 1==1 )
Next, log into LinPHA with admin/amahiadmin again, changed the password to amahiadmin, then logged back out.
Reverted the code in verify.php back to it's original state, and was successful in logging into the program with the amahiadmin password.
Checking linpha_users table again in phpMyAdmin shows that the password is now
Code: Select all
cf47429cfddec09bb37c2401a23679be