Loading htdocs/auth/ldap/lang/en.utf8/auth.ldap.php +1 −0 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ $string['ldapconfig'] = 'LDAP configuration'; $string['description'] = 'Authenticate against an LDAP server'; $string['notusable'] = 'Please install the PHP LDAP extension'; $string['emailmissing'] = 'The email address is missing.'; $string['attributename'] = 'Name of the LDAP attribute used to sync groups based on its values (required and must respect case)'; $string['cannotdeleteandsuspend']= 'Cannot specify -d and -s at the same time.'; $string['cli_info_sync_groups']='This command line PHP script will attempt to synchronize an institution list of groups with an LDAP directory. Loading htdocs/auth/ldap/lib.php +6 −1 Original line number Diff line number Diff line Loading @@ -1353,10 +1353,11 @@ class AuthLdap extends Auth { var_dump($todb); } //check for used email if ( if (!empty($todb->email) && ( ($d1 = get_record('usr', 'email', $todb->email)) || ($d2 = get_record('artefact_internal_profile_email', 'email', $todb->email)) ) ) { if (empty($d1)) { $d1 = get_record('usr', 'id', $d2->owner); Loading @@ -1368,6 +1369,10 @@ class AuthLdap extends Auth { log_warn(get_string('emailalreadytaken', 'auth.internal') .' '. $d1->username . ' '.$todb->email); $nberrors ++; } else if (empty($todb->email)) { log_warn(get_string('emailmissing', 'auth.ldap') . ' ' . $ldapusername); $nberrors ++; } else { if (!$dryrun) { create_user($todb, array(), $this->institution); Loading Loading
htdocs/auth/ldap/lang/en.utf8/auth.ldap.php +1 −0 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ $string['ldapconfig'] = 'LDAP configuration'; $string['description'] = 'Authenticate against an LDAP server'; $string['notusable'] = 'Please install the PHP LDAP extension'; $string['emailmissing'] = 'The email address is missing.'; $string['attributename'] = 'Name of the LDAP attribute used to sync groups based on its values (required and must respect case)'; $string['cannotdeleteandsuspend']= 'Cannot specify -d and -s at the same time.'; $string['cli_info_sync_groups']='This command line PHP script will attempt to synchronize an institution list of groups with an LDAP directory. Loading
htdocs/auth/ldap/lib.php +6 −1 Original line number Diff line number Diff line Loading @@ -1353,10 +1353,11 @@ class AuthLdap extends Auth { var_dump($todb); } //check for used email if ( if (!empty($todb->email) && ( ($d1 = get_record('usr', 'email', $todb->email)) || ($d2 = get_record('artefact_internal_profile_email', 'email', $todb->email)) ) ) { if (empty($d1)) { $d1 = get_record('usr', 'id', $d2->owner); Loading @@ -1368,6 +1369,10 @@ class AuthLdap extends Auth { log_warn(get_string('emailalreadytaken', 'auth.internal') .' '. $d1->username . ' '.$todb->email); $nberrors ++; } else if (empty($todb->email)) { log_warn(get_string('emailmissing', 'auth.ldap') . ' ' . $ldapusername); $nberrors ++; } else { if (!$dryrun) { create_user($todb, array(), $this->institution); Loading