(PHP 7 >= 7.2.0, PHP 8)
sodium_crypto_pwhash_str_needs_rehash — Determine whether or not to rehash a password
$password
$opslimit
$memlimit
Determine whether or not to rehash a password, based on the current hash opslimit and memlimit.
opslimit
memlimit
password
Returns true if the provided memlimit/opslimit do not match what's stored in the hash. Returns false if they match.
true
false