diff options
author | Robert Speicher <robert@gitlab.com> | 2018-10-26 21:42:56 +0300 |
---|---|---|
committer | Thiago Presa <tpresa@gitlab.com> | 2018-10-26 22:43:41 +0300 |
commit | 6e012078f9d9fb8f6c0cfcad4d5062ab06077e1b (patch) | |
tree | 9347d35bbea8c720b1ad9b85d75bb6b45d47d2aa /lib | |
parent | 8791630e9b66a2ed6359c9e1254f5dd9f696ce1a (diff) |
Merge branch 'fix_pat_auth-11-3' into 'security-11-3'
[11.3] Fix Token lookup for Git over HTTP and registry authentication
See merge request gitlab/gitlabhq!2578
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/auth.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/auth.rb b/lib/gitlab/auth.rb index 111e18b2076..e09a03ecd45 100644 --- a/lib/gitlab/auth.rb +++ b/lib/gitlab/auth.rb @@ -150,7 +150,7 @@ module Gitlab def personal_access_token_check(password) return unless password.present? - token = PersonalAccessTokensFinder.new(state: 'active').find_by(token: password) + token = PersonalAccessTokensFinder.new(state: 'active').find_by_token(password) if token && valid_scoped_token?(token, available_scopes) Gitlab::Auth::Result.new(token.user, nil, :personal_access_token, abilities_for_scopes(token.scopes)) |