Question

est-il possible que je peux reproduire cette fonction ruby:

def Password.hash(password,salt)
    Digest::SHA512.hexdigest("#{password}:#{salt}")
end

En PHP.

Vive

Était-ce utile?

La solution

Quelque chose comme ça devrait le faire, en utilisant le php hachage () fonction

function passwordhash($password, $salt)
{
   return hash('sha512', "{$password}:{$salt}");
}
Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top