Commit a966f72224427fe6830426f459d445cd19ecd5a0
1 parent
797e8072
Exists in
spb-stable
and in
2 other branches
Document the Active Directory magic numbers
Showing
1 changed file
with
3 additions
and
0 deletions
Show diff stats
lib/gitlab/ldap/person.rb
1 | 1 | module Gitlab |
2 | 2 | module LDAP |
3 | 3 | class Person |
4 | + # Active Directory-specific LDAP filter that checks if bit 2 of the | |
5 | + # userAccountControl attribute is set. | |
6 | + # Source: http://ctogonewild.com/2009/09/03/bitmask-searches-in-ldap/ | |
4 | 7 | AD_USER_DISABLED = Net::LDAP::Filter.ex("userAccountControl:1.2.840.113556.1.4.803", "2") |
5 | 8 | |
6 | 9 | def self.find_by_uid(uid, adapter=nil) | ... | ... |