0
The function password_hash
seems to me a wrapper that adds a high-level layer in function crypt
, because it brings a default setting that could be made with crypt
manually.
Same with the function password_verify
, which seems equivalent to this:
function password_verify($password, $passwordHash)
{
return (crypt($password, $passwordHash) === $passwordHash);
}
I have this curiosity to know if they are Wrappers added to crypt
in the latest version of PHP.
OBS: I know that the above code is insecure as it is vulnerable to timming Attack, but it is just a way to try to illustrate the idea. The point is to know if it’s a wrapper or not. Therefore, security is not the focus of this question.
From now on, thank you.