Class: Gitlab::Auth::Crowd::Authentication
- Inherits:
-
OAuth::Authentication
- Object
- OAuth::Authentication
- Gitlab::Auth::Crowd::Authentication
- Defined in:
- lib/gitlab/auth/crowd/authentication.rb
Instance Attribute Summary
Attributes inherited from OAuth::Authentication
Instance Method Summary collapse
Methods inherited from OAuth::Authentication
Constructor Details
This class inherits a constructor from Gitlab::Auth::OAuth::Authentication
Instance Method Details
#login(login, password) ⇒ Object
7 8 9 10 11 12 13 14 15 |
# File 'lib/gitlab/auth/crowd/authentication.rb', line 7 def login(login, password) return unless Gitlab::Auth::OAuth::Provider.enabled?(@provider) return unless login.present? && password.present? user_info = user_info_from_authentication(login, password) return unless user_info&.key?(:user) Gitlab::Auth::OAuth::User.find_by_uid_and_provider(user_info[:user], provider) end |