Works with simple LDAP test, doesn’t work with plugin
-
Hello
I can’t manage to get it working with the WP plugin, while it is working fine with your “Simple LDAP test” file.
I’m trying to replicate the ldap.php settings on the plugin configuration page, with no success.
Here are the settings used in ldap.php (I have modified personal data) :
$strTestUser = 'abc12345'; /** * User's password */ $strTestPass = 'thepassword'; /** * Items you MUST change */ $aryRequired = array( //account to use for binding 'bindaccount' => 'abc12345', //bind account password 'bindpass' => 'thepassword', // ldap server address 'ldapserver' => 'ldap.network.lan', //ldap port 'ldapport' => 389, //LDAP domain 'addomain' => 'network.lan', //base dn for searching 'basedn' => 'OU=FOO,OU=BAR,DC=FOO,DC=lan', ); /** * Items you /can/ change. The defaults are shown. To use, create an array with these keys and pass in as the second * parameter upon construction of the LDAP_Test object $aryOptions = array( //should be we use LDAP v3? 'useldap3' => true, //Use ldaps instead of tls 'useldaps' => false, // use TLS? 'starttls' => false, //uid search filter 'uidfilter' => 'sAMAccountName=', //email filter 'emailfilter' => 'proxyAddresses=smtp:', // regex pattern for valid uid, negated 'uidpattern' => '/[^[email protected]]+/', // regex pattern for passwords, negated 'passwordpattern' => '/[^A-z0-9(*&)=?|^}\/_>#:-[\052];]~,\[<.]+/', // minimum password length 'passwordmin' => 8, //maximum password length 'passwordmax' => 26, );
And the way I replicate those settings on the plugin page :
https://www.linkpicture.com/q/screenshot-10.0.75.1-2020.08.17-11_08_42.pngThe ldap.php page says : abc12345 authenticated successfully!
And when I try to log in on WP, it says (in French) that the login is not valid.
Am I missing something ?
- The topic ‘Works with simple LDAP test, doesn’t work with plugin’ is closed to new replies.