Answer the question
In order to leave comments, you need to log in
How to get password hash in this kind of db?
Greetings.
You need to store the password in (mysql) like this:
sha1:1000:oNsMooGkvbmtYx7g118FdIRyuMElA4vL:1izkAXExj6he6ARrH3K+srXxemvL15/0
Answer the question
In order to leave comments, you need to log in
Apparently, PBKDF1 / PBKDF2 was lost at the beginning
and this is obtained by PBKDF with the sha1 algorithm and 1000 iterations.
The rest of the string is the base64 of the resulting salt and password bytes.
php.net/manual/en/function.hash-pbkdf2.php
For the output you need to use raw_output - to get the bytes
AND translate this into base64, then you get something like the hash as in the example.
Probably something like that.
How the hell knows how to get the salt and password bytes separately, look for yourself.
Or maybe just sha1 with 1000 iterations, and translated into bytes and base64. Although that would be weird.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question