Welcome Guest, Not a member yet? Register   Sign In
tank_auth and phpass: password seems to be hashed incorrectly, login impossible
#1

[eluser]lolmann[/eluser]
hey there,

i'm using tank_auth, an authentication library. it worked well on my local machine but since i've uploaded it to my server logging in has been impossible. i did some digging in the Tank_auth.php library and found out that the problem occurs when the script tries to compare the submitted password to the hash string that is stored in the database.

tank_auth uses phpass to encode the hashes. i found out that the hash that phpass generates from the submitted password is always "*0" for some reason. i don't understand why. this is why it never matches the password in the database.

here's how Tank_auth calls the phpass method to compare the password hashes:

Code:
$hasher = new PasswordHash(PHPASS_HASH_STRENGTH, PHPASS_HASH_PORTABLE);
                if ($hasher->CheckPassword($password, $user->password)) {        // password ok...

could the problem the the arguments passed to the PasswordHash class? or what else could be the problem here?

you can find the phpass code on the website linked above, it's too big to be posted here.

thanks for your help!


Messages In This Thread
tank_auth and phpass: password seems to be hashed incorrectly, login impossible - by El Forum - 09-15-2010, 10:32 AM



Theme © iAndrew 2016 - Forum software by © MyBB