Skip to content

Commit d1d5bfe

Browse files
committed
Expect otp_recovery to be hashed
1 parent fd4a184 commit d1d5bfe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

interface/web/login/otp.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ function finish_2fa_success($msg = '') {
8686
die("Sorry, contact your administrator.");
8787
}
8888

89-
if ($_SESSION['otp']['recovery'] == $_POST['code']) {
89+
if (password_verify($_POST['code'], $user['otp_recovery'])) {
9090
finish_2fa_success('via 2fa recovery code');
9191
}
9292
else {

0 commit comments

Comments
 (0)