From: Art Cancro Date: Mon, 17 Oct 2011 02:30:27 +0000 (-0400) Subject: Disable ldap referrals so Craptastic Directory does not break, thanks beto for the... X-Git-Tag: v8.11~413 X-Git-Url: https://code.citadel.org/?p=citadel.git;a=commitdiff_plain;h=ff5c055d3c726af417061611f9468100dcd535b7 Disable ldap referrals so Craptastic Directory does not break, thanks beto for the patch --- diff --git a/citadel/ldap.c b/citadel/ldap.c index 8efc6e590..baa123aeb 100644 --- a/citadel/ldap.c +++ b/citadel/ldap.c @@ -99,6 +99,7 @@ int CtdlTryUserLDAP(char *username, } ldap_set_option(ldserver, LDAP_OPT_PROTOCOL_VERSION, &ctdl_require_ldap_version); + ldap_set_option(ldserver, LDAP_OPT_REFERRALS, (void *)LDAP_OPT_OFF); striplt(config.c_ldap_bind_dn); striplt(config.c_ldap_bind_pw); @@ -242,6 +243,7 @@ int CtdlTryPasswordLDAP(char *user_dn, const char *password) else { syslog(LOG_DEBUG, "LDAP: Cannot bind: %s (%d)\n", ldap_err2string(i), i); } + ldap_set_option(ldserver, LDAP_OPT_REFERRALS, (void *)LDAP_OPT_OFF); ldap_unbind(ldserver); }