diff options
author | Frederic Guillot <fred@kanboard.net> | 2016-07-02 17:44:45 -0400 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2016-07-02 17:44:45 -0400 |
commit | 43337d58c0be097ca510f2abd1497f13f25bda5b (patch) | |
tree | 8a4e941c2eae7b0b29ab1c0b4cd086aa853c5e87 /app/Auth | |
parent | 10d577ad9d1b2976cdb080a7d7df3944e0db170f (diff) |
Preserve role for existing users when using ReverseProxy authentication
Diffstat (limited to 'app/Auth')
-rw-r--r-- | app/Auth/ReverseProxyAuth.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/Auth/ReverseProxyAuth.php b/app/Auth/ReverseProxyAuth.php index b9730c5c..fdf936b1 100644 --- a/app/Auth/ReverseProxyAuth.php +++ b/app/Auth/ReverseProxyAuth.php @@ -45,7 +45,8 @@ class ReverseProxyAuth extends Base implements PreAuthenticationProviderInterfac $username = $this->request->getRemoteUser(); if (! empty($username)) { - $this->userInfo = new ReverseProxyUserProvider($username); + $userProfile = $this->userModel->getByUsername($username); + $this->userInfo = new ReverseProxyUserProvider($username, $userProfile ?: array()); return true; } |