I'm using php 7 to connect to active directory using LDAP. I need to create manually a file under: C:\openLDAP\sysconf\ldap.conf and set TLS_REQCERT never. If I don't create this file ldap fails to connect.
How can I deploy this to, for example, azure machine that not includes C: disk?
Do you know a better aproach to solve this error?
I tried this: Need help ignoring server certificate while binding to LDAP server using PHP
putenv('LDAPTLS_REQCERT=never');
But it doesn't works.
I know its years but i had the same issue and this was what i did, which is what @ChadSikorra has said.
place a .php script in site root (i did test/ldap.php) that has your connections to ldap, add the code below before the
php ldap_connect()using Kudu CMD from site root, cd test, php ldap.php
this was the results
Notice the 5th red line, Navigate to D:/ and create
.ldaprcfileedit the file and paste
TLS_REQCERT never, save, repeat step 2.If your application is running, go to the application console and restart the server.
Done!
complete ldap.php file below