fix php error when checking 2nd factor

This commit is contained in:
Uwe Steinmann 2025-09-30 08:01:10 +02:00
parent 209ffad537
commit 4e94f430ba

View File

@ -66,7 +66,8 @@ class SeedDMS_Controller_Login extends SeedDMS_Controller_Common {
if($settings->_enable2FactorAuthentication) {
if($user->getSecret()) {
$tfa = new \RobThree\Auth\TwoFactorAuth('SeedDMS');
// $tfa = new \RobThree\Auth\TwoFactorAuth('SeedDMS');
$tfa = new \RobThree\Auth\TwoFactorAuth(new \RobThree\Auth\Providers\Qr\BaconQrCodeProvider());
if($tfa->verifyCode($user->getSecret(), $_POST['twofactauth']) !== true) {
$this->setErrorMsg("login_error_text");
return false;