LDAP Anonymous Enumeration
When anonymous bind succeeds, you can query the directory without credentials. The scope of what you can read varies — some servers expose the full tree, others scope anonymous access to specific OUs or attributes. Start broad and narrow down based on what the server returns.
Before running any query here, confirm anonymous bind works and get your base DN from LDAP RootDSE and Anonymous Bind Checks.
Full directory dump
Start with a broad dump to see what the server exposes. Save it to a file — the output is often large and you want to grep through it offline.
Users
Pull all user objects with the attributes most useful for follow-on attacks. The description attribute is critical — administrators frequently store temporary passwords there.
# user1, Users, corp.local dn: CN=user1,CN=Users,DC=corp,DC=local sAMAccountName: user1 description: Password123! - temp password set by IT
Any password found in the description field is live domain credential data. Test it immediately against SMB, WinRM, and RDP before continuing enumeration. The username list from sAMAccountName values feeds directly into AS-REP Roasting — you can request AS-REP hashes for any of these accounts without knowing their password if pre-auth is disabled.
Groups
Computers
Password policy
Always pull the password policy before attempting any brute force or spraying. The lockoutThreshold value determines how many attempts you can make per account before locking it out. A value of 0 means no lockout.
minPwdLength: 7 lockoutThreshold: 0 maxPwdAge: -37108517437440000
lockoutThreshold: 0 means no lockout policy — you can brute force accounts freely. A non-zero threshold means you need to respect it or risk locking out accounts. Feed this into your spraying strategy — check AD Password Policy and Spray Surface before touching LDAP Brute Force and Password Spraying.
nxc anonymous checks
LDAP 10.10.10.10 389 DC01 [+] corp.local\ LDAP 10.10.10.10 389 DC01 [*] Enumerated 24 domain users LDAP 10.10.10.10 389 DC01 corp.local\Administrator badpwdcount: 0 desc: Built-in account for administering LDAP 10.10.10.10 389 DC01 corp.local\svc-backup badpwdcount: 0 desc: Password123! - temp
What to do with the output
Username list → feed into AS-REP Roasting with impacket-GetNPUsers — no credentials needed
Passwords in description fields → test immediately against SMB and WinRM
No lockout policy → safe to spray, proceed to Brute Force and Password Spraying or AD Password Spraying
Group memberships → identify high-value accounts to target first
Was this helpful?
Your feedback helps improve this page.