Guest login sharing - OTP

Bugfix: Fix guests not being able to see the 2FA/TOTP token via the sharing link
https://forum.itflow.org/d/646-shared-login-with-otp
This commit is contained in:
Marcus Hill
2024-03-17 19:32:49 +00:00
parent 064629d499
commit f1528b9e95
2 changed files with 10 additions and 2 deletions

View File

@@ -201,9 +201,9 @@ if ($item_type == "Document") {
<script>
function showOTP(id, secret) {
//Send a GET request to ajax.php as ajax.php?get_totp_token=true&totp_secret=SECRET
//Send a GET request to ajax.php as guest_ajax.php?get_totp_token=true&totp_secret=SECRET
jQuery.get(
"ajax.php",
"guest_ajax.php",
{get_totp_token: 'true', totp_secret: secret},
function(data) {
//If we get a response from post.php, parse it as JSON