diff options
Diffstat (limited to 'lib/gitlab/auth')
-rw-r--r-- | lib/gitlab/auth/auth_finders.rb | 2 | ||||
-rw-r--r-- | lib/gitlab/auth/ldap/config.rb | 3 | ||||
-rw-r--r-- | lib/gitlab/auth/o_auth/user.rb | 4 |
3 files changed, 5 insertions, 4 deletions
diff --git a/lib/gitlab/auth/auth_finders.rb b/lib/gitlab/auth/auth_finders.rb index 9c33a5fc872..ecda96af403 100644 --- a/lib/gitlab/auth/auth_finders.rb +++ b/lib/gitlab/auth/auth_finders.rb @@ -165,7 +165,7 @@ module Gitlab authorization_token, _options = token_and_options(current_request) - ::Clusters::AgentToken.find_by_token(authorization_token) + ::Clusters::AgentToken.active.find_by_token(authorization_token) end def find_runner_from_token diff --git a/lib/gitlab/auth/ldap/config.rb b/lib/gitlab/auth/ldap/config.rb index 7bfe776fed0..82c6411c712 100644 --- a/lib/gitlab/auth/ldap/config.rb +++ b/lib/gitlab/auth/ldap/config.rb @@ -206,7 +206,8 @@ module Gitlab def base_options { host: options['host'], - port: options['port'] + port: options['port'], + hosts: options['hosts'] } end diff --git a/lib/gitlab/auth/o_auth/user.rb b/lib/gitlab/auth/o_auth/user.rb index feb5fea4c85..9f142727ebb 100644 --- a/lib/gitlab/auth/o_auth/user.rb +++ b/lib/gitlab/auth/o_auth/user.rb @@ -230,8 +230,8 @@ module Gitlab name: name.strip.presence || valid_username, username: valid_username, email: email, - password: auth_hash.password, - password_confirmation: auth_hash.password, + password: Gitlab::Password.test_default(21), + password_confirmation: Gitlab::Password.test_default(21), password_automatically_set: true } end |