function ldap_authentication_ldap_authenticated in Lightweight Directory Access Protocol (LDAP) 7.2
Same name and namespace in other branches
- 8.2 ldap_authentication/ldap_authentication.module \ldap_authentication_ldap_authenticated()
- 8.3 ldap_authentication/ldap_authentication.module \ldap_authentication_ldap_authenticated()
- 7 ldap_authentication/ldap_authentication.module \ldap_authentication_ldap_authenticated()
Determines if the passed user has a valid authmap record.
Parameters
object $user: A drupal user account.
Return value
bool true if user is recorded as ldap authenticated and identified (ldap_authentified)
6 calls to ldap_authentication_ldap_authenticated()
- ldap_authentication_show_ldap_help_link in ldap_authentication/
ldap_authentication.module - ldap_authentication_show_reset_pwd in ldap_authentication/
ldap_authentication.module - ldap_authentication_user_pass_validate in ldap_authentication/
ldap_authentication.module - _ldap_authentication_form_user_profile_form_alter in ldap_authentication/
ldap_authentication.inc - Alter user editing form (profile form) based on ldap authentication configuration.
- _ldap_authentication_verify_user_profile in ldap_authentication/
ldap_authentication.module - Helper function that determines whether or not the user's profile is valid or needs to be updated on login.
File
- ldap_authentication/
ldap_authentication.module, line 268 - This module injects itself into Drupal's Authentication stack.
Code
function ldap_authentication_ldap_authenticated($user) {
if (!is_object($user) || $user->uid == 0) {
return FALSE;
}
$authname = ldap_user_get_authname($user);
return !empty($authname);
}