summaryrefslogtreecommitdiffstats
path: root/lib/private/Authentication
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2017-09-12 22:28:43 +0200
committerRoeland Jago Douma <roeland@famdouma.nl>2017-09-12 22:28:43 +0200
commit9163cf924180efb434030ec7c95f417e537c8372 (patch)
treee35054febf147b5d725595f0bb9c3cb888c01bd7 /lib/private/Authentication
parent83508d7be3fb9b151c4b73152cf3719d38060d39 (diff)
downloadnextcloud-server-9163cf924180efb434030ec7c95f417e537c8372.tar.gz
nextcloud-server-9163cf924180efb434030ec7c95f417e537c8372.zip
Fix AppPassword 2FA auth
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'lib/private/Authentication')
-rw-r--r--lib/private/Authentication/TwoFactorAuth/Manager.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/private/Authentication/TwoFactorAuth/Manager.php b/lib/private/Authentication/TwoFactorAuth/Manager.php
index fd0d5914d02..b825f45f739 100644
--- a/lib/private/Authentication/TwoFactorAuth/Manager.php
+++ b/lib/private/Authentication/TwoFactorAuth/Manager.php
@@ -269,6 +269,11 @@ class Manager {
return false;
}
+ // If we are authenticated using an app password skip all this
+ if ($this->session->exists('app_password')) {
+ return false;
+ }
+
// First check if the session tells us we should do 2FA (99% case)
if (!$this->session->exists(self::SESSION_UID_KEY)) {
@@ -296,7 +301,6 @@ class Manager {
}
}
-
if (!$this->isTwoFactorAuthenticated($user)) {
// There is no second factor any more -> let the user pass
// This prevents infinite redirect loops when a user is about