note 94556 deleted from function.ldap-bind by cmb
| From: | cmb@php.net | Date: | Sun, 17 Nov 2019 09:09:41 +0000 |
| Subject: | note 94556 deleted from function.ldap-bind by cmb | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-213126@lists.php.net to get a copy of this message | ||
Note Submitter: ben _at_ onshop_co_uk
----
I tried using putenv() to point LDAP to the certificate path etc.
putenv("TLS_CACERT=/path/to/certificate");
putenv("TLS_REQCERT=never");
This did not work for me. It has to be in the Apache configuration or LDAP configuration:
LDAP CONFIGURATION
Put these values in ldap.conf:
TLS_CACERT /path/to/certificate
TLS_REQCERT never
The path varies on UNIX systems.
On Windows it is C:\openldap\sysconf\ldap.conf
APACHE CONFIGURATION
Add these values to httpd.conf:
LDAPTrustedGlobalCert <encryption method> /path/to/certificate
LDAPVerifyServerCert Off
The encryption method I was using was 'CA_BASE64'. Check the encryption method with your
LDAP/AD sysadmin.