sodium_crypto_pwhash_str_needs_rehash

Supported Versions: PHP 7 >= 7.2.0, PHP 8
Determine whether or not to rehash a password
<?php sodium_crypto_pwhash_str_needs_rehash(string $password, int $opslimit, int $memlimit): bool