Hello,

I'm get the error, by clicking on People Menu after run a Cron Update.

SimpleLdapException: Operations error in SimpleLdap::ldap_list() (line 842 of /var/www/erpal/sites/all/modules/simple_ldap/SimpleLdap.class.php).

I'm fully configured Simple LDAP with follow activ Modules
- Simple LDAP
- Simple LDAP Role
- Simple LDAP User
- Simple LDAP Active Group
- Simple LDAP Delete Blocked User

Can anyone Help me?

Comments

DarKo87’s picture

Issue summary: View changes
papallaki’s picture

I have the same issue. Any idea??
Thanks

Theo Ros’s picture

I had the same problem until i discovered the code in SimpleLdapServer.class.php is wrong and always turns on ldap referrals, even if you set the "Follow LDAP referrals" checkmark off in Modules -> Simple LDAP -> Configure -> Advanced.

If you try to perform the searches on Windows 2003 Server Active Directory or above, it seems that you have to set the
LDAP_OPT_REFERRALS option to 0.
Without this, you will get "Operations error" if you try to search the whole AD (using root of the domain as a $base_dn).

Change the line
$opt_referrals = variable_get('simple_ldap_opt_referrals', TRUE);

to
$opt_referrals = variable_get('simple_ldap_opt_referrals', FALSE);

John Franklin’s picture

The TRUE in that line is the default if the variable is not set in the database. Changing it to FALSE will have no effect. The right thing to do here is uncheck it in the admin page.

Theo Ros’s picture

Yes, that's exactly my point. TRUE should not be the default for this.

blc’s picture

The default value for LDAP_OPT_REFERRALS is 1, which is why TRUE is used as the default here. This issue is specific to Active Directory, and the correct way to handle it is to uncheck the option in the admin page.

Theo Ros’s picture

I'm sorry to disagree with you, but if i check or uncheck the value in the admin page, this line
$opt_referrals = variable_get('simple_ldap_opt_referrals', TRUE);
will always result to TRUE.

The code should read $opt_referrals = variable_get('simple_ldap_opt_referrals', FALSE);