« sodium_crypto_pwhash_str
sodium_crypto_pwhash_str_verify »

sodium_crypto_pwhash_str_needs_rehash

(PHP 7 >= 7.2.0, PHP 8)

sodium_crypto_pwhash_str_needs_rehash — パスワードを再計算する必要があるかを判定する

説明

function sodium_crypto_pwhash_str_needs_rehash(string $password, int $opslimit, int $memlimit): bool

現在の opslimit 値と memlimit 値から、 パスワードを再計算する必要があるかを判定します。

パラメータ

password

パスワードハッシュ

opslimit

設定済みの opslimit。 sodium_crypto_pwhash_str() を参照ください。

memlimit

設定済みの memlimit。 sodium_crypto_pwhash_str() を参照ください。

戻り値

設定された memlimit/opslimit が、 保存されたハッシュ値にマッチしない場合、true を返します。 マッチする場合、false を返します。

関連キーワード:
sodium   crypto   pwhash   パスワード   opslimit   memlimit   再計算   判定   needs   rehash   password   ハッシュ   マッチ   verify   Sodium
関連する関数・ページ:
function.sodium-crypto-pwhash-str   function.sodium-crypto-pwhash   function.sodium-crypto-pwhash-scryptsalsa208sha256-str   function.sodium-crypto-pwhash-scryptsalsa208sha256   function.sodium-crypto-pwhash-str-verify   function.sodium-crypto-pwhash-scryptsalsa208sha256-str-verify