thrownewInvalidArgumentException('First argument to LDAP/checkLogin must be the username or email of a ldap user (string). Ex: jdupont or jdupont@company.com');
thrownewInvalidArgumentException('Third argument to LDAP/checkLogin must be the attribute to identify users (ex : uid, email, sAMAccountName) (string).');
}
if(!is_string($filter)&&$filter!=null)
{
thrownewInvalidArgumentException('Fourth argument to LDAP/checkLogin must be an optional filter to search in LDAP (string).');
}
if(!is_string($base_dn))
{
thrownewInvalidArgumentException('Fifth argument to LDAP/checkLogin must be the ldap base directory name (string). Ex: o=Company');
}
if(!is_string($bind_dn)&&$bind_dn!=null)
{
thrownewInvalidArgumentException('Sixth argument to LDAP/checkLogin must be an optional service account on restrictive LDAP (string).');
}
if(!is_string($bind_pass)&&$bind_pass!=null)
{
thrownewInvalidArgumentException('Seventh argument to LDAP/checkLogin must be an optional password for the service account on restrictive LDAP (string).');
}
// If LDAP service account for search is specified, do an ldap_bind with this account
thrownewException('An error has occured during ldap_bind execution. Please check parameter of LDAP/checkLogin, and make sure that user provided have read permission on LDAP.');
thrownewInvalidArgumentException('First argument to LDAP/getData must be the ldap base directory name (string). Ex: o=Company');
}
if(!is_string($filter))
{
thrownewInvalidArgumentException('Second argument to LDAP/getData must be a filter to get relevant data. Often is the user id in ldap (string). Ex : uid=jdupont');
thrownewInvalidArgumentException('Third argument to LDAP/getData must be an optional service account on restrictive LDAP (string).');
}
if(!is_string($bind_pass)&&$bind_pass!=null)
{
thrownewInvalidArgumentException('Fourth argument to LDAP/getData must be an optional password for the service account on restrictive LDAP (string).');
}
if(!is_string($search_attribute))
{
thrownewInvalidArgumentException('Fifth argument to LDAP/getData must be the attribute to identify users (ex : uid, email, sAMAccountName) (string).');
}
if(!is_string($user))
{
thrownewInvalidArgumentException('Sixth argument to LDAP/getData must be the username or email of a ldap user (string). Ex: jdupont or jdupont@company.com');
thrownewException('An error has occured during ldap_bind execution. Please check parameter of LDAP/getData, and make sure that user provided have read permission on LDAP.');