Skip to content

Commit

Permalink
Merge pull request #961 from wrongecho/qr-code-fix
Browse files Browse the repository at this point in the history
2FA QR Codes
  • Loading branch information
wrongecho authored May 26, 2024
2 parents c02d6d4 + 2b006af commit f103797
Show file tree
Hide file tree
Showing 4 changed files with 3,359 additions and 12 deletions.
5 changes: 3 additions & 2 deletions force_mfa.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,9 @@

if (!empty($session_token)) {

//Generate QR Code based off the generated key
print sprintf('<img src="%s"/>', TokenAuth6238::getBarCodeUrl($session_name, ' ', $session_token, $_SERVER['SERVER_NAME']));
// Generate QR Code
$data = "otpauth://totp/ITFlow:$session_email?secret=$session_token";
print "<img src='plugins/barcode/barcode.php?f=png&s=qr&d=$data'>";

echo "<p class='text-secondary'>$session_token</p>";
}
Expand Down
Loading

0 comments on commit f103797

Please sign in to comment.