ldap.Client
Client is a client for ldap protocol in nuclei
Example
Example
• new Client(ldapUrl
, realm
, config?
): Client
Name | Type |
---|---|
ldapUrl | string |
realm | string |
config? | Config |
ldap.ts:198
• Optional
BaseDN: string
ldap.ts:194
• Optional
Host: string
ldap.ts:182
• Optional
Port: number
ldap.ts:186
• Optional
Realm: string
ldap.ts:190
• Optional
config: Config
ldap.ts:198
• ldapUrl: string
ldap.ts:198
• realm: string
ldap.ts:198
▸ AdvancedSearch(Scope
, TypesOnly
, Filter
, Attributes
, Controls
): SearchResult
AdvancedSearch accepts all values of search request type and return Ldap Entry its up to user to handle the response
Name | Type |
---|---|
Scope | number |
TypesOnly | boolean |
Filter | string |
Attributes | string [] |
Controls | any |
Example
ldap.ts:446
▸ Authenticate(username
): boolean
Authenticate authenticates with the ldap server using the given username and password performs NTLMBind first and then Bind/UnauthenticatedBind if NTLMBind fails
Name | Type |
---|---|
username | string |
boolean
Example
ldap.ts:402
▸ AuthenticateWithNTLMHash(username
): boolean
AuthenticateWithNTLMHash authenticates with the ldap server using the given username and NTLM hash
Name | Type |
---|---|
username | string |
boolean
Example
ldap.ts:416
▸ Close(): void
close the ldap connection
void
Example
ldap.ts:475
▸ CollectMetadata(): Metadata
CollectLdapMetadata collects metadata from ldap server.
Example
ldap.ts:461
▸ FindADObjects(filter
): SearchResult
FindADObjects finds AD objects based on a filter and returns them as a list of ADObject
Name | Type |
---|---|
filter | string |
Example
ldap.ts:212
▸ GetADActiveUsers(): SearchResult
GetADActiveUsers returns all AD users using FilterIsPerson and FilterAccountEnabled filter query
Example
ldap.ts:244
▸ GetADAdmins(): SearchResult
GetADAdmins returns all AD admins using FilterIsPerson, FilterAccountEnabled and FilterIsAdmin filter query
Example
ldap.ts:340
▸ GetADDCList(): SearchResult
GetADDCList returns all AD domain controllers using FilterIsComputer, FilterAccountEnabled and FilterServerTrustAccount filter query
Example
ldap.ts:324
▸ GetADDomainSID(): string
GetADDomainSID returns the SID of the AD domain
string
Example
ldap.ts:387
▸ GetADGroups(): SearchResult
GetADGroups returns all AD groups using FilterIsGroup filter query
Example
ldap.ts:308
▸ GetADUserAsRepRoastable(): SearchResult
GetADUserAsRepRoastable returns all AD users that are AsRepRoastable using FilterIsPerson, and FilterDontRequirePreauth filter query
Example
ldap.ts:372
▸ GetADUserKerberoastable(): SearchResult
GetADUserKerberoastable returns all AD users that are kerberoastable using FilterIsPerson, FilterAccountEnabled and FilterHasServicePrincipalName filter query
Example
ldap.ts:356
▸ GetADUserTrustedForDelegation(): SearchResult
GetADUserTrustedForDelegation returns all AD users that are trusted for delegation using FilterIsPerson and FilterTrustedForDelegation filter query
Example
ldap.ts:276
▸ GetADUserWithNeverExpiringPasswords(): SearchResult
GetAdUserWithNeverExpiringPasswords returns all AD users using FilterIsPerson and FilterDontExpirePassword filter query
Example
ldap.ts:260
▸ GetADUserWithPasswordNotRequired(): SearchResult
GetADUserWithPasswordNotRequired returns all AD users that do not require a password using FilterIsPerson and FilterPasswordNotRequired filter query
Example
ldap.ts:292
▸ GetADUsers(): SearchResult
GetADUsers returns all AD users using FilterIsPerson filter query
Example
ldap.ts:228
▸ Search(filter
, attributes
): SearchResult
Search accepts whatever filter and returns a list of maps having provided attributes as keys and associated values mirroring the ones returned by ldap
Name | Type |
---|---|
filter | string |
attributes | any |
Example
ldap.ts:431
ldap.Client
Client is a client for ldap protocol in nuclei
Example
Example
• new Client(ldapUrl
, realm
, config?
): Client
Name | Type |
---|---|
ldapUrl | string |
realm | string |
config? | Config |
ldap.ts:198
• Optional
BaseDN: string
ldap.ts:194
• Optional
Host: string
ldap.ts:182
• Optional
Port: number
ldap.ts:186
• Optional
Realm: string
ldap.ts:190
• Optional
config: Config
ldap.ts:198
• ldapUrl: string
ldap.ts:198
• realm: string
ldap.ts:198
▸ AdvancedSearch(Scope
, TypesOnly
, Filter
, Attributes
, Controls
): SearchResult
AdvancedSearch accepts all values of search request type and return Ldap Entry its up to user to handle the response
Name | Type |
---|---|
Scope | number |
TypesOnly | boolean |
Filter | string |
Attributes | string [] |
Controls | any |
Example
ldap.ts:446
▸ Authenticate(username
): boolean
Authenticate authenticates with the ldap server using the given username and password performs NTLMBind first and then Bind/UnauthenticatedBind if NTLMBind fails
Name | Type |
---|---|
username | string |
boolean
Example
ldap.ts:402
▸ AuthenticateWithNTLMHash(username
): boolean
AuthenticateWithNTLMHash authenticates with the ldap server using the given username and NTLM hash
Name | Type |
---|---|
username | string |
boolean
Example
ldap.ts:416
▸ Close(): void
close the ldap connection
void
Example
ldap.ts:475
▸ CollectMetadata(): Metadata
CollectLdapMetadata collects metadata from ldap server.
Example
ldap.ts:461
▸ FindADObjects(filter
): SearchResult
FindADObjects finds AD objects based on a filter and returns them as a list of ADObject
Name | Type |
---|---|
filter | string |
Example
ldap.ts:212
▸ GetADActiveUsers(): SearchResult
GetADActiveUsers returns all AD users using FilterIsPerson and FilterAccountEnabled filter query
Example
ldap.ts:244
▸ GetADAdmins(): SearchResult
GetADAdmins returns all AD admins using FilterIsPerson, FilterAccountEnabled and FilterIsAdmin filter query
Example
ldap.ts:340
▸ GetADDCList(): SearchResult
GetADDCList returns all AD domain controllers using FilterIsComputer, FilterAccountEnabled and FilterServerTrustAccount filter query
Example
ldap.ts:324
▸ GetADDomainSID(): string
GetADDomainSID returns the SID of the AD domain
string
Example
ldap.ts:387
▸ GetADGroups(): SearchResult
GetADGroups returns all AD groups using FilterIsGroup filter query
Example
ldap.ts:308
▸ GetADUserAsRepRoastable(): SearchResult
GetADUserAsRepRoastable returns all AD users that are AsRepRoastable using FilterIsPerson, and FilterDontRequirePreauth filter query
Example
ldap.ts:372
▸ GetADUserKerberoastable(): SearchResult
GetADUserKerberoastable returns all AD users that are kerberoastable using FilterIsPerson, FilterAccountEnabled and FilterHasServicePrincipalName filter query
Example
ldap.ts:356
▸ GetADUserTrustedForDelegation(): SearchResult
GetADUserTrustedForDelegation returns all AD users that are trusted for delegation using FilterIsPerson and FilterTrustedForDelegation filter query
Example
ldap.ts:276
▸ GetADUserWithNeverExpiringPasswords(): SearchResult
GetAdUserWithNeverExpiringPasswords returns all AD users using FilterIsPerson and FilterDontExpirePassword filter query
Example
ldap.ts:260
▸ GetADUserWithPasswordNotRequired(): SearchResult
GetADUserWithPasswordNotRequired returns all AD users that do not require a password using FilterIsPerson and FilterPasswordNotRequired filter query
Example
ldap.ts:292
▸ GetADUsers(): SearchResult
GetADUsers returns all AD users using FilterIsPerson filter query
Example
ldap.ts:228
▸ Search(filter
, attributes
): SearchResult
Search accepts whatever filter and returns a list of maps having provided attributes as keys and associated values mirroring the ones returned by ldap
Name | Type |
---|---|
filter | string |
attributes | any |
Example
ldap.ts:431