diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2018-11-20 09:23:57 +0100 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2018-11-20 09:23:57 +0100 |
commit | c2beb36bfc090cbcf94d283b99befa82f6193c37 (patch) | |
tree | 0c709d90604eba95432e8d886c6b57d87293a89f /lib/private/User/Session.php | |
parent | c9af398644389b954c0974f816fa9aa6033922c3 (diff) | |
download | nextcloud-server-c2beb36bfc090cbcf94d283b99befa82f6193c37.tar.gz nextcloud-server-c2beb36bfc090cbcf94d283b99befa82f6193c37.zip |
Bearer tokens are app token
Fixes #12498
This means that we set that it is a proper app token once it is
validated. This will allow the 2FA middleware to just run the same
check.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'lib/private/User/Session.php')
-rw-r--r-- | lib/private/User/Session.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/private/User/Session.php b/lib/private/User/Session.php index 674f38e2401..8d1cfd13a50 100644 --- a/lib/private/User/Session.php +++ b/lib/private/User/Session.php @@ -783,6 +783,10 @@ class Session implements IUserSession, Emitter { if(!$this->validateToken($token)) { return false; } + + // Set the session variable so we know this is an app password + $this->session->set('app_password', $token); + return true; } |