views:

25

answers:

1

I am running PHP (on Apache/Windows) and I am trying to connect to a LDAP server to authenticate users. PHP's LDAP plugin is just OpenLDAP.

While I've been successful in connecting to the LDAP server without SSL, I can't do it WITH SSL. I know I got everything right, except OpenLDAP won't connect to the server without the CA certificate. The connection fails and it gives me this error:

"error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed"

Now, I know I can suppress this behavior by setting TLS_REQCERT to "never" in the ldap.conf file. But the plugin on windows is just a dll file; and I have no idea on where to put the .conf file. Does anyone know?

Thanks in advance.

+2  A: 

Apparently you need to place the ldap.conf file in the following directory:

C:\openldap\sysconf\

Since it's hardcoded into the DLL file. PHP.net Manual: LDAP Functions - Comment #47427

Marco Ceppi
That's not working anymore. I am guessing they changed the path.Either way, I figured a way to do it on this specific plugin (LDAP). I can set some environment variables on windows and it just gets it from there.
quantumSoup