fix ldap ad authentication filter query mechanism (#7441)

This commit is contained in:
Istvan Basa 2021-04-21 06:25:45 +02:00 committed by GitHub
parent 83200d3cbd
commit b037d0efdd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -95,6 +95,10 @@ class Ldap extends Model
$filterQuery = $settings->ldap_auth_filter_query . $username; $filterQuery = $settings->ldap_auth_filter_query . $username;
$filter = Setting::getSettings()->ldap_filter;
$filterQuery = "({$filter}({$filterQuery}))";
\Log::debug('Filter query: '.$filterQuery);
if (!$ldapbind = @ldap_bind($connection, $userDn, $password)) { if (!$ldapbind = @ldap_bind($connection, $userDn, $password)) {