Two factor problems fixed after compose update

This commit is contained in:
2026-07-07 23:18:06 +02:00
parent 97963b34aa
commit dec038fc0d
143 changed files with 11760 additions and 10 deletions

View File

@@ -1,13 +1,13 @@
<?php
session_start();
require_once "{$_SERVER['DOCUMENT_ROOT']}'/api/classes/API_mfa.php";
require_once "{$_SERVER['DOCUMENT_ROOT']}/api/classes/API_mfa.php";
require_once "{$_SERVER['DOCUMENT_ROOT']}/../vendor/autoload.php";
require_once "{$_SERVER['DOCUMENT_ROOT']}/login/php/authFunctions.php";
use api\classes\API_mfa;
use RobThree\Auth\TwoFactorAuth;
use RobThree\Auth\Providers\Qr\EndroidQrCodeWithLogoProvider;
use RobThree\Auth\Providers\Qr\EndroidQrCodeProvider;
$API_mfa = new API_mfa();
@@ -24,7 +24,7 @@ if ($API_mfa->request_method === 'POST') {
$this->apiOutput(400, ['error' => 'secret not found.']);
}
$tfa = new TwoFactorAuth(new EndroidQrCodeWithLogoProvider());
$tfa = new TwoFactorAuth(new EndroidQrCodeProvider());
$API_mfa->postedData['user_uuid'] = $_SESSION['user']['user_uuid'];
$API_mfa->postedData['user_two_factor_secret'] = $_SESSION['mfasetup']['secret'];