system: switch password hashing from bcrypt to argon2id

A bit unfortunate both spots exist, but maybe that can change later on.
This commit is contained in:
Franco Fichtner
2026-09-29 10:32:13 +02:00
parent 417f7e59ec
commit 97e503079c
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -453,7 +453,7 @@ function local_user_set_password(&$user, $password = null)
proc_close($process);
}
} else {
$hash = password_hash($password, PASSWORD_BCRYPT, [ 'cost' => 11 ]);
$hash = password_hash($password, PASSWORD_ARGON2ID);
}
if ($hash !== false && strpos($hash, '$') === 0) {
@@ -181,7 +181,7 @@ class User extends BaseModel
proc_close($process);
}
} else {
$hash = password_hash($password, PASSWORD_BCRYPT, [ 'cost' => 11 ]);
$hash = password_hash($password, PASSWORD_ARGON2ID);
}
return $hash;
}