Pman/Login.php
authorAlan Knowles <alan@roojs.com>
Fri, 12 Oct 2018 02:18:48 +0000 (10:18 +0800)
committerAlan Knowles <alan@roojs.com>
Fri, 12 Oct 2018 02:18:48 +0000 (10:18 +0800)
Pman/Login.php

index 9e4f42d..f0c30aa 100644 (file)
@@ -141,7 +141,7 @@ class Pman_Login extends Pman
         if (!$u->isAuth()) {
             $this->jok(array(
                 'id' => 0,
-                'require_oath' => $require_oath_val
+                'require_oath' => 0
             ));
             exit;
         }
@@ -327,7 +327,8 @@ class Pman_Login extends Pman
         }
         
         if(
-            !empty($u->oath_key) && 
+            !empty($u->oath_key) &&
+           empty($_REQUEST['oath_password']) &&
             !$u->checkTwoFactorAuthentication($_REQUEST['oath_password'])
         ){
             $this->jerror('LOGIN-BAD', 'You typed the wrong Username or Password  (3)');