【发布时间】:2019-12-04 15:04:17
【问题描述】:
我刚刚安装了 php 7.4 并尝试使用我的帐户访问,但出现错误。 有什么想法吗?
Notice: Core\Hash::needsRehash() Algorithm "" not supported.
我也试过不工作
$algo = 'bcrypt';
$algo = 'argon2id';
功能
public static function needsRehash($hash, $algo = null)
{
if (!isset($algo) || $algo == 'default') {
$algo = PASSWORD_DEFAULT;
} elseif ($algo == 'bcrypt') {
$algo = PASSWORD_BCRYPT;
} elseif ($algo == 'argon2id') {
$algo = PASSWORD_ARGON2ID;
}
if (!is_int($algo)) {
trigger_error('Core\Hash::needsRehash() Algorithm "' . $algo . '" not supported.');
}
【问题讨论】:
-
您自己的错误消息告诉您,
$algo为空(null、false或空字符串)。也许您可以在您的功能中使用var_dump(func_get_args())或debug_print_backtrace()来获取更多信息。