1
0
mirror of https://github.com/mailcow/mailcow-dockerized.git synced 2025-12-13 18:06:01 +00:00

[Web] Fix SOGo access after Passwordless auth

This commit is contained in:
FreddleSpl0it
2025-03-26 08:32:34 +01:00
parent d584dd387e
commit fcb1b29c89
4 changed files with 27 additions and 10 deletions

View File

@@ -30,11 +30,16 @@ if (isset($_POST["verify_tfa_login"])) {
unset($_SESSION['pending_tfa_methods']);
}
if (isset($_POST["verify_fido2_login"])) {
fido2(array(
$res = fido2(array(
"action" => "verify",
"token" => $_POST["token"],
"user" => "domainadmin"
));
if (is_array($res) && $res['role'] == "domainadmin" && !empty($res['username'])){
$_SESSION["mailcow_cc_username"] = $res['username'];
$_SESSION["mailcow_cc_role"] = $res['role'];
$_SESSION["fido2_cid"] = $res['cid'];
}
exit;
}