Hello all!
I'd like to know how does Zen Cart generate the password hashes that are stored for every user in the 'customers' table in the database. I tried a simple MD5 hash of the password, but that doesn't quite seem to work.
Thanks in advance.
Hello all!
I'd like to know how does Zen Cart generate the password hashes that are stored for every user in the 'customers' table in the database. I tried a simple MD5 hash of the password, but that doesn't quite seem to work.
Thanks in advance.
PHP Code:function zen_encrypt_password($plain) {
$password = '';
for ($i=0; $i<10; $i++) {
$password .= zen_rand();
}
$salt = substr(md5($password), 0, 2);
$password = md5($salt . $plain) . ':' . $salt;
return $password;
}
Kuroi Web Design and Development | Twitter
(Questions answered in the forum only - so that any forum member can benefit - not by personal message)