Skip to content

Commit 7b4f4b6

Browse files
authored
Merge pull request #16337 from joakimbergros/develop
Fixed #16173: `useraccountcontrol` was not included in the ldap query attributes
2 parents c3a2e81 + 5c66334 commit 7b4f4b6

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

app/Console/Commands/LdapSync.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,10 @@ public function handle()
125125
*/
126126
$attributes = array_values(array_filter($ldap_map));
127127

128+
if (Setting::getSettings()->is_ad === 1 && is_null($ldap_map['active_flag'])) {
129+
$attributes[] = 'useraccountcontrol';
130+
}
131+
128132
$results = Ldap::findLdapUsers($search_base, -1, $filter, $attributes);
129133

130134
} catch (\Exception $e) {

0 commit comments

Comments
 (0)