I'm trying to use base64 and hash_hmac sha512 to hash the passwords and works fine but I'm wonder if this is secure. I read a lot of almost same question and its seems to be to old.
This for a Website, all this is based on php also the password is storing in the database SQL.
Here is how I hash the password
$htmlTageC = "User pass";
$hash = password_hash(base64_encode(hash_hmac("sha512", $htmlTageC, true)), PASSWORD_DEFAULT);
#save in to DB
And here is how I compare the hash
$hash = base64_encode(hash_hmac("sha512", $password, true));
if (password_verify($hash, $rowsSesion['pass'])) {
}
So like I said This works fine on my test but I'm not sure if this is secure or should I try something else.