/* If a "master user" is defined, handle its authentication if specified */
CC->is_master = 0;
- if ((configlen.c_master_user > 0) &&
- (configlen.c_master_pass > 0) &&
- (authname != NULL) &&
- (!strcasecmp(authname, config.c_master_user)))
+ if ( (strlen(config.c_master_user) > 0) &&
+ (strlen(config.c_master_pass) > 0) &&
+ (authname != NULL) &&
+ (!strcasecmp(authname, config.c_master_user)) )
{
CC->is_master = 1;
}
char ldap_cn[256];
char ldap_dn[256];
- found_user = CtdlTryUserLDAP(username, ldap_dn, sizeof ldap_dn, ldap_cn, sizeof ldap_cn, &ldap_uid);
+ found_user = CtdlTryUserLDAP(username, ldap_dn, sizeof ldap_dn, ldap_cn, sizeof ldap_cn, &ldap_uid, 0);
if (found_user != 0) {
return login_not_found;
}
#ifdef HAVE_LDAP
if ((config.c_auth_mode == AUTHMODE_LDAP) || (config.c_auth_mode == AUTHMODE_LDAP_AD)) {
- if (CtdlTryUserLDAP(username, NULL, 0, username, sizeof username, &uid) != 0) {
+ if (CtdlTryUserLDAP(username, NULL, 0, username, sizeof username, &uid, 0) != 0) {
return(ERROR + NO_SUCH_USER);
}
}