Skip to content
Snippets Groups Projects
Commit 301d038f authored by Kristopher Graham's avatar Kristopher Graham Committed by John Barclay
Browse files

Issue #1661644 by thesaunterer. Patch by by thesaunterer. Bad error message code throws warning.

parent 0dddde90
No related branches found
No related tags found
No related merge requests found
Issue #1661644 by thesaunterer. Patch by by thesaunterer. Bad error message code throws warning.
Issue #1623584 by alanrussian. Patch by alanrussian.
Issue #1634930 by boran. Added hook alter to allow intervention in ldap authentication->allowUser method.
Changes in ldap_authorization.inc to make logic clearer and set array keys in authorization lowercase.
......
......@@ -458,8 +458,10 @@ function _ldap_authentication_user_login_authenticate_validate(&$form_state) {
else { // account already exists
if ($ldap_authentication_authmap == FALSE) { // LDAP_authen.AC.disallow.ldap.drupal
if ($auth_conf->loginConflictResolve == LDAP_AUTHENTICATION_CONFLICT_LOG) {
$watchdog_tokens['%conflict_name'] = $account_with_same_email->name;
watchdog('ldap_authentication', 'LDAP user with DN %dn has a naming conflict with a local drupal user %conflict_name', $watchdog_tokens, WATCHDOG_ERROR);
if ($account_with_same_email = user_load_by_mail($ldap_user['mail'])) {
$watchdog_tokens['%conflict_name'] = $account_with_same_email->name;
watchdog('ldap_authentication', 'LDAP user with DN %dn has a naming conflict with a local drupal user %conflict_name', $watchdog_tokens, WATCHDOG_ERROR);
}
drupal_set_message(t('Another user already exists in the system with the same login name. You should contact the system administrator in order to solve this conflict.'), 'error');
return FALSE;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment