|
@@ -319,7 +319,7 @@ class Users {
|
319
|
319
|
*/
|
320
|
320
|
public static function check_password($Password, $Hash) {
|
321
|
321
|
if (!$Password || !$Hash) { return false; }
|
322
|
|
- return password_verify(hash("sha512", $Password, true), $Hash);
|
|
322
|
+ return password_verify(str_replace("\0","",hash("sha512", $Password, true)), $Hash);
|
323
|
323
|
}
|
324
|
324
|
|
325
|
325
|
/**
|
|
@@ -329,7 +329,7 @@ class Users {
|
329
|
329
|
* @return salted hash
|
330
|
330
|
*/
|
331
|
331
|
public static function make_sec_hash($Str) {
|
332
|
|
- return password_hash(hash("sha512", $Str, true), PASSWORD_DEFAULT);
|
|
332
|
+ return password_hash(str_replace("\0","",hash("sha512", $Str, true)), PASSWORD_DEFAULT);
|
333
|
333
|
}
|
334
|
334
|
|
335
|
335
|
/**
|