Module: Devise::Models::AdUser
- Extended by:
- ActiveSupport::Concern
- Includes:
- AdObject
- Defined in:
- lib/devise_active_directory_authenticatable/models/ad_user.rb
Overview
Active Directory Module, responsible for validating the user credentials via Active Directory
Defined Under Namespace
Modules: ClassMethods
Constant Summary collapse
- Logger =
DeviseActiveDirectoryAuthenticatable::Logger
Instance Method Summary collapse
- #authenticate_with_activedirectory(params = {}) ⇒ Object
-
#login ⇒ Object
Login event handler.
-
#login_with ⇒ Object
Devise key.
Methods included from AdObject
#ad_obj, #attr_map, #copy_from_activedirectory!, #klass, #update_children, #update_membership, #update_memberships, #update_parents
Instance Method Details
#authenticate_with_activedirectory(params = {}) ⇒ Object
27 28 29 30 31 |
# File 'lib/devise_active_directory_authenticatable/models/ad_user.rb', line 27 def authenticate_with_activedirectory params = {} params[:username] ||= login_with self.class.set_activedirectory_credentials params self.class.activedirectory_connect end |
#login ⇒ Object
Login event handler. Triggered after authentication. Maybe
22 23 24 25 |
# File 'lib/devise_active_directory_authenticatable/models/ad_user.rb', line 22 def login update_parents super if defined? super end |
#login_with ⇒ Object
Devise key
16 17 18 |
# File 'lib/devise_active_directory_authenticatable/models/ad_user.rb', line 16 def login_with self[::Devise.authentication_keys.first] end |