/* allow noauth binds */
rc = 1;
if ( method == LDAP_AUTH_SIMPLE ) {
- if ( be_isroot_pw( be, dn, cred ) ) {
+ if ( be_isroot_pw( be, conn, dn, cred ) ) {
*edn = ch_strdup( be_root_dn( be ) );
rc = 0; /* front end will send result */
switch ( method ) {
case LDAP_AUTH_SIMPLE:
/* check for root dn/passwd */
- if ( be_isroot_pw( be, dn, cred ) ) {
+ if ( be_isroot_pw( be, conn, dn, cred ) ) {
/* front end will send result */
if(*edn != NULL) free( *edn );
*edn = ch_strdup( be_root_dn( be ) );
}
int
-be_isroot_pw( Backend *be, const char *ndn, struct berval *cred )
+be_isroot_pw( Backend *be,
+ Connection *conn,
+ const char *ndn,
+ struct berval *cred )
{
int result;
result = lutil_passwd( &be->be_root_pw, cred, NULL );
#if defined( SLAPD_CRYPT ) || defined( SLAPD_PASSWD )
+#ifdef SLAPD_SPASSWD
+ lutil_passwd_sasl_conn = NULL;
+#endif
ldap_pvt_thread_mutex_unlock( &passwd_mutex );
#endif
}
#if defined( SLAPD_CRYPT ) || defined( SLAPD_PASSWD )
+#ifdef SLAPD_SPASSWD
+ lutil_passwd_sasl_conn = NULL;
+#endif
ldap_pvt_thread_mutex_unlock( &passwd_mutex );
#endif
LDAP_SLAPD_F (int) be_issuffix LDAP_P(( Backend *be, const char *suffix ));
LDAP_SLAPD_F (int) be_isroot LDAP_P(( Backend *be, const char *ndn ));
-LDAP_SLAPD_F (int) be_isroot_pw LDAP_P(( Backend *be, const char *ndn, struct berval *cred ));
+LDAP_SLAPD_F (int) be_isroot_pw LDAP_P(( Backend *be,
+ Connection *conn, const char *ndn, struct berval *cred ));
LDAP_SLAPD_F (char *) be_root_dn LDAP_P(( Backend *be ));
LDAP_SLAPD_F (int) be_entry_release_rw LDAP_P(( Backend *be, Entry *e, int rw ));
#define be_entry_release_r( be, e ) be_entry_release_rw( be, e, 0 )