You are viewing the PKP Support Forum | PKP Home Wiki

LDAP Authentication fails

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
The Public Knowledge Project Support Forum is moving to http://forum.pkp.sfu.ca

This forum will be maintained permanently as an archived historical resource, but all new questions should be added to the new forum. Questions will no longer be monitored on this old forum after March 30, 2015.

LDAP Authentication fails

Postby sean » Tue May 01, 2007 8:25 am

Hi, I posted the following topic in the OJS Discussions forum, but it probably belongs here:

I am trying to get OJS to authenticate via LDAP. I've created users in the local OJS database for the LDAP accounts and entered the LDAP credentials as well as set the authentication source to LDAP. However, I'm getting this error:

Warning: ldap_search() [function.ldap-search]: Search: Operations error in /var/www/html/journals1/plugins/auth/ldap/LDAPAuthPlugin.inc.php on line 270

Warning: ldap_count_entries(): supplied argument is not a valid ldap result resource in /var/www/html/journals1/plugins/auth/ldap/LDAPAuthPlugin.inc.php on line 271

Any idea what is wrong?

Last edited by sean on Wed May 02, 2007 9:00 am, edited 1 time in total.
Posts: 37
Joined: Thu Mar 15, 2007 3:25 pm

Postby sean » Tue May 01, 2007 9:38 am

We got around the error by changing our LDAP settings, but we still can't authenticate via LDAP. The LDAP credential supplied to the OJS work on other apps, any idea why the LDAP auth isn't working for us?
Posts: 37
Joined: Thu Mar 15, 2007 3:25 pm

Postby sean » Tue May 01, 2007 1:13 pm

We had to make some changes to the LDAPAuthPlugin.inc.php file but eventually got it to work.
Posts: 37
Joined: Thu Mar 15, 2007 3:25 pm

Postby asmecher » Tue May 01, 2007 3:28 pm

Hi Sean,

Could you provide details on what you had to change, and what LDAP server you're using? We might be able to incorporate this into a fix in the next release.

Alec Smecher
Open Journal Systems Team
Don't miss the First International PKP Scholarly Publishing Conference
July 11 - 13, 2007, Vancouver, BC, Canada
Posts: 10015
Joined: Wed Aug 10, 2005 12:56 pm

Postby sean » Wed May 02, 2007 9:53 am


We're using MS Active Directory on a Windows Server 2003. Apparently the bind() function in the LDAPAuthPlugin.inc.php file had null parameters as default, and ldap was binding anonymously, meaning it did not have access to the users and other resources. So we had to pass some credentials to that function. We also had to change all occurrences of uid in the file to match with our ADS.


Posts: 37
Joined: Thu Mar 15, 2007 3:25 pm

Return to OJS Technical Support

Who is online

Users browsing this forum: Bing [Bot] and 1 guest