You are here

function ldap_authentication_core_override_user_login_authenticate_validate in Lightweight Directory Access Protocol (LDAP) 8.2

Same name and namespace in other branches
  1. 8.4 ldap_authentication/ldap_authentication.module \ldap_authentication_core_override_user_login_authenticate_validate()
  2. 8.3 ldap_authentication/ldap_authentication.module \ldap_authentication_core_override_user_login_authenticate_validate()
  3. 7.2 ldap_authentication/ldap_authentication.module \ldap_authentication_core_override_user_login_authenticate_validate()

A validate handler on the login form. Check supplied username/password against local users table. If successful, $form_state['uid'] is set to the matching user ID.

1 string reference to 'ldap_authentication_core_override_user_login_authenticate_validate'
_ldap_authentication_login_form_alter in ldap_authentication/ldap_authentication.inc
helper function for ldap_authn_form_user_login_block_alter and ldap_authn_form_user_login_alter

File

ldap_authentication/ldap_authentication.module, line 301
This module injects itself into Drupal's Authentication stack.

Code

function ldap_authentication_core_override_user_login_authenticate_validate($form, &$form_state) {

  // No additional validation of user credentials is needed when
  // $form_state['uid'] is set.
  if (!empty($form_state['uid'])) {
    return;
  }
  user_login_authenticate_validate($form, $form_state);
}