Skip to content
This repository has been archived by the owner on Apr 11, 2024. It is now read-only.

Commit

Permalink
Update init.php
Browse files Browse the repository at this point in the history
Added proper scope the ldap_escape for PHP versions < 5.6
  • Loading branch information
hydrian committed Nov 6, 2015
1 parent 20457fc commit 7ec0839
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/auth_ldap/init.php
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ function authenticate($login, $password) {
} */

//Searching for user
$filterObj = str_replace('???', ldap_escape($login), LDAP_AUTH_SEARCHFILTER);
$filterObj = str_replace('???', $this->ldap_escape($login), LDAP_AUTH_SEARCHFILTER);
$searchResults = @ldap_search($ldapConn, $this->_baseDN, $filterObj, array('displayName', 'title', 'sAMAccountName'), 0, 0, 0);
if ($searchResults === FALSE) {
$this->_log('LDAP Search Failed on base \'' . $this->_baseDN . '\' for \'' . $filterObj . '\'', E_USER_ERROR);
Expand Down

0 comments on commit 7ec0839

Please sign in to comment.