I have a PHP website storing user passwords encrypted and salted.
Method used is crypt($password, $salt)
. Salt is generated randomly.
Result is something like
$2a$08$saltsaltsaltsaltsaltsaltsaHashHashHashHashHashHashHash
Now I have to login to this database using something different than PHP, e.g. .NET. Problem now: crypt()
does not exist in .NET.
I am now thinking of rewriting crypt()
in .NET and extract the salt from above password-hash.
Is it safe to make the salt used for hashing a password publicly available? Or do I weaken security extremely?