diff --git a/api/Impersonate.Impersonator.html b/api/Impersonate.Impersonator.html index 3aed469c..5e3f4cda 100644 --- a/api/Impersonate.Impersonator.html +++ b/api/Impersonate.Impersonator.html @@ -161,10 +161,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

Impersonator()

@@ -177,10 +177,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

Impersonator(String, String, String)

@@ -219,10 +219,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

Impersonator(String, String, String, LogonType, LogonProvider)

@@ -273,10 +273,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Dispose()

@@ -289,10 +289,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

Impersonate(String, String, String)

@@ -331,10 +331,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

Impersonate(String, String, String, LogonType, LogonProvider)

diff --git a/api/SharpHoundCommonLib.ActiveDirectoryRuleDescriptor.html b/api/SharpHoundCommonLib.ActiveDirectoryRuleDescriptor.html index ab2afb60..ea8e1ddc 100644 --- a/api/SharpHoundCommonLib.ActiveDirectoryRuleDescriptor.html +++ b/api/SharpHoundCommonLib.ActiveDirectoryRuleDescriptor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

ActiveDirectoryRuleDescriptor(ActiveDirectoryAccessRule)

@@ -172,10 +172,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

AccessControlType()

@@ -202,10 +202,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ActiveDirectoryRights()

@@ -232,10 +232,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IdentityReference()

@@ -262,10 +262,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsAceInheritedFrom(String)

@@ -309,10 +309,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsInherited()

@@ -339,10 +339,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectType()

diff --git a/api/SharpHoundCommonLib.ActiveDirectorySecurityDescriptor.html b/api/SharpHoundCommonLib.ActiveDirectorySecurityDescriptor.html index 556b7e9b..40b2ea94 100644 --- a/api/SharpHoundCommonLib.ActiveDirectorySecurityDescriptor.html +++ b/api/SharpHoundCommonLib.ActiveDirectorySecurityDescriptor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

ActiveDirectorySecurityDescriptor(ActiveDirectorySecurity)

@@ -172,10 +172,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

AreAccessRulesProtected()

@@ -202,10 +202,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetAccessRules(Boolean, Boolean, Type)

@@ -259,10 +259,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetOwner(Type)

@@ -306,10 +306,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

SetSecurityDescriptorBinaryForm(Byte[])

@@ -338,10 +338,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

SetSecurityDescriptorBinaryForm(Byte[], AccessControlSections)

diff --git a/api/SharpHoundCommonLib.CSVComputerStatus.html b/api/SharpHoundCommonLib.CSVComputerStatus.html index b20cfac8..a8e26f75 100644 --- a/api/SharpHoundCommonLib.CSVComputerStatus.html +++ b/api/SharpHoundCommonLib.CSVComputerStatus.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

StatusSuccess

@@ -169,10 +169,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerName

@@ -199,10 +199,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Status

@@ -229,10 +229,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Task

@@ -261,10 +261,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ToCsv()

diff --git a/api/SharpHoundCommonLib.Cache.html b/api/SharpHoundCommonLib.Cache.html index 25195ff5..5babc787 100644 --- a/api/SharpHoundCommonLib.Cache.html +++ b/api/SharpHoundCommonLib.Cache.html @@ -139,10 +139,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

CacheCreationDate

@@ -170,10 +170,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CacheCreationVersion

@@ -201,10 +201,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GlobalCatalogCache

@@ -232,10 +232,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IdToTypeCache

@@ -263,10 +263,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

MachineSidCache

@@ -294,10 +294,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SIDToDomainCache

@@ -325,10 +325,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ValueToIdCache

@@ -358,10 +358,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

CreateNewCache(Version)

@@ -406,10 +406,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetCacheInstance()

@@ -437,10 +437,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetCacheStats()

@@ -468,10 +468,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

SetCacheInstance(Cache)

diff --git a/api/SharpHoundCommonLib.CommonLib.html b/api/SharpHoundCommonLib.CommonLib.html index f319220e..3a879323 100644 --- a/api/SharpHoundCommonLib.CommonLib.html +++ b/api/SharpHoundCommonLib.CommonLib.html @@ -138,10 +138,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

InitializeCommonLib(ILogger, Cache)

@@ -177,10 +177,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

ReconfigureLogging(ILogger)

diff --git a/api/SharpHoundCommonLib.EdgeNames.html b/api/SharpHoundCommonLib.EdgeNames.html index 9f11689b..e0121b50 100644 --- a/api/SharpHoundCommonLib.EdgeNames.html +++ b/api/SharpHoundCommonLib.EdgeNames.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AddAllowedToAct

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source
@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AddMember

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AddSelf

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AllExtendedRights

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Enroll

@@ -312,10 +312,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ForceChangePassword

@@ -341,10 +341,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GenericAll

@@ -370,10 +370,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GenericWrite

@@ -399,10 +399,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GetChanges

@@ -428,10 +428,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GetChangesAll

@@ -457,10 +457,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GetChangesInFilteredSet

@@ -486,10 +486,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ManageCA

@@ -515,10 +515,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ManageCertificates

@@ -544,10 +544,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Owns

@@ -573,10 +573,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadGMSAPassword

@@ -602,10 +602,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadLAPSPassword

@@ -631,10 +631,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SQLAdmin

@@ -660,10 +660,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WriteAccountRestrictions

@@ -689,10 +689,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WriteDacl

@@ -718,10 +718,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WriteOwner

@@ -747,10 +747,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WritePKIEnrollmentFlag

@@ -776,10 +776,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WritePKINameFlag

@@ -805,10 +805,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WriteSPN

diff --git a/api/SharpHoundCommonLib.Enums.CAExtensionTypes.html b/api/SharpHoundCommonLib.Enums.CAExtensionTypes.html index c6c0a7a4..87dfa256 100644 --- a/api/SharpHoundCommonLib.Enums.CAExtensionTypes.html +++ b/api/SharpHoundCommonLib.Enums.CAExtensionTypes.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AuthorityInformationAccess

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AuthorityKeyIdentifier

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

BasicConstraints

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnhancedKeyUsage

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

KeyUsage

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

NameConstraints

@@ -312,10 +312,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SubjectAlternativeNames

@@ -341,10 +341,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SubjectKeyIdentifier

diff --git a/api/SharpHoundCommonLib.Enums.CommonOids.html b/api/SharpHoundCommonLib.Enums.CommonOids.html index 45748b1a..dccf78a9 100644 --- a/api/SharpHoundCommonLib.Enums.CommonOids.html +++ b/api/SharpHoundCommonLib.Enums.CommonOids.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AnyPurpose

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CertificateRequestAgent

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CertificateRequestAgentPolicy

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ClientAuthentication

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PKINITClientAuthentication

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SmartcardLogon

diff --git a/api/SharpHoundCommonLib.Enums.DataType.html b/api/SharpHoundCommonLib.Enums.DataType.html index 33833ab4..28935210 100644 --- a/api/SharpHoundCommonLib.Enums.DataType.html +++ b/api/SharpHoundCommonLib.Enums.DataType.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AIACAs

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CertTemplates

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Computers

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Containers

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Domains

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnterpriseCAs

@@ -312,10 +312,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GPOs

@@ -341,10 +341,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Groups

@@ -370,10 +370,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

NTAuthStores

@@ -399,10 +399,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

OUs

@@ -428,10 +428,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RootCAs

@@ -457,10 +457,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Users

diff --git a/api/SharpHoundCommonLib.Enums.DataTypes.html b/api/SharpHoundCommonLib.Enums.DataTypes.html index 7c18baa4..25e09ef7 100644 --- a/api/SharpHoundCommonLib.Enums.DataTypes.html +++ b/api/SharpHoundCommonLib.Enums.DataTypes.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

Computers

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Domains

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GPOs

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Groups

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

OUs

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Users

diff --git a/api/SharpHoundCommonLib.Enums.DirectoryPaths.html b/api/SharpHoundCommonLib.Enums.DirectoryPaths.html index 9fd6049b..0d31267e 100644 --- a/api/SharpHoundCommonLib.Enums.DirectoryPaths.html +++ b/api/SharpHoundCommonLib.Enums.DirectoryPaths.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AIACALocation

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CertTemplateLocation

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ConfigLocation

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnterpriseCALocation

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

NTAuthStoreLocation

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PKILocation

@@ -312,10 +312,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RootCALocation

diff --git a/api/SharpHoundCommonLib.Enums.LSAPrivileges.html b/api/SharpHoundCommonLib.Enums.LSAPrivileges.html index 8dbed1e5..2698e37d 100644 --- a/api/SharpHoundCommonLib.Enums.LSAPrivileges.html +++ b/api/SharpHoundCommonLib.Enums.LSAPrivileges.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AssignPrimaryToken

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Audit

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Backup

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

BatchLogon

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ChangeNotify

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CreateGlobal

@@ -312,10 +312,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CreatePagefile

@@ -341,10 +341,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CreatePermanent

@@ -370,10 +370,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source
@@ -399,10 +399,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CreateToken

@@ -428,10 +428,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Debug

@@ -457,10 +457,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyBatchLogon

@@ -486,10 +486,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyInteractiveLogon

@@ -515,10 +515,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyNetworkLogon

@@ -544,10 +544,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyRemoteInteractiveLogon

@@ -573,10 +573,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyServiceLogon

@@ -602,10 +602,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DesiredPrivileges

@@ -631,10 +631,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnableDelegation

@@ -660,10 +660,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Impersonate

@@ -689,10 +689,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IncreaseBasePriority

@@ -718,10 +718,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IncreaseQuota

@@ -747,10 +747,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IncreaseWorkingSet

@@ -776,10 +776,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

InteractiveLogon

@@ -805,10 +805,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LoadDriver

@@ -834,10 +834,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LockMemory

@@ -863,10 +863,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

MachineAccount

@@ -892,10 +892,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ManageVolume

@@ -921,10 +921,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

NetworkLogon

@@ -950,10 +950,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ProfileSingleProcess

@@ -979,10 +979,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Relabel

@@ -1008,10 +1008,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RemoteInteractiveLogon

@@ -1037,10 +1037,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RemoteShutdown

@@ -1066,10 +1066,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Restore

@@ -1095,10 +1095,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Security

@@ -1124,10 +1124,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ServiceLogon

@@ -1153,10 +1153,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Shutdown

@@ -1182,10 +1182,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SyncAgent

@@ -1211,10 +1211,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SystemEnvironment

@@ -1240,10 +1240,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SystemProfile

@@ -1269,10 +1269,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SystemTime

@@ -1298,10 +1298,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TakeOwnership

@@ -1327,10 +1327,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Tcb

@@ -1356,10 +1356,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TimeZone

@@ -1385,10 +1385,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TrustedCredManAccess

@@ -1414,10 +1414,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Undock

diff --git a/api/SharpHoundCommonLib.Enums.Label.html b/api/SharpHoundCommonLib.Enums.Label.html index a5b39bfe..ac9cd948 100644 --- a/api/SharpHoundCommonLib.Enums.Label.html +++ b/api/SharpHoundCommonLib.Enums.Label.html @@ -123,10 +123,6 @@

Fields Base - - CertAuthority - - CertTemplate diff --git a/api/SharpHoundCommonLib.Enums.LdapErrorCodes.html b/api/SharpHoundCommonLib.Enums.LdapErrorCodes.html index 985adc09..03776ed3 100644 --- a/api/SharpHoundCommonLib.Enums.LdapErrorCodes.html +++ b/api/SharpHoundCommonLib.Enums.LdapErrorCodes.html @@ -119,6 +119,10 @@

Fields Busy + + LocalError + + ServerDown diff --git a/api/SharpHoundCommonLib.Exceptions.LDAPQueryException.html b/api/SharpHoundCommonLib.Exceptions.LDAPQueryException.html index 4debb54a..e077e617 100644 --- a/api/SharpHoundCommonLib.Exceptions.LDAPQueryException.html +++ b/api/SharpHoundCommonLib.Exceptions.LDAPQueryException.html @@ -177,10 +177,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

LDAPQueryException()

@@ -192,10 +192,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

LDAPQueryException(String)

@@ -224,10 +224,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

LDAPQueryException(String, Exception)

diff --git a/api/SharpHoundCommonLib.Extensions.html b/api/SharpHoundCommonLib.Extensions.html index d5a49e70..ca6f370e 100644 --- a/api/SharpHoundCommonLib.Extensions.html +++ b/api/SharpHoundCommonLib.Extensions.html @@ -138,10 +138,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetGuid(SearchResultEntry)

@@ -187,10 +187,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetLabel(SearchResultEntry)

@@ -236,10 +236,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetObjectIdentifier(SearchResultEntry)

@@ -286,10 +286,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetProperty(SearchResultEntry, String)

@@ -341,10 +341,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetPropertyAsArray(SearchResultEntry, String)

@@ -396,10 +396,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetPropertyAsArrayOfBytes(SearchResultEntry, String)

@@ -452,10 +452,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetPropertyAsArrayOfCertificates(SearchResultEntry, String)

@@ -505,10 +505,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetPropertyAsBytes(SearchResultEntry, String)

@@ -560,10 +560,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetPropertyAsInt(SearchResultEntry, String, out Int32)

@@ -618,10 +618,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetSid(DirectoryEntry)

@@ -665,10 +665,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetSid(SearchResultEntry)

@@ -714,10 +714,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsComputerCollectionSet(ResolvedCollectionMethod)

@@ -762,10 +762,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsDeleted(SearchResultEntry)

@@ -810,10 +810,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsLocalGroupCollectionSet(ResolvedCollectionMethod)

@@ -858,10 +858,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LdapValue(Guid)

@@ -905,10 +905,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LdapValue(SecurityIdentifier)

@@ -952,10 +952,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

PrintEntry(SearchResultEntry)

@@ -1000,10 +1000,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Rid(SecurityIdentifier)

diff --git a/api/SharpHoundCommonLib.Helpers.html b/api/SharpHoundCommonLib.Helpers.html index a9ac613f..d6e17eae 100644 --- a/api/SharpHoundCommonLib.Helpers.html +++ b/api/SharpHoundCommonLib.Helpers.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AuthenticationOIDs

@@ -169,10 +169,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Base64(String)

@@ -217,10 +217,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ConvertFileTimeToUnixEpoch(String)

@@ -265,10 +265,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ConvertGuidToHexGuid(String)

@@ -313,10 +313,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ConvertLdapTimeToLong(String)

@@ -361,10 +361,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ConvertSidToHexSid(String)

@@ -411,10 +411,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ConvertTimestampToUnixEpoch(String)

@@ -459,10 +459,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

DistinguishedNameToDomain(String)

@@ -509,10 +509,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetRegistryKeyData(String, String, String, ILogger)

@@ -571,10 +571,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsSidFiltered(String)

@@ -618,10 +618,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenRemoteRegistry(String)

@@ -665,10 +665,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

RemoveDistinguishedNamePrefix(String)

@@ -712,10 +712,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

SamAccountTypeToType(String)

@@ -761,10 +761,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

SplitGPLinkProperty(String, Boolean)

@@ -815,10 +815,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

StripServicePrincipalName(String)

diff --git a/api/SharpHoundCommonLib.ILDAPUtils.html b/api/SharpHoundCommonLib.ILDAPUtils.html index af3d7ea0..b71ada70 100644 --- a/api/SharpHoundCommonLib.ILDAPUtils.html +++ b/api/SharpHoundCommonLib.ILDAPUtils.html @@ -109,10 +109,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

AddDomainController(String)

@@ -141,10 +141,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

BuildLdapPath(String, String)

@@ -193,10 +193,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ConvertWellKnownPrincipal(String, String)

@@ -245,10 +245,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

DoRangedRetrieval(String, String)

@@ -300,10 +300,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetConfigurationPath(String)

@@ -347,10 +347,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetDomain(String)

@@ -394,10 +394,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetDomainNameFromSid(String)

@@ -441,10 +441,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetForest(String)

@@ -488,10 +488,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetSchemaPath(String)

@@ -535,10 +535,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetSidFromDomainName(String)

@@ -582,10 +582,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetUserGlobalCatalogMatches(String)

@@ -629,10 +629,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetWellKnownPrincipal(String, String, out TypedPrincipal)

@@ -686,10 +686,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetWellKnownPrincipalOutput(String)

@@ -733,10 +733,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsDomainController(String, String)

@@ -785,10 +785,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupGuidType(String, String)

@@ -837,10 +837,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupSidType(String, String)

@@ -889,10 +889,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

MakeSecurityDescriptor()

@@ -919,10 +919,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

QueryLDAP(LDAPQueryOptions)

@@ -969,10 +969,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

QueryLDAP(String, SearchScope, String[], String, Boolean, Boolean, String, Boolean, Boolean, Boolean)

@@ -1074,10 +1074,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

QueryLDAP(String, SearchScope, String[], CancellationToken, String, Boolean, Boolean, String, Boolean, Boolean, Boolean)

@@ -1185,10 +1185,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveAccountName(String, String)

@@ -1238,10 +1238,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveCertTemplateByProperty(String, String, String, String)

@@ -1300,10 +1300,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveDistinguishedName(String)

@@ -1350,10 +1350,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveHostToSid(String, String)

@@ -1403,10 +1403,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveIDAndType(String, String)

@@ -1455,10 +1455,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

SetLDAPConfig(LDAPConfig)

@@ -1487,10 +1487,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

TestLDAPConfig(String)

diff --git a/api/SharpHoundCommonLib.IRegistryKey.html b/api/SharpHoundCommonLib.IRegistryKey.html index 96e3ffa6..d297318c 100644 --- a/api/SharpHoundCommonLib.IRegistryKey.html +++ b/api/SharpHoundCommonLib.IRegistryKey.html @@ -109,10 +109,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetValue(String, String)

diff --git a/api/SharpHoundCommonLib.ISearchResultEntry.html b/api/SharpHoundCommonLib.ISearchResultEntry.html index 9b515898..3fe4e8b8 100644 --- a/api/SharpHoundCommonLib.ISearchResultEntry.html +++ b/api/SharpHoundCommonLib.ISearchResultEntry.html @@ -109,10 +109,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

DistinguishedName

@@ -141,10 +141,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetArrayProperty(String)

@@ -188,10 +188,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetByteArrayProperty(String)

@@ -235,10 +235,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetByteProperty(String)

@@ -282,10 +282,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetCertificateArrayProperty(String)

@@ -329,10 +329,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetGuid()

@@ -359,10 +359,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetIntProperty(String, out Int32)

@@ -411,10 +411,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetLabel()

@@ -441,10 +441,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetObjectIdentifier()

@@ -471,10 +471,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetProperty(String)

@@ -518,10 +518,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetSid()

@@ -548,10 +548,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

HasLAPS()

@@ -578,10 +578,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsDeleted()

@@ -608,10 +608,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsGMSA()

@@ -638,10 +638,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsMSA()

@@ -668,10 +668,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

PropCount(String)

@@ -715,10 +715,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

PropertyNames()

@@ -745,10 +745,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveBloodHoundInfo()

diff --git a/api/SharpHoundCommonLib.LDAPConfig.html b/api/SharpHoundCommonLib.LDAPConfig.html index 0fb4468f..aa5237f4 100644 --- a/api/SharpHoundCommonLib.LDAPConfig.html +++ b/api/SharpHoundCommonLib.LDAPConfig.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

AuthType

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DisableCertVerification

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DisableSigning

@@ -228,10 +228,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Password

@@ -258,10 +258,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Port

@@ -288,10 +288,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Server

@@ -318,10 +318,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SSL

@@ -348,10 +348,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Username

@@ -380,10 +380,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetPort()

diff --git a/api/SharpHoundCommonLib.LDAPProperties.html b/api/SharpHoundCommonLib.LDAPProperties.html index 14cfcafc..a7fa9895 100644 --- a/api/SharpHoundCommonLib.LDAPProperties.html +++ b/api/SharpHoundCommonLib.LDAPProperties.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AdminCount

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AllowedToActOnBehalfOfOtherIdentity

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AllowedToDelegateTo

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ApplicationPolicies

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CACertificate

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CanonicalName

@@ -312,10 +312,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CertificateApplicationPolicy

@@ -341,10 +341,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CertificateTemplates

@@ -370,10 +370,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CertTemplateOID

@@ -399,10 +399,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CrossCertificatePair

@@ -428,10 +428,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Description

@@ -457,10 +457,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DisplayName

@@ -486,10 +486,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DistinguishedName

@@ -515,10 +515,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DNSHostName

@@ -544,10 +544,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainFunctionalLevel

@@ -573,10 +573,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Email

@@ -602,10 +602,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ExtendedKeyUsage

@@ -631,10 +631,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Flags

@@ -660,10 +660,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GPCFileSYSPath

@@ -689,10 +689,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source
@@ -718,10 +718,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GroupMSAMembership

@@ -747,10 +747,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GroupPolicyOptions

@@ -776,10 +776,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

HomeDirectory

@@ -805,10 +805,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

HostServiceAccount

@@ -834,10 +834,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsDeleted

@@ -863,10 +863,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IssuancePolicies

@@ -892,10 +892,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LAPSExpirationTime

@@ -921,10 +921,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LastLogon

@@ -950,10 +950,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LastLogonTimestamp

@@ -979,10 +979,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LdapAdminLimits

@@ -1008,10 +1008,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LegacyLAPSExpirationTime

@@ -1037,10 +1037,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Members

@@ -1066,10 +1066,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

MsSFU30Password

@@ -1095,10 +1095,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Name

@@ -1124,10 +1124,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

NumSignaturesRequired

@@ -1153,10 +1153,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectClass

@@ -1182,10 +1182,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectGUID

@@ -1211,10 +1211,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectSID

@@ -1240,10 +1240,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

OperatingSystem

@@ -1269,10 +1269,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PasswordLastSet

@@ -1298,10 +1298,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PKIEnrollmentFlag

@@ -1327,10 +1327,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PKIExpirationPeriod

@@ -1356,10 +1356,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PKINameFlag

@@ -1385,10 +1385,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PKIOverlappedPeriod

@@ -1414,10 +1414,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PKIPrivateKeyFlag

@@ -1443,10 +1443,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PrimaryGroupID

@@ -1472,10 +1472,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SAMAccountName

@@ -1501,10 +1501,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SAMAccountType

@@ -1530,10 +1530,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SchemaIDGUID

@@ -1559,10 +1559,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ScriptPath

@@ -1588,10 +1588,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SecurityDescriptor

@@ -1617,10 +1617,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SecurityIdentifier

@@ -1646,10 +1646,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ServicePack

@@ -1675,10 +1675,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ServicePrincipalNames

@@ -1704,10 +1704,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SIDHistory

@@ -1733,10 +1733,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TemplateSchemaVersion

@@ -1762,10 +1762,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Title

@@ -1791,10 +1791,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TrustAttributes

@@ -1820,10 +1820,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TrustDirection

@@ -1849,10 +1849,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TrustType

@@ -1878,10 +1878,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

UnicodePassword

@@ -1907,10 +1907,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

UnixUserPassword

@@ -1936,10 +1936,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

UserAccountControl

@@ -1965,10 +1965,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

UserPassword

@@ -1994,10 +1994,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WhenCreated

diff --git a/api/SharpHoundCommonLib.LDAPQueries.CommonFilters.html b/api/SharpHoundCommonLib.LDAPQueries.CommonFilters.html index f4ad569f..5f435e65 100644 --- a/api/SharpHoundCommonLib.LDAPQueries.CommonFilters.html +++ b/api/SharpHoundCommonLib.LDAPQueries.CommonFilters.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

DomainControllers

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnabledOnly

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ExcludeDomainControllers

@@ -228,10 +228,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

NeedsGPCFilePath

@@ -258,10 +258,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

NeedsSPN

@@ -288,10 +288,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TrustedDomains

@@ -320,10 +320,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

SpecificGUID(String)

@@ -367,10 +367,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

SpecificSID(String)

diff --git a/api/SharpHoundCommonLib.LDAPQueries.CommonPaths.html b/api/SharpHoundCommonLib.LDAPQueries.CommonPaths.html index 730cf205..e6170d5b 100644 --- a/api/SharpHoundCommonLib.LDAPQueries.CommonPaths.html +++ b/api/SharpHoundCommonLib.LDAPQueries.CommonPaths.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

ConfigurationPath

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

QueryPolicyPath

@@ -198,10 +198,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

CreateDNPath(String, String)

diff --git a/api/SharpHoundCommonLib.LDAPQueries.CommonProperties.html b/api/SharpHoundCommonLib.LDAPQueries.CommonProperties.html index c4e3e084..5fc8a548 100644 --- a/api/SharpHoundCommonLib.LDAPQueries.CommonProperties.html +++ b/api/SharpHoundCommonLib.LDAPQueries.CommonProperties.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

ACLProps

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

BaseQueryProps

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CertAbuseProps

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerMethodProps

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ContainerProps

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainTrustProps

@@ -312,10 +312,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GPCFileSysPath

@@ -341,10 +341,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GPOLocalGroupProps

@@ -370,10 +370,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GroupResolutionProps

@@ -399,10 +399,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectID

@@ -428,10 +428,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectPropsProps

@@ -457,10 +457,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectSID

@@ -486,10 +486,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SPNTargetProps

@@ -515,10 +515,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TypeResolutionProps

diff --git a/api/SharpHoundCommonLib.LDAPQueries.LDAPFilter.html b/api/SharpHoundCommonLib.LDAPQueries.LDAPFilter.html index b71f5a0a..380a01d4 100644 --- a/api/SharpHoundCommonLib.LDAPQueries.LDAPFilter.html +++ b/api/SharpHoundCommonLib.LDAPQueries.LDAPFilter.html @@ -139,10 +139,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

AddAllObjects(String[])

@@ -187,10 +187,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddCertificateAuthorities(String[])

@@ -235,10 +235,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddCertificateTemplates(String[])

@@ -283,10 +283,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddComputers(String[])

@@ -332,10 +332,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddComputersNoMSAs(String[])

@@ -380,10 +380,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddConfiguration(String[])

@@ -428,10 +428,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddContainers(String[])

@@ -476,10 +476,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddDomains(String[])

@@ -524,10 +524,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddEnterpriseCertificationAuthorities(String[])

@@ -572,10 +572,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddFilter(String, Boolean)

@@ -627,10 +627,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddGPOs(String[])

@@ -675,10 +675,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddGroups(String[])

@@ -723,10 +723,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddOUs(String[])

@@ -771,10 +771,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddPrimaryGroups(String[])

@@ -819,10 +819,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddSchemaID(String[])

@@ -867,10 +867,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

AddUsers(String[])

@@ -915,10 +915,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetFilter()

@@ -946,10 +946,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetFilterList()

diff --git a/api/SharpHoundCommonLib.LDAPQueryOptions.html b/api/SharpHoundCommonLib.LDAPQueryOptions.html index 14b0e27c..efeeb68c 100644 --- a/api/SharpHoundCommonLib.LDAPQueryOptions.html +++ b/api/SharpHoundCommonLib.LDAPQueryOptions.html @@ -131,10 +131,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AdsPath

@@ -160,10 +160,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CancellationToken

@@ -189,10 +189,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainName

@@ -218,10 +218,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Filter

@@ -247,10 +247,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GlobalCatalog

@@ -276,10 +276,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IncludeAcl

@@ -305,10 +305,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Properties

@@ -334,10 +334,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Scope

@@ -363,10 +363,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ShowDeleted

@@ -392,10 +392,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SkipCache

@@ -421,10 +421,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ThrowException

diff --git a/api/SharpHoundCommonLib.LDAPUtils.html b/api/SharpHoundCommonLib.LDAPUtils.html index 7d524cc5..0ddcfa0d 100644 --- a/api/SharpHoundCommonLib.LDAPUtils.html +++ b/api/SharpHoundCommonLib.LDAPUtils.html @@ -142,10 +142,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

LDAPUtils()

@@ -158,10 +158,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

LDAPUtils(NativeMethods, PortScanner, ILogger)

@@ -203,10 +203,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

AddDomainController(String)

@@ -236,10 +236,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

BuildLdapPath(String, String)

@@ -288,10 +288,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ConvertWellKnownPrincipal(String, String)

@@ -341,10 +341,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

DoRangedRetrieval(String, String)

@@ -396,10 +396,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetConfigurationPath(String)

@@ -443,10 +443,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetDomain(String)

@@ -492,10 +492,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetDomainNameFromSid(String)

@@ -540,10 +540,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetDomainRangeSize(String, Int32)

@@ -593,10 +593,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetForest(String)

@@ -642,10 +642,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetSchemaPath(String)

@@ -689,10 +689,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetSidFromDomainName(String)

@@ -737,10 +737,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetUserGlobalCatalogMatches(String)

@@ -785,10 +785,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetWellKnownPrincipal(String, String, out TypedPrincipal)

@@ -844,10 +844,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetWellKnownPrincipalOutput(String)

@@ -907,10 +907,10 @@
Exceptions
| - Improve this Doc + Improve this Doc - View Source + View Source

IsDomainController(String, String)

@@ -959,10 +959,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupGuidType(String, String)

@@ -1012,10 +1012,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupSidType(String, String)

@@ -1065,10 +1065,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

MakeSecurityDescriptor()

@@ -1097,10 +1097,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

QueryLDAP(LDAPQueryOptions)

@@ -1145,10 +1145,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

QueryLDAP(String, SearchScope, String[], String, Boolean, Boolean, String, Boolean, Boolean, Boolean)

@@ -1266,10 +1266,10 @@
Exceptions
| - Improve this Doc + Improve this Doc - View Source + View Source

QueryLDAP(String, SearchScope, String[], CancellationToken, String, Boolean, Boolean, String, Boolean, Boolean, Boolean)

@@ -1393,10 +1393,10 @@
Exceptions
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveAccountName(String, String)

@@ -1446,10 +1446,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveCertTemplateByProperty(String, String, String, String)

@@ -1508,10 +1508,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveDistinguishedName(String)

@@ -1558,10 +1558,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveHostToSid(String, String)

@@ -1611,10 +1611,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveIDAndType(String, String)

@@ -1665,10 +1665,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

SetLDAPConfig(LDAPConfig)

@@ -1713,10 +1713,10 @@
Exceptions
| - Improve this Doc + Improve this Doc - View Source + View Source

TestLDAPConfig(String)

@@ -1762,10 +1762,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

UpdateLDAPConfig(LDAPConfig)

diff --git a/api/SharpHoundCommonLib.MockRegistryKey.html b/api/SharpHoundCommonLib.MockRegistryKey.html index 9d3d340d..43b86b4b 100644 --- a/api/SharpHoundCommonLib.MockRegistryKey.html +++ b/api/SharpHoundCommonLib.MockRegistryKey.html @@ -142,10 +142,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetValue(String, String)

diff --git a/api/SharpHoundCommonLib.NativeMethods.html b/api/SharpHoundCommonLib.NativeMethods.html index a4f859a5..6cd19dea 100644 --- a/api/SharpHoundCommonLib.NativeMethods.html +++ b/api/SharpHoundCommonLib.NativeMethods.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

NativeMethods()

@@ -153,10 +153,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

NativeMethods(ILogger)

@@ -187,10 +187,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

CallDsGetDcName(String, String)

@@ -239,10 +239,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

NetSessionEnum(String)

@@ -286,10 +286,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

NetWkstaUserEnum(String)

diff --git a/api/SharpHoundCommonLib.NoOpLogger.html b/api/SharpHoundCommonLib.NoOpLogger.html index 2b64b158..14a3d464 100644 --- a/api/SharpHoundCommonLib.NoOpLogger.html +++ b/api/SharpHoundCommonLib.NoOpLogger.html @@ -115,10 +115,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

BeginScope<TState>(TState)

@@ -177,10 +177,10 @@
Type Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

IsEnabled(LogLevel)

@@ -224,10 +224,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Log<TState>(LogLevel, EventId, TState, Exception, Func<TState, Exception, String>)

diff --git a/api/SharpHoundCommonLib.OutputTypes.ACE.html b/api/SharpHoundCommonLib.OutputTypes.ACE.html index 7a34a3f0..6a3e9dce 100644 --- a/api/SharpHoundCommonLib.OutputTypes.ACE.html +++ b/api/SharpHoundCommonLib.OutputTypes.ACE.html @@ -129,10 +129,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

IsInherited

@@ -159,10 +159,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PrincipalSID

@@ -189,10 +189,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PrincipalType

@@ -219,10 +219,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RightName

@@ -251,10 +251,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Equals(ACE)

@@ -298,10 +298,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Equals(Object)

@@ -347,10 +347,10 @@
Overrides
System.Object.Equals(System.Object)
| - Improve this Doc + Improve this Doc - View Source + View Source

GetHashCode()

@@ -379,10 +379,10 @@
Overrides
System.Object.GetHashCode()
| - Improve this Doc + Improve this Doc - View Source + View Source

ToString()

diff --git a/api/SharpHoundCommonLib.OutputTypes.APIResult.html b/api/SharpHoundCommonLib.OutputTypes.APIResult.html index 063c9cd7..2271dbe4 100644 --- a/api/SharpHoundCommonLib.OutputTypes.APIResult.html +++ b/api/SharpHoundCommonLib.OutputTypes.APIResult.html @@ -147,10 +147,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Collected

@@ -177,10 +177,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

FailureReason

diff --git a/api/SharpHoundCommonLib.OutputTypes.AceRegistryAPIResult.html b/api/SharpHoundCommonLib.OutputTypes.AceRegistryAPIResult.html index db0155ce..ed60f37a 100644 --- a/api/SharpHoundCommonLib.OutputTypes.AceRegistryAPIResult.html +++ b/api/SharpHoundCommonLib.OutputTypes.AceRegistryAPIResult.html @@ -145,10 +145,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Data

diff --git a/api/SharpHoundCommonLib.OutputTypes.BoolRegistryAPIResult.html b/api/SharpHoundCommonLib.OutputTypes.BoolRegistryAPIResult.html index 476e65f3..df1693c0 100644 --- a/api/SharpHoundCommonLib.OutputTypes.BoolRegistryAPIResult.html +++ b/api/SharpHoundCommonLib.OutputTypes.BoolRegistryAPIResult.html @@ -145,10 +145,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Value

diff --git a/api/SharpHoundCommonLib.OutputTypes.CARegistryData.html b/api/SharpHoundCommonLib.OutputTypes.CARegistryData.html index d1de1a6e..59087156 100644 --- a/api/SharpHoundCommonLib.OutputTypes.CARegistryData.html +++ b/api/SharpHoundCommonLib.OutputTypes.CARegistryData.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

CASecurity

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnrollmentAgentRestrictions

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsUserSpecifiesSanEnabled

diff --git a/api/SharpHoundCommonLib.OutputTypes.CertificateExtension.html b/api/SharpHoundCommonLib.OutputTypes.CertificateExtension.html index 10389c8b..194d0894 100644 --- a/api/SharpHoundCommonLib.OutputTypes.CertificateExtension.html +++ b/api/SharpHoundCommonLib.OutputTypes.CertificateExtension.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

CertificateExtension(X509Extension)

@@ -172,10 +172,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Critical

@@ -202,10 +202,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Oid

diff --git a/api/SharpHoundCommonLib.OutputTypes.Computer.html b/api/SharpHoundCommonLib.OutputTypes.Computer.html index 32f94003..f8ad7cc4 100644 --- a/api/SharpHoundCommonLib.OutputTypes.Computer.html +++ b/api/SharpHoundCommonLib.OutputTypes.Computer.html @@ -158,10 +158,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

AllowedToAct

@@ -188,10 +188,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AllowedToDelegate

@@ -218,10 +218,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DCRegistryData

@@ -248,10 +248,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainSID

@@ -278,10 +278,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DumpSMSAPassword

@@ -308,10 +308,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

HasSIDHistory

@@ -338,10 +338,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsDC

@@ -368,10 +368,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LocalGroups

@@ -398,10 +398,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PrimaryGroupSID

@@ -428,10 +428,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PrivilegedSessions

@@ -458,10 +458,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RegistrySessions

@@ -488,10 +488,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Sessions

@@ -518,10 +518,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Status

@@ -548,10 +548,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

UserRights

diff --git a/api/SharpHoundCommonLib.OutputTypes.ComputerStatus.html b/api/SharpHoundCommonLib.OutputTypes.ComputerStatus.html index 866ae34f..3320be87 100644 --- a/api/SharpHoundCommonLib.OutputTypes.ComputerStatus.html +++ b/api/SharpHoundCommonLib.OutputTypes.ComputerStatus.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Connectable

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Error

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

NonWindowsOS

@@ -228,10 +228,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

OldPwd

@@ -258,10 +258,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PortNotOpen

@@ -288,10 +288,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Success

@@ -320,10 +320,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetCSVStatus(String)

diff --git a/api/SharpHoundCommonLib.OutputTypes.Container.html b/api/SharpHoundCommonLib.OutputTypes.Container.html index 98b5a614..686ed52d 100644 --- a/api/SharpHoundCommonLib.OutputTypes.Container.html +++ b/api/SharpHoundCommonLib.OutputTypes.Container.html @@ -157,10 +157,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ChildObjects

diff --git a/api/SharpHoundCommonLib.OutputTypes.DCRegistryData.html b/api/SharpHoundCommonLib.OutputTypes.DCRegistryData.html index 033917e9..7bedb63e 100644 --- a/api/SharpHoundCommonLib.OutputTypes.DCRegistryData.html +++ b/api/SharpHoundCommonLib.OutputTypes.DCRegistryData.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

CertificateMappingMethods

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

StrongCertificateBindingEnforcement

diff --git a/api/SharpHoundCommonLib.OutputTypes.Domain.html b/api/SharpHoundCommonLib.OutputTypes.Domain.html index 25b82bc8..16b71363 100644 --- a/api/SharpHoundCommonLib.OutputTypes.Domain.html +++ b/api/SharpHoundCommonLib.OutputTypes.Domain.html @@ -157,10 +157,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

GPOChanges

@@ -188,10 +188,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ChildObjects

@@ -218,10 +218,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source @@ -248,10 +248,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Trusts

diff --git a/api/SharpHoundCommonLib.OutputTypes.DomainTrust.html b/api/SharpHoundCommonLib.OutputTypes.DomainTrust.html index 0a2fbdfc..96bcffd4 100644 --- a/api/SharpHoundCommonLib.OutputTypes.DomainTrust.html +++ b/api/SharpHoundCommonLib.OutputTypes.DomainTrust.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

IsTransitive

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SidFilteringEnabled

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TargetDomainName

@@ -228,10 +228,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TargetDomainSid

@@ -258,10 +258,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TrustDirection

@@ -288,10 +288,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TrustType

diff --git a/api/SharpHoundCommonLib.OutputTypes.EnrollmentAgentRegistryAPIResult.html b/api/SharpHoundCommonLib.OutputTypes.EnrollmentAgentRegistryAPIResult.html index 1b51cad3..9dee0e6b 100644 --- a/api/SharpHoundCommonLib.OutputTypes.EnrollmentAgentRegistryAPIResult.html +++ b/api/SharpHoundCommonLib.OutputTypes.EnrollmentAgentRegistryAPIResult.html @@ -145,10 +145,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Restrictions

diff --git a/api/SharpHoundCommonLib.OutputTypes.EnterpriseCA.html b/api/SharpHoundCommonLib.OutputTypes.EnterpriseCA.html index 046b70dd..7c6f0271 100644 --- a/api/SharpHoundCommonLib.OutputTypes.EnterpriseCA.html +++ b/api/SharpHoundCommonLib.OutputTypes.EnterpriseCA.html @@ -157,10 +157,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

CARegistryData

@@ -187,10 +187,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnabledCertTemplates

@@ -217,10 +217,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

HostingComputer

diff --git a/api/SharpHoundCommonLib.OutputTypes.GPLink.html b/api/SharpHoundCommonLib.OutputTypes.GPLink.html index d90d530f..e70e29c4 100644 --- a/api/SharpHoundCommonLib.OutputTypes.GPLink.html +++ b/api/SharpHoundCommonLib.OutputTypes.GPLink.html @@ -132,10 +132,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source @@ -162,10 +162,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source @@ -194,10 +194,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source @@ -241,10 +241,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source @@ -290,10 +290,10 @@
Overrides
System.Object.Equals(System.Object)
| - Improve this Doc + Improve this Doc - View Source + View Source diff --git a/api/SharpHoundCommonLib.OutputTypes.Group.html b/api/SharpHoundCommonLib.OutputTypes.Group.html index eb1629f4..d9984f8f 100644 --- a/api/SharpHoundCommonLib.OutputTypes.Group.html +++ b/api/SharpHoundCommonLib.OutputTypes.Group.html @@ -157,10 +157,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Members

diff --git a/api/SharpHoundCommonLib.OutputTypes.IntRegistryAPIResult.html b/api/SharpHoundCommonLib.OutputTypes.IntRegistryAPIResult.html index 5010ec8c..78b2e5e4 100644 --- a/api/SharpHoundCommonLib.OutputTypes.IntRegistryAPIResult.html +++ b/api/SharpHoundCommonLib.OutputTypes.IntRegistryAPIResult.html @@ -145,10 +145,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Value

diff --git a/api/SharpHoundCommonLib.OutputTypes.LSAPrivilegeAPIResult.html b/api/SharpHoundCommonLib.OutputTypes.LSAPrivilegeAPIResult.html index f3272939..9ce8f134 100644 --- a/api/SharpHoundCommonLib.OutputTypes.LSAPrivilegeAPIResult.html +++ b/api/SharpHoundCommonLib.OutputTypes.LSAPrivilegeAPIResult.html @@ -145,10 +145,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Results

diff --git a/api/SharpHoundCommonLib.OutputTypes.LocalGroup.html b/api/SharpHoundCommonLib.OutputTypes.LocalGroup.html index ae4c5cb4..93cfda18 100644 --- a/api/SharpHoundCommonLib.OutputTypes.LocalGroup.html +++ b/api/SharpHoundCommonLib.OutputTypes.LocalGroup.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Name

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectID

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Rid

diff --git a/api/SharpHoundCommonLib.OutputTypes.LocalGroupAPIResult.html b/api/SharpHoundCommonLib.OutputTypes.LocalGroupAPIResult.html index 6737f273..ee4e7ba7 100644 --- a/api/SharpHoundCommonLib.OutputTypes.LocalGroupAPIResult.html +++ b/api/SharpHoundCommonLib.OutputTypes.LocalGroupAPIResult.html @@ -142,10 +142,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

LocalNames

@@ -172,10 +172,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Name

@@ -202,10 +202,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectIdentifier

@@ -232,10 +232,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Results

@@ -264,10 +264,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ToString()

diff --git a/api/SharpHoundCommonLib.OutputTypes.MetaTag.html b/api/SharpHoundCommonLib.OutputTypes.MetaTag.html index 33629835..1e783c82 100644 --- a/api/SharpHoundCommonLib.OutputTypes.MetaTag.html +++ b/api/SharpHoundCommonLib.OutputTypes.MetaTag.html @@ -139,10 +139,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

CollectionMethods

@@ -170,10 +170,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Count

@@ -201,10 +201,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DataType

@@ -232,10 +232,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Version

diff --git a/api/SharpHoundCommonLib.OutputTypes.NTAuthStore.html b/api/SharpHoundCommonLib.OutputTypes.NTAuthStore.html index 72484c65..0636d82b 100644 --- a/api/SharpHoundCommonLib.OutputTypes.NTAuthStore.html +++ b/api/SharpHoundCommonLib.OutputTypes.NTAuthStore.html @@ -157,10 +157,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

DomainSID

diff --git a/api/SharpHoundCommonLib.OutputTypes.NamedPrincipal.html b/api/SharpHoundCommonLib.OutputTypes.NamedPrincipal.html index 9ac8a595..5f3f905c 100644 --- a/api/SharpHoundCommonLib.OutputTypes.NamedPrincipal.html +++ b/api/SharpHoundCommonLib.OutputTypes.NamedPrincipal.html @@ -135,10 +135,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

NamedPrincipal()

@@ -150,10 +150,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

NamedPrincipal(String, String)

@@ -189,10 +189,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectId

@@ -219,10 +219,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PrincipalName

@@ -251,10 +251,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ToString()

diff --git a/api/SharpHoundCommonLib.OutputTypes.OU.html b/api/SharpHoundCommonLib.OutputTypes.OU.html index 212d2e06..706b5618 100644 --- a/api/SharpHoundCommonLib.OutputTypes.OU.html +++ b/api/SharpHoundCommonLib.OutputTypes.OU.html @@ -157,10 +157,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

GPOChanges

@@ -188,10 +188,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ChildObjects

@@ -218,10 +218,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source diff --git a/api/SharpHoundCommonLib.OutputTypes.OutputBase.html b/api/SharpHoundCommonLib.OutputTypes.OutputBase.html index 323b139b..4ee32bb1 100644 --- a/api/SharpHoundCommonLib.OutputTypes.OutputBase.html +++ b/api/SharpHoundCommonLib.OutputTypes.OutputBase.html @@ -151,10 +151,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

Properties

@@ -182,10 +182,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Aces

@@ -212,10 +212,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ContainedBy

@@ -242,10 +242,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsACLProtected

@@ -272,10 +272,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsDeleted

@@ -302,10 +302,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectIdentifier

diff --git a/api/SharpHoundCommonLib.OutputTypes.OutputWrapper-1.html b/api/SharpHoundCommonLib.OutputTypes.OutputWrapper-1.html index e4a404ed..e6876b7c 100644 --- a/api/SharpHoundCommonLib.OutputTypes.OutputWrapper-1.html +++ b/api/SharpHoundCommonLib.OutputTypes.OutputWrapper-1.html @@ -154,10 +154,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Data

@@ -185,10 +185,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Meta

diff --git a/api/SharpHoundCommonLib.OutputTypes.ResultingGPOChanges.html b/api/SharpHoundCommonLib.OutputTypes.ResultingGPOChanges.html index 2a8168c0..22198de4 100644 --- a/api/SharpHoundCommonLib.OutputTypes.ResultingGPOChanges.html +++ b/api/SharpHoundCommonLib.OutputTypes.ResultingGPOChanges.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

AffectedComputers

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DcomUsers

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LocalAdmins

@@ -228,10 +228,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PSRemoteUsers

@@ -258,10 +258,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RemoteDesktopUsers

diff --git a/api/SharpHoundCommonLib.OutputTypes.RootCA.html b/api/SharpHoundCommonLib.OutputTypes.RootCA.html index b7a91a8d..d203765c 100644 --- a/api/SharpHoundCommonLib.OutputTypes.RootCA.html +++ b/api/SharpHoundCommonLib.OutputTypes.RootCA.html @@ -157,10 +157,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

DomainSID

diff --git a/api/SharpHoundCommonLib.OutputTypes.SPNPrivilege.html b/api/SharpHoundCommonLib.OutputTypes.SPNPrivilege.html index 6770ead1..f4c388b4 100644 --- a/api/SharpHoundCommonLib.OutputTypes.SPNPrivilege.html +++ b/api/SharpHoundCommonLib.OutputTypes.SPNPrivilege.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerSID

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Port

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Service

diff --git a/api/SharpHoundCommonLib.OutputTypes.Session.html b/api/SharpHoundCommonLib.OutputTypes.Session.html index f6f87b24..ff6064a2 100644 --- a/api/SharpHoundCommonLib.OutputTypes.Session.html +++ b/api/SharpHoundCommonLib.OutputTypes.Session.html @@ -132,10 +132,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerSID

@@ -162,10 +162,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

UserSID

@@ -194,10 +194,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Equals(Session)

@@ -241,10 +241,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Equals(Object)

@@ -290,10 +290,10 @@
Overrides
System.Object.Equals(System.Object)
| - Improve this Doc + Improve this Doc - View Source + View Source

GetHashCode()

diff --git a/api/SharpHoundCommonLib.OutputTypes.SessionAPIResult.html b/api/SharpHoundCommonLib.OutputTypes.SessionAPIResult.html index c85e7a71..9741a6cd 100644 --- a/api/SharpHoundCommonLib.OutputTypes.SessionAPIResult.html +++ b/api/SharpHoundCommonLib.OutputTypes.SessionAPIResult.html @@ -145,10 +145,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Results

diff --git a/api/SharpHoundCommonLib.OutputTypes.TypedPrincipal.html b/api/SharpHoundCommonLib.OutputTypes.TypedPrincipal.html index de415829..41782339 100644 --- a/api/SharpHoundCommonLib.OutputTypes.TypedPrincipal.html +++ b/api/SharpHoundCommonLib.OutputTypes.TypedPrincipal.html @@ -129,10 +129,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

TypedPrincipal()

@@ -144,10 +144,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

TypedPrincipal(String, Label)

@@ -183,10 +183,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectIdentifier

@@ -213,10 +213,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectType

@@ -245,10 +245,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Equals(TypedPrincipal)

@@ -292,10 +292,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Equals(Object)

@@ -341,10 +341,10 @@
Overrides
System.Object.Equals(System.Object)
| - Improve this Doc + Improve this Doc - View Source + View Source

GetHashCode()

@@ -373,10 +373,10 @@
Overrides
System.Object.GetHashCode()
| - Improve this Doc + Improve this Doc - View Source + View Source

ToString()

diff --git a/api/SharpHoundCommonLib.OutputTypes.User.html b/api/SharpHoundCommonLib.OutputTypes.User.html index fed421c7..0b590bc7 100644 --- a/api/SharpHoundCommonLib.OutputTypes.User.html +++ b/api/SharpHoundCommonLib.OutputTypes.User.html @@ -157,10 +157,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

AllowedToDelegate

@@ -187,10 +187,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

HasSIDHistory

@@ -217,10 +217,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PrimaryGroupSID

@@ -247,10 +247,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SPNTargets

diff --git a/api/SharpHoundCommonLib.OutputTypes.UserRightsAssignmentAPIResult.html b/api/SharpHoundCommonLib.OutputTypes.UserRightsAssignmentAPIResult.html index 58ec6031..c947b4b2 100644 --- a/api/SharpHoundCommonLib.OutputTypes.UserRightsAssignmentAPIResult.html +++ b/api/SharpHoundCommonLib.OutputTypes.UserRightsAssignmentAPIResult.html @@ -142,10 +142,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

LocalNames

@@ -172,10 +172,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Privilege

@@ -202,10 +202,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Results

@@ -234,10 +234,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ToString()

diff --git a/api/SharpHoundCommonLib.ParsedGPLink.html b/api/SharpHoundCommonLib.ParsedGPLink.html index 36114005..4a469f4c 100644 --- a/api/SharpHoundCommonLib.ParsedGPLink.html +++ b/api/SharpHoundCommonLib.ParsedGPLink.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source @@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source diff --git a/api/SharpHoundCommonLib.Processors.ACEGuids.html b/api/SharpHoundCommonLib.Processors.ACEGuids.html index a1931b8c..e6d7cb67 100644 --- a/api/SharpHoundCommonLib.Processors.ACEGuids.html +++ b/api/SharpHoundCommonLib.Processors.ACEGuids.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AddKeyPrincipal

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AllGuid

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AutoEnroll

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DSReplicationGetChanges

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DSReplicationGetChangesAll

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DSReplicationGetChangesInFilteredSet

@@ -312,10 +312,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Enroll

@@ -341,10 +341,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PKIEnrollmentFlag

@@ -370,10 +370,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PKINameFlag

@@ -399,10 +399,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

UserAccountRestrictions

@@ -428,10 +428,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

UserForceChangePassword

@@ -457,10 +457,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WriteAllowedToAct

@@ -486,10 +486,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WriteMember

@@ -515,10 +515,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

WriteSPN

diff --git a/api/SharpHoundCommonLib.Processors.ACLProcessor.html b/api/SharpHoundCommonLib.Processors.ACLProcessor.html index 80687d57..ef676a25 100644 --- a/api/SharpHoundCommonLib.Processors.ACLProcessor.html +++ b/api/SharpHoundCommonLib.Processors.ACLProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

ACLProcessor(ILDAPUtils, Boolean, ILogger, String)

@@ -187,10 +187,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

IsACLProtected(ISearchResultEntry)

@@ -235,10 +235,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsACLProtected(Byte[])

@@ -283,10 +283,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ProcessACL(ResolvedSearchResult, ISearchResultEntry)

@@ -336,10 +336,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ProcessACL(Byte[], String, Label, Boolean, String)

@@ -405,10 +405,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ProcessGMSAReaders(ResolvedSearchResult, ISearchResultEntry)

@@ -458,10 +458,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ProcessGMSAReaders(Byte[], String)

@@ -511,10 +511,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ProcessGMSAReaders(Byte[], String, String)

diff --git a/api/SharpHoundCommonLib.Processors.CertAbuseProcessor.html b/api/SharpHoundCommonLib.Processors.CertAbuseProcessor.html index ffae1dc5..8f94105f 100644 --- a/api/SharpHoundCommonLib.Processors.CertAbuseProcessor.html +++ b/api/SharpHoundCommonLib.Processors.CertAbuseProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

CertAbuseProcessor(ILDAPUtils, ILogger)

@@ -177,10 +177,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

_utils

@@ -208,10 +208,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetRegistryPrincipal(SecurityIdentifier, String, String, Boolean, String, SecurityIdentifier)

@@ -280,10 +280,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsUserSpecifiesSanEnabled(String, String)

@@ -352,10 +352,10 @@
Exceptions
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenSamServer(String)

@@ -399,10 +399,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ProcessCertTemplates(String[], String)

@@ -451,10 +451,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ProcessEAPermissions(String, String, String, String)

@@ -515,10 +515,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ProcessRegistryEnrollmentPermissions(String, String, String, String)

@@ -581,10 +581,10 @@

Events

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerStatusEvent

diff --git a/api/SharpHoundCommonLib.Processors.CertRegistryResult.html b/api/SharpHoundCommonLib.Processors.CertRegistryResult.html index 2e2a7c5a..b182e7f3 100644 --- a/api/SharpHoundCommonLib.Processors.CertRegistryResult.html +++ b/api/SharpHoundCommonLib.Processors.CertRegistryResult.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Collected

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

FailureReason

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Value

diff --git a/api/SharpHoundCommonLib.Processors.ComputerAvailability.html b/api/SharpHoundCommonLib.Processors.ComputerAvailability.html index 33db3d72..5d588083 100644 --- a/api/SharpHoundCommonLib.Processors.ComputerAvailability.html +++ b/api/SharpHoundCommonLib.Processors.ComputerAvailability.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerAvailability(PortScanner, Int32, Int32, Boolean, Boolean, ILogger)

@@ -195,10 +195,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerAvailability(Int32, Int32, Boolean, Boolean, ILogger)

@@ -249,10 +249,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

IsComputerAvailable(ResolvedSearchResult, ISearchResultEntry)

@@ -302,10 +302,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsComputerAvailable(String, String, String)

@@ -369,10 +369,10 @@

Events

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerStatusEvent

diff --git a/api/SharpHoundCommonLib.Processors.ComputerProperties.html b/api/SharpHoundCommonLib.Processors.ComputerProperties.html index 97b11b50..305f9748 100644 --- a/api/SharpHoundCommonLib.Processors.ComputerProperties.html +++ b/api/SharpHoundCommonLib.Processors.ComputerProperties.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

AllowedToAct

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AllowedToDelegate

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DumpSMSAPassword

@@ -228,10 +228,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Props

@@ -258,10 +258,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SidHistory

diff --git a/api/SharpHoundCommonLib.Processors.ComputerSessionProcessor.html b/api/SharpHoundCommonLib.Processors.ComputerSessionProcessor.html index 090ba470..c407fa37 100644 --- a/api/SharpHoundCommonLib.Processors.ComputerSessionProcessor.html +++ b/api/SharpHoundCommonLib.Processors.ComputerSessionProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerSessionProcessor(ILDAPUtils, String, NativeMethods, ILogger, Boolean, String, String)

@@ -202,10 +202,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ReadUserSessions(String, String, String)

@@ -261,10 +261,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadUserSessionsPrivileged(String, String, String)

@@ -320,10 +320,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadUserSessionsRegistry(String, String, String)

@@ -379,10 +379,10 @@

Events

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerStatusEvent

diff --git a/api/SharpHoundCommonLib.Processors.ContainerProcessor.html b/api/SharpHoundCommonLib.Processors.ContainerProcessor.html index 22189f78..a1e4416e 100644 --- a/api/SharpHoundCommonLib.Processors.ContainerProcessor.html +++ b/api/SharpHoundCommonLib.Processors.ContainerProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

ContainerProcessor(ILDAPUtils, ILogger)

@@ -177,10 +177,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetContainerChildObjects(ResolvedSearchResult, ISearchResultEntry)

@@ -230,10 +230,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetContainerChildObjects(String, String)

@@ -283,10 +283,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetContainingObject(ISearchResultEntry)

@@ -331,10 +331,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetContainingObject(String)

@@ -380,10 +380,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadBlocksInheritance(String)

@@ -428,10 +428,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source @@ -480,10 +480,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source diff --git a/api/SharpHoundCommonLib.Processors.DCRegistryProcessor.html b/api/SharpHoundCommonLib.Processors.DCRegistryProcessor.html index 1830b536..602e18d4 100644 --- a/api/SharpHoundCommonLib.Processors.DCRegistryProcessor.html +++ b/api/SharpHoundCommonLib.Processors.DCRegistryProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

DCRegistryProcessor(ILDAPUtils, ILogger)

@@ -177,10 +177,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

_utils

@@ -208,10 +208,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetCertificateMappingMethods(String)

@@ -275,10 +275,10 @@
Exceptions
| - Improve this Doc + Improve this Doc - View Source + View Source

GetStrongCertificateBindingEnforcement(String)

diff --git a/api/SharpHoundCommonLib.Processors.DomainTrustProcessor.html b/api/SharpHoundCommonLib.Processors.DomainTrustProcessor.html index 65b0b1fc..8c915a69 100644 --- a/api/SharpHoundCommonLib.Processors.DomainTrustProcessor.html +++ b/api/SharpHoundCommonLib.Processors.DomainTrustProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

DomainTrustProcessor(ILDAPUtils, ILogger)

@@ -177,10 +177,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

EnumerateDomainTrusts(String)

@@ -225,10 +225,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

TrustAttributesToType(TrustAttributes)

diff --git a/api/SharpHoundCommonLib.Processors.EnrollmentAgentRestriction.html b/api/SharpHoundCommonLib.Processors.EnrollmentAgentRestriction.html index 568d2882..ed7b5d36 100644 --- a/api/SharpHoundCommonLib.Processors.EnrollmentAgentRestriction.html +++ b/api/SharpHoundCommonLib.Processors.EnrollmentAgentRestriction.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

EnrollmentAgentRestriction(QualifiedAce, String, String, CertAbuseProcessor, String, Boolean, String, SecurityIdentifier)

@@ -207,10 +207,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

AccessType

@@ -237,10 +237,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Agent

@@ -267,10 +267,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AllTemplates

@@ -297,10 +297,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Targets

@@ -327,10 +327,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Template

diff --git a/api/SharpHoundCommonLib.Processors.GPOLocalGroupProcessor.GroupResults.html b/api/SharpHoundCommonLib.Processors.GPOLocalGroupProcessor.GroupResults.html index a159bdde..330746bc 100644 --- a/api/SharpHoundCommonLib.Processors.GPOLocalGroupProcessor.GroupResults.html +++ b/api/SharpHoundCommonLib.Processors.GPOLocalGroupProcessor.GroupResults.html @@ -139,10 +139,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

LocalGroups

@@ -168,10 +168,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RestrictedMember

@@ -197,10 +197,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RestrictedMemberOf

diff --git a/api/SharpHoundCommonLib.Processors.GPOLocalGroupProcessor.html b/api/SharpHoundCommonLib.Processors.GPOLocalGroupProcessor.html index e5d4153f..168345b2 100644 --- a/api/SharpHoundCommonLib.Processors.GPOLocalGroupProcessor.html +++ b/api/SharpHoundCommonLib.Processors.GPOLocalGroupProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

GPOLocalGroupProcessor(ILDAPUtils, ILogger)

@@ -177,10 +177,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ReadGPOLocalGroups(ISearchResultEntry)

@@ -224,10 +224,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadGPOLocalGroups(String, String)

diff --git a/api/SharpHoundCommonLib.Processors.GroupProcessor.html b/api/SharpHoundCommonLib.Processors.GroupProcessor.html index 7d541e16..5daaadae 100644 --- a/api/SharpHoundCommonLib.Processors.GroupProcessor.html +++ b/api/SharpHoundCommonLib.Processors.GroupProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

GroupProcessor(ILDAPUtils, ILogger)

@@ -177,10 +177,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetPrimaryGroupInfo(String, String)

@@ -230,10 +230,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadGroupMembers(ResolvedSearchResult, ISearchResultEntry)

@@ -282,10 +282,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadGroupMembers(String, String[], String)

diff --git a/api/SharpHoundCommonLib.Processors.LDAPPropertyProcessor.html b/api/SharpHoundCommonLib.Processors.LDAPPropertyProcessor.html index fbd915bc..4f7170e9 100644 --- a/api/SharpHoundCommonLib.Processors.LDAPPropertyProcessor.html +++ b/api/SharpHoundCommonLib.Processors.LDAPPropertyProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

LDAPPropertyProcessor(ILDAPUtils)

@@ -172,10 +172,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

FunctionalLevelToString(Int32)

@@ -220,10 +220,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ParseAllProperties(ISearchResultEntry)

@@ -269,10 +269,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadAIACAProperties(ISearchResultEntry)

@@ -318,10 +318,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadCertTemplateProperties(ISearchResultEntry)

@@ -367,10 +367,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadComputerProperties(ISearchResultEntry)

@@ -415,10 +415,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadContainerProperties(ISearchResultEntry)

@@ -463,10 +463,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadDomainProperties(ISearchResultEntry)

@@ -511,10 +511,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadEnterpriseCAProperties(ISearchResultEntry)

@@ -558,10 +558,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadGPOProperties(ISearchResultEntry)

@@ -606,10 +606,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadGroupProperties(ISearchResultEntry)

@@ -654,10 +654,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadNTAuthStoreProperties(ISearchResultEntry)

@@ -703,10 +703,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadOUProperties(ISearchResultEntry)

@@ -751,10 +751,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadRootCAProperties(ISearchResultEntry)

@@ -800,10 +800,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadUserProperties(ISearchResultEntry)

diff --git a/api/SharpHoundCommonLib.Processors.LocalGroupProcessor.html b/api/SharpHoundCommonLib.Processors.LocalGroupProcessor.html index 63d57781..9368b9aa 100644 --- a/api/SharpHoundCommonLib.Processors.LocalGroupProcessor.html +++ b/api/SharpHoundCommonLib.Processors.LocalGroupProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

LocalGroupProcessor(ILDAPUtils, ILogger)

@@ -177,10 +177,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetLocalGroups(ResolvedSearchResult)

@@ -224,10 +224,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetLocalGroups(String, String, String, Boolean)

@@ -290,10 +290,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenSamServer(String)

@@ -339,10 +339,10 @@

Events

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerStatusEvent

diff --git a/api/SharpHoundCommonLib.Processors.ParsedCertificate.html b/api/SharpHoundCommonLib.Processors.ParsedCertificate.html index eb0927a6..0c91eb9d 100644 --- a/api/SharpHoundCommonLib.Processors.ParsedCertificate.html +++ b/api/SharpHoundCommonLib.Processors.ParsedCertificate.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

ParsedCertificate(Byte[])

@@ -172,10 +172,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

BasicConstraintPathLength

@@ -202,10 +202,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Chain

@@ -232,10 +232,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

HasBasicConstraints

@@ -262,10 +262,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Name

@@ -292,10 +292,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Thumbprint

diff --git a/api/SharpHoundCommonLib.Processors.PortScanner.html b/api/SharpHoundCommonLib.Processors.PortScanner.html index 4cd0bddb..25309638 100644 --- a/api/SharpHoundCommonLib.Processors.PortScanner.html +++ b/api/SharpHoundCommonLib.Processors.PortScanner.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

PortScanner()

@@ -153,10 +153,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

PortScanner(ILogger)

@@ -187,10 +187,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

CheckPort(String, Int32, Int32)

@@ -247,10 +247,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ClearCache()

diff --git a/api/SharpHoundCommonLib.Processors.RegistryResult.html b/api/SharpHoundCommonLib.Processors.RegistryResult.html index 033ba59c..82929cad 100644 --- a/api/SharpHoundCommonLib.Processors.RegistryResult.html +++ b/api/SharpHoundCommonLib.Processors.RegistryResult.html @@ -145,10 +145,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Value

diff --git a/api/SharpHoundCommonLib.Processors.SPNProcessors.html b/api/SharpHoundCommonLib.Processors.SPNProcessors.html index 2cc181f5..62cff9e2 100644 --- a/api/SharpHoundCommonLib.Processors.SPNProcessors.html +++ b/api/SharpHoundCommonLib.Processors.SPNProcessors.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SPNProcessors(ILDAPUtils, ILogger)

@@ -177,10 +177,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ReadSPNTargets(ResolvedSearchResult, ISearchResultEntry)

@@ -229,10 +229,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ReadSPNTargets(String[], String, String)

diff --git a/api/SharpHoundCommonLib.Processors.UserProperties.html b/api/SharpHoundCommonLib.Processors.UserProperties.html index 7074ef99..3c323102 100644 --- a/api/SharpHoundCommonLib.Processors.UserProperties.html +++ b/api/SharpHoundCommonLib.Processors.UserProperties.html @@ -138,10 +138,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

AllowedToDelegate

@@ -168,10 +168,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Props

@@ -198,10 +198,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SidHistory

diff --git a/api/SharpHoundCommonLib.Processors.UserRightsAssignmentProcessor.html b/api/SharpHoundCommonLib.Processors.UserRightsAssignmentProcessor.html index 2e58bff1..386e0631 100644 --- a/api/SharpHoundCommonLib.Processors.UserRightsAssignmentProcessor.html +++ b/api/SharpHoundCommonLib.Processors.UserRightsAssignmentProcessor.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

UserRightsAssignmentProcessor(ILDAPUtils, ILogger)

@@ -177,10 +177,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetUserRightsAssignments(ResolvedSearchResult, String[])

@@ -229,10 +229,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetUserRightsAssignments(String, String, String, Boolean, String[])

@@ -299,10 +299,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenLSAPolicy(String)

@@ -348,10 +348,10 @@

Events

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerStatusEvent

diff --git a/api/SharpHoundCommonLib.ResolvedSearchResult.html b/api/SharpHoundCommonLib.ResolvedSearchResult.html index 4aa6ea01..10896509 100644 --- a/api/SharpHoundCommonLib.ResolvedSearchResult.html +++ b/api/SharpHoundCommonLib.ResolvedSearchResult.html @@ -135,10 +135,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Deleted

@@ -165,10 +165,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DisplayName

@@ -195,10 +195,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Domain

@@ -225,10 +225,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainSid

@@ -255,10 +255,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsDomainController

@@ -285,10 +285,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectId

@@ -315,10 +315,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectType

@@ -347,10 +347,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ToString()

diff --git a/api/SharpHoundCommonLib.SHRegistryKey.html b/api/SharpHoundCommonLib.SHRegistryKey.html index 345be31f..13718828 100644 --- a/api/SharpHoundCommonLib.SHRegistryKey.html +++ b/api/SharpHoundCommonLib.SHRegistryKey.html @@ -142,10 +142,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SHRegistryKey(RegistryHive, String)

@@ -181,10 +181,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetValue(String, String)

diff --git a/api/SharpHoundCommonLib.SearchResultEntryWrapper.html b/api/SharpHoundCommonLib.SearchResultEntryWrapper.html index 948be7c4..0348cc5b 100644 --- a/api/SharpHoundCommonLib.SearchResultEntryWrapper.html +++ b/api/SharpHoundCommonLib.SearchResultEntryWrapper.html @@ -142,10 +142,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SearchResultEntryWrapper(SearchResultEntry, ILDAPUtils, ILogger)

@@ -186,10 +186,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

DistinguishedName

@@ -218,10 +218,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetArrayProperty(String)

@@ -265,10 +265,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetByteArrayProperty(String)

@@ -312,10 +312,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetByteProperty(String)

@@ -359,10 +359,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetCertificateArrayProperty(String)

@@ -406,10 +406,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetEntry()

@@ -436,10 +436,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetGuid()

@@ -466,10 +466,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetIntProperty(String, out Int32)

@@ -518,10 +518,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetLabel()

@@ -548,10 +548,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetObjectIdentifier()

@@ -578,10 +578,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetProperty(String)

@@ -625,10 +625,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetSid()

@@ -655,10 +655,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

HasLAPS()

@@ -685,10 +685,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsDeleted()

@@ -715,10 +715,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsGMSA()

@@ -745,10 +745,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsMSA()

@@ -775,10 +775,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

PropCount(String)

@@ -822,10 +822,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

PropertyNames()

@@ -852,10 +852,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

ResolveBloodHoundInfo()

diff --git a/api/SharpHoundCommonLib.WellKnownPrincipal.html b/api/SharpHoundCommonLib.WellKnownPrincipal.html index d7a4f3ae..ef9501ce 100644 --- a/api/SharpHoundCommonLib.WellKnownPrincipal.html +++ b/api/SharpHoundCommonLib.WellKnownPrincipal.html @@ -138,10 +138,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetWellKnownPrincipal(String, out TypedPrincipal)

diff --git a/api/SharpHoundRPC.Extensions.html b/api/SharpHoundRPC.Extensions.html index ee04e016..7419479c 100644 --- a/api/SharpHoundRPC.Extensions.html +++ b/api/SharpHoundRPC.Extensions.html @@ -138,10 +138,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetBytes(SecurityIdentifier)

@@ -185,10 +185,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

IsError(NtStatus)

@@ -232,10 +232,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Rid(SecurityIdentifier)

diff --git a/api/SharpHoundRPC.Handles.BasePointer.html b/api/SharpHoundRPC.Handles.BasePointer.html index c8245507..0c3769ae 100644 --- a/api/SharpHoundRPC.Handles.BasePointer.html +++ b/api/SharpHoundRPC.Handles.BasePointer.html @@ -184,10 +184,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

BasePointer()

@@ -199,10 +199,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

BasePointer(Boolean)

@@ -231,10 +231,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

BasePointer(IntPtr)

@@ -263,10 +263,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

BasePointer(IntPtr, Boolean)

@@ -302,10 +302,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetData<T>()

@@ -347,10 +347,10 @@
Type Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

GetEnumerable<T>(Int32)

diff --git a/api/SharpHoundRPC.Handles.LSAHandle.html b/api/SharpHoundRPC.Handles.LSAHandle.html index 3a46a5e4..d02a0474 100644 --- a/api/SharpHoundRPC.Handles.LSAHandle.html +++ b/api/SharpHoundRPC.Handles.LSAHandle.html @@ -178,10 +178,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

LSAHandle()

@@ -193,10 +193,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

LSAHandle(Boolean)

@@ -225,10 +225,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

LSAHandle(IntPtr, Boolean)

@@ -264,10 +264,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Finalize()

@@ -279,10 +279,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

ReleaseHandle()

diff --git a/api/SharpHoundRPC.Handles.LSAPointer.html b/api/SharpHoundRPC.Handles.LSAPointer.html index ea3f06f1..394573ff 100644 --- a/api/SharpHoundRPC.Handles.LSAPointer.html +++ b/api/SharpHoundRPC.Handles.LSAPointer.html @@ -185,10 +185,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

LSAPointer()

@@ -200,10 +200,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

LSAPointer(IntPtr)

@@ -232,10 +232,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

LSAPointer(IntPtr, Boolean)

@@ -271,10 +271,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ReleaseHandle()

diff --git a/api/SharpHoundRPC.Handles.NetAPIPointer.html b/api/SharpHoundRPC.Handles.NetAPIPointer.html index 211c2250..11a5b104 100644 --- a/api/SharpHoundRPC.Handles.NetAPIPointer.html +++ b/api/SharpHoundRPC.Handles.NetAPIPointer.html @@ -185,10 +185,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

NetAPIPointer()

@@ -200,10 +200,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

NetAPIPointer(IntPtr)

@@ -232,10 +232,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

NetAPIPointer(IntPtr, Boolean)

@@ -271,10 +271,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ReleaseHandle()

diff --git a/api/SharpHoundRPC.Handles.SAMHandle.html b/api/SharpHoundRPC.Handles.SAMHandle.html index 0b3bd933..760ae647 100644 --- a/api/SharpHoundRPC.Handles.SAMHandle.html +++ b/api/SharpHoundRPC.Handles.SAMHandle.html @@ -178,10 +178,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SAMHandle()

@@ -193,10 +193,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

SAMHandle(IntPtr)

@@ -225,10 +225,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

SAMHandle(IntPtr, Boolean)

@@ -264,10 +264,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Finalize()

@@ -279,10 +279,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

ReleaseHandle()

diff --git a/api/SharpHoundRPC.Handles.SAMPointer.html b/api/SharpHoundRPC.Handles.SAMPointer.html index 4e0f3539..a98c6801 100644 --- a/api/SharpHoundRPC.Handles.SAMPointer.html +++ b/api/SharpHoundRPC.Handles.SAMPointer.html @@ -186,10 +186,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SAMPointer()

@@ -201,10 +201,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

SAMPointer(IntPtr)

@@ -233,10 +233,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

SAMPointer(IntPtr, Boolean)

@@ -272,10 +272,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ReleaseHandle()

diff --git a/api/SharpHoundRPC.Handles.SAMSidArray.html b/api/SharpHoundRPC.Handles.SAMSidArray.html index 187e071a..778ab39a 100644 --- a/api/SharpHoundRPC.Handles.SAMSidArray.html +++ b/api/SharpHoundRPC.Handles.SAMSidArray.html @@ -189,10 +189,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SAMSidArray()

@@ -204,10 +204,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

SAMSidArray(IntPtr)

@@ -236,10 +236,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

SAMSidArray(IntPtr, Boolean)

@@ -275,10 +275,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetData(Int32)

diff --git a/api/SharpHoundRPC.LSANative.LSAStructs.LSAReferencedDomains.html b/api/SharpHoundRPC.LSANative.LSAStructs.LSAReferencedDomains.html index d9857fdb..0fce5d85 100644 --- a/api/SharpHoundRPC.LSANative.LSAStructs.LSAReferencedDomains.html +++ b/api/SharpHoundRPC.LSANative.LSAStructs.LSAReferencedDomains.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

Domains

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Entries

diff --git a/api/SharpHoundRPC.LSANative.LSAStructs.LSATranslatedNames.html b/api/SharpHoundRPC.LSANative.LSAStructs.LSATranslatedNames.html index 788f4386..ecebca50 100644 --- a/api/SharpHoundRPC.LSANative.LSAStructs.LSATranslatedNames.html +++ b/api/SharpHoundRPC.LSANative.LSAStructs.LSATranslatedNames.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

DomainIndex

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Name

@@ -188,10 +188,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Use

diff --git a/api/SharpHoundRPC.LSANative.LSAStructs.LSATrustInformation.html b/api/SharpHoundRPC.LSANative.LSAStructs.LSATrustInformation.html index 8f33c5f6..b55a2857 100644 --- a/api/SharpHoundRPC.LSANative.LSAStructs.LSATrustInformation.html +++ b/api/SharpHoundRPC.LSANative.LSAStructs.LSATrustInformation.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

Name

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Sid

diff --git a/api/SharpHoundRPC.LSANative.LSAStructs.ObjectAttributes.html b/api/SharpHoundRPC.LSANative.LSAStructs.ObjectAttributes.html index 6f392678..67abb531 100644 --- a/api/SharpHoundRPC.LSANative.LSAStructs.ObjectAttributes.html +++ b/api/SharpHoundRPC.LSANative.LSAStructs.ObjectAttributes.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

Attributes

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Length

@@ -188,10 +188,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectName

@@ -217,10 +217,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RootDirectory

@@ -246,10 +246,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SecurityDescriptor

@@ -275,10 +275,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SecurityQualityOfService

@@ -306,10 +306,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Dispose()

diff --git a/api/SharpHoundRPC.LSANative.LSAStructs.PolicyAccountDomainInfo.html b/api/SharpHoundRPC.LSANative.LSAStructs.PolicyAccountDomainInfo.html index 2e1f4dab..223a43b8 100644 --- a/api/SharpHoundRPC.LSANative.LSAStructs.PolicyAccountDomainInfo.html +++ b/api/SharpHoundRPC.LSANative.LSAStructs.PolicyAccountDomainInfo.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

DomainName

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainSid

diff --git a/api/SharpHoundRPC.LSANative.UserRights.html b/api/SharpHoundRPC.LSANative.UserRights.html index d9e1a127..8e4f1e1d 100644 --- a/api/SharpHoundRPC.LSANative.UserRights.html +++ b/api/SharpHoundRPC.LSANative.UserRights.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AllPrivileges

@@ -167,10 +167,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

AssignPrimaryToken

@@ -196,10 +196,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Audit

@@ -225,10 +225,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Backup

@@ -254,10 +254,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

BatchLogon

@@ -283,10 +283,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ChangeNotify

@@ -312,10 +312,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CreateGlobal

@@ -341,10 +341,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CreatePagefile

@@ -370,10 +370,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CreatePermanent

@@ -399,10 +399,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source
@@ -428,10 +428,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

CreateToken

@@ -457,10 +457,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Debug

@@ -486,10 +486,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyBatchLogon

@@ -515,10 +515,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyInteractiveLogon

@@ -544,10 +544,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyNetworkLogon

@@ -573,10 +573,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyRemoteInteractiveLogon

@@ -602,10 +602,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DenyServiceLogon

@@ -631,10 +631,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnableDelegation

@@ -660,10 +660,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Impersonate

@@ -689,10 +689,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IncreaseBasePriority

@@ -718,10 +718,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IncreaseQuota

@@ -747,10 +747,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IncreaseWorkingSet

@@ -776,10 +776,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

InteractiveLogon

@@ -805,10 +805,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LoadDriver

@@ -834,10 +834,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LockMemory

@@ -863,10 +863,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

MachineAccount

@@ -892,10 +892,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ManageVolume

@@ -921,10 +921,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

NetworkLogon

@@ -950,10 +950,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ProfileSingleProcess

@@ -979,10 +979,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Relabel

@@ -1008,10 +1008,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RemoteInteractiveLogon

@@ -1037,10 +1037,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RemoteShutdown

@@ -1066,10 +1066,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Restore

@@ -1095,10 +1095,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Security

@@ -1124,10 +1124,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ServiceLogon

@@ -1153,10 +1153,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Shutdown

@@ -1182,10 +1182,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SyncAgent

@@ -1211,10 +1211,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SystemEnvironment

@@ -1240,10 +1240,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SystemProfile

@@ -1269,10 +1269,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SystemTime

@@ -1298,10 +1298,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TakeOwnership

@@ -1327,10 +1327,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Tcb

@@ -1356,10 +1356,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TimeZone

@@ -1385,10 +1385,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

TrustedCredManAccess

@@ -1414,10 +1414,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Undock

diff --git a/api/SharpHoundRPC.NetAPINative.NetAPIMethods.html b/api/SharpHoundRPC.NetAPINative.NetAPIMethods.html index 1b088eb9..9e7840d0 100644 --- a/api/SharpHoundRPC.NetAPINative.NetAPIMethods.html +++ b/api/SharpHoundRPC.NetAPINative.NetAPIMethods.html @@ -138,10 +138,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

DsGetDcName(String, String)

@@ -190,10 +190,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

NetSessionEnum(String)

@@ -237,10 +237,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

NetWkstaGetInfo(String)

@@ -284,10 +284,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

NetWkstaUserEnum(String)

diff --git a/api/SharpHoundRPC.NetAPINative.NetAPIResult-1.html b/api/SharpHoundRPC.NetAPINative.NetAPIResult-1.html index 4406dcac..a4a91310 100644 --- a/api/SharpHoundRPC.NetAPINative.NetAPIResult-1.html +++ b/api/SharpHoundRPC.NetAPINative.NetAPIResult-1.html @@ -153,10 +153,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Error

@@ -183,10 +183,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsFailed

@@ -213,10 +213,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsSuccess

@@ -243,10 +243,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Status

@@ -273,10 +273,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Value

@@ -305,10 +305,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Fail(NetAPIEnums.NetAPIStatus)

@@ -352,10 +352,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Fail(String)

@@ -399,10 +399,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Ok(T)

@@ -448,10 +448,10 @@

Operators

| - Improve this Doc + Improve this Doc - View Source + View Source

Implicit(T to NetAPIResult<T>)

@@ -495,10 +495,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Implicit(NetAPIEnums.NetAPIStatus to NetAPIResult<T>)

@@ -542,10 +542,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Implicit(String to NetAPIResult<T>)

diff --git a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.DomainControllerInfo.html b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.DomainControllerInfo.html index 68b8286b..499f2dff 100644 --- a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.DomainControllerInfo.html +++ b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.DomainControllerInfo.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

ClientSiteName

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DcSiteName

@@ -188,10 +188,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DnsForestName

@@ -217,10 +217,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainControllerAddress

@@ -246,10 +246,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainControllerAddressType

@@ -275,10 +275,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainControllerName

@@ -304,10 +304,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainGuid

@@ -333,10 +333,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainName

@@ -362,10 +362,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Flags

diff --git a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.GuidClass.html b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.GuidClass.html index b05322ec..7ed1798d 100644 --- a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.GuidClass.html +++ b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.GuidClass.html @@ -138,10 +138,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

TheGuid

diff --git a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.SessionInfo10.html b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.SessionInfo10.html index 9386201d..fe4f2e01 100644 --- a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.SessionInfo10.html +++ b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.SessionInfo10.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

CName

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IdleTIme

@@ -188,10 +188,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Time

@@ -217,10 +217,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Username

diff --git a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.WkstaUserInfo1.html b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.WkstaUserInfo1.html index cd442d03..17e3ce99 100644 --- a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.WkstaUserInfo1.html +++ b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.WkstaUserInfo1.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

LogonDomain

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LogonServer

@@ -188,10 +188,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

OtherDomains

@@ -217,10 +217,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Username

diff --git a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.WorkstationInfo100.html b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.WorkstationInfo100.html index ff66f4f7..8c018434 100644 --- a/api/SharpHoundRPC.NetAPINative.NetAPIStructs.WorkstationInfo100.html +++ b/api/SharpHoundRPC.NetAPINative.NetAPIStructs.WorkstationInfo100.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerName

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LanGroup

@@ -188,10 +188,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

MajorVersion

@@ -217,10 +217,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

MinorVersion

@@ -246,10 +246,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

PlatformId

diff --git a/api/SharpHoundRPC.NetAPINative.NetSessionEnumResults.html b/api/SharpHoundRPC.NetAPINative.NetSessionEnumResults.html index 26ee66d7..7fdceee7 100644 --- a/api/SharpHoundRPC.NetAPINative.NetSessionEnumResults.html +++ b/api/SharpHoundRPC.NetAPINative.NetSessionEnumResults.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

NetSessionEnumResults(String, String)

@@ -177,10 +177,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerName

@@ -207,10 +207,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Username

diff --git a/api/SharpHoundRPC.NetAPINative.NetWkstaUserEnumResults.html b/api/SharpHoundRPC.NetAPINative.NetWkstaUserEnumResults.html index 3ab75ca6..d18f0257 100644 --- a/api/SharpHoundRPC.NetAPINative.NetWkstaUserEnumResults.html +++ b/api/SharpHoundRPC.NetAPINative.NetWkstaUserEnumResults.html @@ -138,10 +138,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

NetWkstaUserEnumResults(String, String)

@@ -177,10 +177,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

LogonDomain

@@ -207,10 +207,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Username

diff --git a/api/SharpHoundRPC.RPCException.html b/api/SharpHoundRPC.RPCException.html index af1e7e73..42f89074 100644 --- a/api/SharpHoundRPC.RPCException.html +++ b/api/SharpHoundRPC.RPCException.html @@ -174,10 +174,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

RPCException(String, NtStatus)

@@ -211,10 +211,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

RPCException(String, String)

@@ -250,10 +250,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

AliasNotFound

@@ -279,10 +279,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Connect

@@ -308,10 +308,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

DomainNotFound

@@ -337,10 +337,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnumerateAliases

@@ -366,10 +366,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

EnumerateDomains

@@ -395,10 +395,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GetAliasMembers

@@ -424,10 +424,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

GetMachineSid

@@ -453,10 +453,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupDomain

@@ -482,10 +482,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupIds

@@ -511,10 +511,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenAlias

@@ -540,10 +540,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenDomain

@@ -569,10 +569,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ServerNotInitialized

@@ -600,10 +600,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

ToString()

diff --git a/api/SharpHoundRPC.Result-1.html b/api/SharpHoundRPC.Result-1.html index ce09ff97..4885aab5 100644 --- a/api/SharpHoundRPC.Result-1.html +++ b/api/SharpHoundRPC.Result-1.html @@ -153,10 +153,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Error

@@ -183,10 +183,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsFailed

@@ -213,10 +213,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

IsSuccess

@@ -243,10 +243,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SError

@@ -273,10 +273,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Status

@@ -303,10 +303,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Value

@@ -335,10 +335,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Fail(NtStatus)

@@ -382,10 +382,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Fail(String)

@@ -429,10 +429,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Ok(T)

@@ -478,10 +478,10 @@

Operators

| - Improve this Doc + Improve this Doc - View Source + View Source

Implicit(T to Result<T>)

@@ -525,10 +525,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Implicit(NtStatus to Result<T>)

@@ -572,10 +572,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

Implicit(String to Result<T>)

diff --git a/api/SharpHoundRPC.SAMRPCNative.SAMStructs.ObjectAttributes.html b/api/SharpHoundRPC.SAMRPCNative.SAMStructs.ObjectAttributes.html index ee361bdb..a3a673b3 100644 --- a/api/SharpHoundRPC.SAMRPCNative.SAMStructs.ObjectAttributes.html +++ b/api/SharpHoundRPC.SAMRPCNative.SAMStructs.ObjectAttributes.html @@ -134,10 +134,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

Attributes

@@ -163,10 +163,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Length

@@ -192,10 +192,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

ObjectName

@@ -221,10 +221,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Qos

@@ -250,10 +250,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

RootDirectory

@@ -279,10 +279,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

SID

@@ -310,10 +310,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Dispose()

diff --git a/api/SharpHoundRPC.SAMRPCNative.SAMStructs.SamRidEnumeration.html b/api/SharpHoundRPC.SAMRPCNative.SAMStructs.SamRidEnumeration.html index 391cb38f..4dfd7e49 100644 --- a/api/SharpHoundRPC.SAMRPCNative.SAMStructs.SamRidEnumeration.html +++ b/api/SharpHoundRPC.SAMRPCNative.SAMStructs.SamRidEnumeration.html @@ -130,10 +130,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

Name

@@ -159,10 +159,10 @@
Field Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Rid

diff --git a/api/SharpHoundRPC.Shared.SharedStructs.UnicodeString.html b/api/SharpHoundRPC.Shared.SharedStructs.UnicodeString.html index 35d281c0..0e2d9a3b 100644 --- a/api/SharpHoundRPC.Shared.SharedStructs.UnicodeString.html +++ b/api/SharpHoundRPC.Shared.SharedStructs.UnicodeString.html @@ -131,10 +131,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

UnicodeString(String)

@@ -165,10 +165,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Dispose()

@@ -180,10 +180,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

ToString()

diff --git a/api/SharpHoundRPC.Wrappers.ILSAPolicy.html b/api/SharpHoundRPC.Wrappers.ILSAPolicy.html index fffc5f8a..e8e67696 100644 --- a/api/SharpHoundRPC.Wrappers.ILSAPolicy.html +++ b/api/SharpHoundRPC.Wrappers.ILSAPolicy.html @@ -109,10 +109,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetLocalDomainInformation()

@@ -139,10 +139,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetPrincipalsWithPrivilege(String)

@@ -186,10 +186,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetResolvedPrincipalsWithPrivilege(String)

@@ -233,10 +233,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupSid(SecurityIdentifier)

@@ -280,10 +280,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupSids(SecurityIdentifier[])

diff --git a/api/SharpHoundRPC.Wrappers.ISAMAlias.html b/api/SharpHoundRPC.Wrappers.ISAMAlias.html index 5f11434e..5717661d 100644 --- a/api/SharpHoundRPC.Wrappers.ISAMAlias.html +++ b/api/SharpHoundRPC.Wrappers.ISAMAlias.html @@ -109,10 +109,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetMembers()

diff --git a/api/SharpHoundRPC.Wrappers.ISAMDomain.html b/api/SharpHoundRPC.Wrappers.ISAMDomain.html index 2d079d92..e1cad8b2 100644 --- a/api/SharpHoundRPC.Wrappers.ISAMDomain.html +++ b/api/SharpHoundRPC.Wrappers.ISAMDomain.html @@ -109,10 +109,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetAliases()

@@ -139,10 +139,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupPrincipalByRid(Int32)

@@ -186,10 +186,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenAlias(Int32, SAMEnums.AliasOpenFlags)

@@ -238,10 +238,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenAlias(String)

diff --git a/api/SharpHoundRPC.Wrappers.ISAMServer.html b/api/SharpHoundRPC.Wrappers.ISAMServer.html index 53320487..d336de1e 100644 --- a/api/SharpHoundRPC.Wrappers.ISAMServer.html +++ b/api/SharpHoundRPC.Wrappers.ISAMServer.html @@ -109,10 +109,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetDomains()

@@ -139,10 +139,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetMachineSid(String)

@@ -186,10 +186,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupDomain(String)

@@ -233,10 +233,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupPrincipalBySid(SecurityIdentifier)

@@ -280,10 +280,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenDomain(SecurityIdentifier, SAMEnums.DomainAccessMask)

@@ -332,10 +332,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenDomain(String, SAMEnums.DomainAccessMask)

diff --git a/api/SharpHoundRPC.Wrappers.LSABase.html b/api/SharpHoundRPC.Wrappers.LSABase.html index 5c1a2054..9ec2a5fe 100644 --- a/api/SharpHoundRPC.Wrappers.LSABase.html +++ b/api/SharpHoundRPC.Wrappers.LSABase.html @@ -143,10 +143,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

LSABase(LSAHandle)

@@ -177,10 +177,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

Handle

@@ -208,10 +208,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Dispose()

@@ -223,10 +223,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

Dispose(Boolean)

@@ -255,10 +255,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

ReleaseHandle()

diff --git a/api/SharpHoundRPC.Wrappers.LSAPolicy.html b/api/SharpHoundRPC.Wrappers.LSAPolicy.html index a57e5821..54f20831 100644 --- a/api/SharpHoundRPC.Wrappers.LSAPolicy.html +++ b/api/SharpHoundRPC.Wrappers.LSAPolicy.html @@ -156,10 +156,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

LSAPolicy(String, LSAHandle)

@@ -195,10 +195,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetLocalDomainInformation()

@@ -225,10 +225,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetPrincipalsWithPrivilege(String)

@@ -272,10 +272,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetResolvedPrincipalsWithPrivilege(String)

diff --git a/api/SharpHoundRPC.Wrappers.SAMAlias.html b/api/SharpHoundRPC.Wrappers.SAMAlias.html index 9b21777c..eeb81d45 100644 --- a/api/SharpHoundRPC.Wrappers.SAMAlias.html +++ b/api/SharpHoundRPC.Wrappers.SAMAlias.html @@ -156,10 +156,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SAMAlias(SAMHandle)

@@ -190,10 +190,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

Name

@@ -220,10 +220,10 @@
Property Value
| - Improve this Doc + Improve this Doc - View Source + View Source

Rid

@@ -252,10 +252,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetMembers()

diff --git a/api/SharpHoundRPC.Wrappers.SAMBase.html b/api/SharpHoundRPC.Wrappers.SAMBase.html index ff845777..9957323c 100644 --- a/api/SharpHoundRPC.Wrappers.SAMBase.html +++ b/api/SharpHoundRPC.Wrappers.SAMBase.html @@ -145,10 +145,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SAMBase(SAMHandle)

@@ -179,10 +179,10 @@

Fields

| - Improve this Doc + Improve this Doc - View Source + View Source

Handle

@@ -210,10 +210,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Dispose()

@@ -225,10 +225,10 @@
Declaration
| - Improve this Doc + Improve this Doc - View Source + View Source

Dispose(Boolean)

@@ -257,10 +257,10 @@
Parameters
| - Improve this Doc + Improve this Doc - View Source + View Source

ReleaseHandle()

diff --git a/api/SharpHoundRPC.Wrappers.SAMDomain.html b/api/SharpHoundRPC.Wrappers.SAMDomain.html index 19ee83e4..870affb8 100644 --- a/api/SharpHoundRPC.Wrappers.SAMDomain.html +++ b/api/SharpHoundRPC.Wrappers.SAMDomain.html @@ -156,10 +156,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SAMDomain(SAMHandle)

@@ -190,10 +190,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

GetAliases()

@@ -220,10 +220,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupPrincipalByRid(Int32)

@@ -267,10 +267,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenAlias(Int32, SAMEnums.AliasOpenFlags)

@@ -319,10 +319,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenAlias(String)

diff --git a/api/SharpHoundRPC.Wrappers.SAMServer.html b/api/SharpHoundRPC.Wrappers.SAMServer.html index 6d040303..511e3a2e 100644 --- a/api/SharpHoundRPC.Wrappers.SAMServer.html +++ b/api/SharpHoundRPC.Wrappers.SAMServer.html @@ -153,10 +153,10 @@

Constructors

| - Improve this Doc + Improve this Doc - View Source + View Source

SAMServer(SAMHandle, String)

@@ -192,10 +192,10 @@

Properties

| - Improve this Doc + Improve this Doc - View Source + View Source

ComputerName

@@ -224,10 +224,10 @@

Methods

| - Improve this Doc + Improve this Doc - View Source + View Source

Dispose(Boolean)

@@ -258,10 +258,10 @@
Overrides
SAMBase.Dispose(Boolean)
| - Improve this Doc + Improve this Doc - View Source + View Source

GetDomains()

@@ -288,10 +288,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

GetMachineSid(String)

@@ -335,10 +335,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupDomain(String)

@@ -382,10 +382,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

LookupPrincipalBySid(SecurityIdentifier)

@@ -429,10 +429,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenDomain(SecurityIdentifier, SAMEnums.DomainAccessMask)

@@ -481,10 +481,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenDomain(String, SAMEnums.DomainAccessMask)

@@ -533,10 +533,10 @@
Returns
| - Improve this Doc + Improve this Doc - View Source + View Source

OpenServer(String, SAMEnums.SamAccessMasks)

diff --git a/coverage/report/SharpHoundCommonLib_ACE.html b/coverage/report/SharpHoundCommonLib_ACE.html index fee0b8e8..35ebe4c8 100644 --- a/coverage/report/SharpHoundCommonLib_ACE.html +++ b/coverage/report/SharpHoundCommonLib_ACE.html @@ -87,7 +87,7 @@

D:\a\Sha  43} - +

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_ACLProcessor.html b/coverage/report/SharpHoundCommonLib_ACLProcessor.html index c820729f..2dc6cc8a 100644 --- a/coverage/report/SharpHoundCommonLib_ACLProcessor.html +++ b/coverage/report/SharpHoundCommonLib_ACLProcessor.html @@ -635,7 +635,7 @@

 585} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_APIResult.html b/coverage/report/SharpHoundCommonLib_APIResult.html index 5f7ac4da..7626a0bf 100644 --- a/coverage/report/SharpHoundCommonLib_APIResult.html +++ b/coverage/report/SharpHoundCommonLib_APIResult.html @@ -41,7 +41,7 @@

D:  8} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_AceRegistryAPIResult.html b/coverage/report/SharpHoundCommonLib_AceRegistryAPIResult.html index 43c365ae..4b157380 100644 --- a/coverage/report/SharpHoundCommonLib_AceRegistryAPIResult.html +++ b/coverage/report/SharpHoundCommonLib_AceRegistryAPIResult.html @@ -42,7 +42,7 @@

 9} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_ActiveDirectoryRuleDescriptor.html b/coverage/report/SharpHoundCommonLib_ActiveDirectoryRuleDescriptor.html index c4e98022..5fa93824 100644 --- a/coverage/report/SharpHoundCommonLib_ActiveDirectoryRuleDescriptor.html +++ b/coverage/report/SharpHoundCommonLib_ActiveDirectoryRuleDescriptor.html @@ -149,7 +149,7 @@

D:\a  102} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_ActiveDirectorySecurityDescriptor.html b/coverage/report/SharpHoundCommonLib_ActiveDirectorySecurityDescriptor.html index d2cba548..96f92585 100644 --- a/coverage/report/SharpHoundCommonLib_ActiveDirectorySecurityDescriptor.html +++ b/coverage/report/SharpHoundCommonLib_ActiveDirectorySecurityDescriptor.html @@ -148,7 +148,7 @@

D:\a  102} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_BoolRegistryAPIResult.html b/coverage/report/SharpHoundCommonLib_BoolRegistryAPIResult.html index 1ba7745f..81011286 100644 --- a/coverage/report/SharpHoundCommonLib_BoolRegistryAPIResult.html +++ b/coverage/report/SharpHoundCommonLib_BoolRegistryAPIResult.html @@ -40,7 +40,7 @@

 7} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CARegistryData.html b/coverage/report/SharpHoundCommonLib_CARegistryData.html index ea605062..5a359d7c 100644 --- a/coverage/report/SharpHoundCommonLib_CARegistryData.html +++ b/coverage/report/SharpHoundCommonLib_CARegistryData.html @@ -42,7 +42,7 @@

 9} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CSVComputerStatus.html b/coverage/report/SharpHoundCommonLib_CSVComputerStatus.html index 17820319..36f4d08b 100644 --- a/coverage/report/SharpHoundCommonLib_CSVComputerStatus.html +++ b/coverage/report/SharpHoundCommonLib_CSVComputerStatus.html @@ -89,7 +89,7 @@

D:\a\  47} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_Cache.html b/coverage/report/SharpHoundCommonLib_Cache.html index 793a434b..daa8f67d 100644 --- a/coverage/report/SharpHoundCommonLib_Cache.html +++ b/coverage/report/SharpHoundCommonLib_Cache.html @@ -265,7 +265,7 @@

D:\a\SharpHoundCo  205} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CachedLocalItem.html b/coverage/report/SharpHoundCommonLib_CachedLocalItem.html index 9b2408f4..bd02cfe8 100644 --- a/coverage/report/SharpHoundCommonLib_CachedLocalItem.html +++ b/coverage/report/SharpHoundCommonLib_CachedLocalItem.html @@ -56,7 +56,7 @@

 16} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CertAbuseProcessor.html b/coverage/report/SharpHoundCommonLib_CertAbuseProcessor.html index 8eeeb178..2bcb1393 100644 --- a/coverage/report/SharpHoundCommonLib_CertAbuseProcessor.html +++ b/coverage/report/SharpHoundCommonLib_CertAbuseProcessor.html @@ -510,7 +510,7 @@

 460} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CertRegistryResult.html b/coverage/report/SharpHoundCommonLib_CertRegistryResult.html index adf93787..44b8a1de 100644 --- a/coverage/report/SharpHoundCommonLib_CertRegistryResult.html +++ b/coverage/report/SharpHoundCommonLib_CertRegistryResult.html @@ -493,7 +493,7 @@

 460} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CertificateExtension.html b/coverage/report/SharpHoundCommonLib_CertificateExtension.html index bd9136c1..d8dff530 100644 --- a/coverage/report/SharpHoundCommonLib_CertificateExtension.html +++ b/coverage/report/SharpHoundCommonLib_CertificateExtension.html @@ -57,7 +57,7 @@

 17} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CommonFilters.html b/coverage/report/SharpHoundCommonLib_CommonFilters.html index c7f80621..3b49c4d6 100644 --- a/coverage/report/SharpHoundCommonLib_CommonFilters.html +++ b/coverage/report/SharpHoundCommonLib_CommonFilters.html @@ -70,7 +70,7 @@

 29} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CommonLib.html b/coverage/report/SharpHoundCommonLib_CommonLib.html index 2e211101..e39a4252 100644 --- a/coverage/report/SharpHoundCommonLib_CommonLib.html +++ b/coverage/report/SharpHoundCommonLib_CommonLib.html @@ -89,7 +89,7 @@

D:\a\SharpHou  47} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CommonOids.html b/coverage/report/SharpHoundCommonLib_CommonOids.html index 4f016f79..f442e583 100644 --- a/coverage/report/SharpHoundCommonLib_CommonOids.html +++ b/coverage/report/SharpHoundCommonLib_CommonOids.html @@ -53,7 +53,7 @@

D:\a\Sh  13} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CommonPaths.html b/coverage/report/SharpHoundCommonLib_CommonPaths.html index 5b6acccf..cd47a2be 100644 --- a/coverage/report/SharpHoundCommonLib_CommonPaths.html +++ b/coverage/report/SharpHoundCommonLib_CommonPaths.html @@ -56,7 +56,7 @@

 16 -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_CommonProperties.html b/coverage/report/SharpHoundCommonLib_CommonProperties.html index aa603d4c..efbe3e62 100644 --- a/coverage/report/SharpHoundCommonLib_CommonProperties.html +++ b/coverage/report/SharpHoundCommonLib_CommonProperties.html @@ -130,7 +130,7 @@

 90} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_Computer.html b/coverage/report/SharpHoundCommonLib_Computer.html index 02e944e6..626077f1 100644 --- a/coverage/report/SharpHoundCommonLib_Computer.html +++ b/coverage/report/SharpHoundCommonLib_Computer.html @@ -85,7 +85,7 @@

D:\  52} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_ComputerAvailability.html b/coverage/report/SharpHoundCommonLib_ComputerAvailability.html index 20055228..bd402f34 100644 --- a/coverage/report/SharpHoundCommonLib_ComputerAvailability.html +++ b/coverage/report/SharpHoundCommonLib_ComputerAvailability.html @@ -203,7 +203,7 @@

 158} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_ComputerProperties.html b/coverage/report/SharpHoundCommonLib_ComputerProperties.html index f19067d7..557dde7c 100644 --- a/coverage/report/SharpHoundCommonLib_ComputerProperties.html +++ b/coverage/report/SharpHoundCommonLib_ComputerProperties.html @@ -818,7 +818,7 @@

 785} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_ComputerSessionProcessor.html b/coverage/report/SharpHoundCommonLib_ComputerSessionProcessor.html index 46654cf0..f67053e5 100644 --- a/coverage/report/SharpHoundCommonLib_ComputerSessionProcessor.html +++ b/coverage/report/SharpHoundCommonLib_ComputerSessionProcessor.html @@ -404,7 +404,7 @@

 357} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_ComputerStatus.html b/coverage/report/SharpHoundCommonLib_ComputerStatus.html index 589777f9..28fb841e 100644 --- a/coverage/report/SharpHoundCommonLib_ComputerStatus.html +++ b/coverage/report/SharpHoundCommonLib_ComputerStatus.html @@ -92,7 +92,7 @@

D:\  52} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_Container.html b/coverage/report/SharpHoundCommonLib_Container.html index c5696b30..837f24b0 100644 --- a/coverage/report/SharpHoundCommonLib_Container.html +++ b/coverage/report/SharpHoundCommonLib_Container.html @@ -42,7 +42,7 @@

D:  9} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_ContainerProcessor.html b/coverage/report/SharpHoundCommonLib_ContainerProcessor.html index 76de643e..b97fa143 100644 --- a/coverage/report/SharpHoundCommonLib_ContainerProcessor.html +++ b/coverage/report/SharpHoundCommonLib_ContainerProcessor.html @@ -208,7 +208,7 @@

 159} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_DCRegistryData.html b/coverage/report/SharpHoundCommonLib_DCRegistryData.html index 518e4691..ba72766b 100644 --- a/coverage/report/SharpHoundCommonLib_DCRegistryData.html +++ b/coverage/report/SharpHoundCommonLib_DCRegistryData.html @@ -85,7 +85,7 @@

D:\  52} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_DCRegistryProcessor.html b/coverage/report/SharpHoundCommonLib_DCRegistryProcessor.html index 1c35293a..029e41e8 100644 --- a/coverage/report/SharpHoundCommonLib_DCRegistryProcessor.html +++ b/coverage/report/SharpHoundCommonLib_DCRegistryProcessor.html @@ -128,7 +128,7 @@

 87} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_Domain.html b/coverage/report/SharpHoundCommonLib_Domain.html index 51c011e5..212eeaa5 100644 --- a/coverage/report/SharpHoundCommonLib_Domain.html +++ b/coverage/report/SharpHoundCommonLib_Domain.html @@ -52,7 +52,7 @@

D:\a\  12} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_DomainTrust.html b/coverage/report/SharpHoundCommonLib_DomainTrust.html index bc84f9e6..72364408 100644 --- a/coverage/report/SharpHoundCommonLib_DomainTrust.html +++ b/coverage/report/SharpHoundCommonLib_DomainTrust.html @@ -47,7 +47,7 @@

 14} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_DomainTrustProcessor.html b/coverage/report/SharpHoundCommonLib_DomainTrustProcessor.html index ef5d6004..7d093f76 100644 --- a/coverage/report/SharpHoundCommonLib_DomainTrustProcessor.html +++ b/coverage/report/SharpHoundCommonLib_DomainTrustProcessor.html @@ -149,7 +149,7 @@

 106} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_EnrollmentAgentRegistryAPIResult.html b/coverage/report/SharpHoundCommonLib_EnrollmentAgentRegistryAPIResult.html index 86c0fbf1..687254b5 100644 --- a/coverage/report/SharpHoundCommonLib_EnrollmentAgentRegistryAPIResult.html +++ b/coverage/report/SharpHoundCommonLib_EnrollmentAgentRegistryAPIResult.html @@ -43,7 +43,7 @@

 10} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_EnrollmentAgentRestriction.html b/coverage/report/SharpHoundCommonLib_EnrollmentAgentRestriction.html index 3549dea7..442cf625 100644 --- a/coverage/report/SharpHoundCommonLib_EnrollmentAgentRestriction.html +++ b/coverage/report/SharpHoundCommonLib_EnrollmentAgentRestriction.html @@ -501,7 +501,7 @@

 460} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_EnterpriseCA.html b/coverage/report/SharpHoundCommonLib_EnterpriseCA.html index 597821bf..1379bba1 100644 --- a/coverage/report/SharpHoundCommonLib_EnterpriseCA.html +++ b/coverage/report/SharpHoundCommonLib_EnterpriseCA.html @@ -42,7 +42,7 @@

 9} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_Extensions.html b/coverage/report/SharpHoundCommonLib_Extensions.html index d746f06b..08df0130 100644 --- a/coverage/report/SharpHoundCommonLib_Extensions.html +++ b/coverage/report/SharpHoundCommonLib_Extensions.html @@ -467,7 +467,7 @@

D:\a\SharpHo  407} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_GPLink.html b/coverage/report/SharpHoundCommonLib_GPLink.html index 1e65ec52..81ce3e6f 100644 --- a/coverage/report/SharpHoundCommonLib_GPLink.html +++ b/coverage/report/SharpHoundCommonLib_GPLink.html @@ -79,7 +79,7 @@

D:\a\  36} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_GPOLocalGroupProcessor.html b/coverage/report/SharpHoundCommonLib_GPOLocalGroupProcessor.html index 77b8f0f8..ad080632 100644 --- a/coverage/report/SharpHoundCommonLib_GPOLocalGroupProcessor.html +++ b/coverage/report/SharpHoundCommonLib_GPOLocalGroupProcessor.html @@ -677,7 +677,7 @@

 627} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_Group.html b/coverage/report/SharpHoundCommonLib_Group.html index 8beb2a69..bdc54aa2 100644 --- a/coverage/report/SharpHoundCommonLib_Group.html +++ b/coverage/report/SharpHoundCommonLib_Group.html @@ -42,7 +42,7 @@

D:\a\S  9} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_GroupProcessor.html b/coverage/report/SharpHoundCommonLib_GroupProcessor.html index 713d83e1..5880d7eb 100644 --- a/coverage/report/SharpHoundCommonLib_GroupProcessor.html +++ b/coverage/report/SharpHoundCommonLib_GroupProcessor.html @@ -159,7 +159,7 @@

 115} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_Helpers.html b/coverage/report/SharpHoundCommonLib_Helpers.html index 8832bc7c..12f5724f 100644 --- a/coverage/report/SharpHoundCommonLib_Helpers.html +++ b/coverage/report/SharpHoundCommonLib_Helpers.html @@ -227,9 +227,9 @@

D:\a\SharpHound  171        /// <param name="target">Raw service principal name</param>  172        /// <returns>Stripped service principal name with (hopefully) just the hostname</returns>  173        public static string StripServicePrincipalName(string target) - 15174        { - 15175            return SPNRegex.IsMatch(target) ? target.Split('/')[1].Split(':')[0] : target; - 15176        } + 16174        { + 16175            return SPNRegex.IsMatch(target) ? target.Split('/')[1].Split(':')[0] : target; + 16176        }  177  178        /// <summary>  179        ///     Converts a string to its base64 representation @@ -393,7 +393,7 @@

D:\a\SharpHound  337} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_Impersonator.html b/coverage/report/SharpHoundCommonLib_Impersonator.html index 098af3e2..af9e17e1 100644 --- a/coverage/report/SharpHoundCommonLib_Impersonator.html +++ b/coverage/report/SharpHoundCommonLib_Impersonator.html @@ -246,7 +246,7 @@

D:\a\SharpH  199} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_IntRegistryAPIResult.html b/coverage/report/SharpHoundCommonLib_IntRegistryAPIResult.html index 6a03bb4d..296c4603 100644 --- a/coverage/report/SharpHoundCommonLib_IntRegistryAPIResult.html +++ b/coverage/report/SharpHoundCommonLib_IntRegistryAPIResult.html @@ -40,7 +40,7 @@

 7} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_LDAPConfig.html b/coverage/report/SharpHoundCommonLib_LDAPConfig.html index 1fb8926d..cac797cc 100644 --- a/coverage/report/SharpHoundCommonLib_LDAPConfig.html +++ b/coverage/report/SharpHoundCommonLib_LDAPConfig.html @@ -62,7 +62,7 @@

D:\a\SharpHo  21} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_LDAPFilter.html b/coverage/report/SharpHoundCommonLib_LDAPFilter.html index 0d521654..4fab173e 100644 --- a/coverage/report/SharpHoundCommonLib_LDAPFilter.html +++ b/coverage/report/SharpHoundCommonLib_LDAPFilter.html @@ -334,7 +334,7 @@

D  272} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_LDAPPropertyProcessor.html b/coverage/report/SharpHoundCommonLib_LDAPPropertyProcessor.html index 49467b85..01f30c4b 100644 --- a/coverage/report/SharpHoundCommonLib_LDAPPropertyProcessor.html +++ b/coverage/report/SharpHoundCommonLib_LDAPPropertyProcessor.html @@ -845,7 +845,7 @@

 785} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_LDAPQueryException.html b/coverage/report/SharpHoundCommonLib_LDAPQueryException.html index 9dbd5049..24e91f85 100644 --- a/coverage/report/SharpHoundCommonLib_LDAPQueryException.html +++ b/coverage/report/SharpHoundCommonLib_LDAPQueryException.html @@ -61,7 +61,7 @@

 19} -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_LDAPQueryParams.html b/coverage/report/SharpHoundCommonLib_LDAPQueryParams.html index 414222c1..1a916e05 100644 --- a/coverage/report/SharpHoundCommonLib_LDAPQueryParams.html +++ b/coverage/report/SharpHoundCommonLib_LDAPQueryParams.html @@ -47,7 +47,7 @@

D:\a\Sh  14 -

+

Methods/Properties

diff --git a/coverage/report/SharpHoundCommonLib_LDAPUtils.html b/coverage/report/SharpHoundCommonLib_LDAPUtils.html index d25811e6..04b827eb 100644 --- a/coverage/report/SharpHoundCommonLib_LDAPUtils.html +++ b/coverage/report/SharpHoundCommonLib_LDAPUtils.html @@ -17,65 +17,66 @@

< Summary

Class:SharpHoundCommonLib.LDAPUtils Assembly:SharpHoundCommonLib File(s):D:\a\SharpHoundCommon\SharpHoundCommon\src\CommonLib\LDAPUtils.cs -Covered lines:184 -Uncovered lines:779 -Coverable lines:963 -Total lines:1743 -Line coverage:19.1% (184 of 963) -Covered branches:60 -Total branches:413 -Branch coverage:14.5% (60 of 413) +Covered lines:189 +Uncovered lines:757 +Coverable lines:946 +Total lines:1736 +Line coverage:19.9% (189 of 946) +Covered branches:58 +Total branches:387 +Branch coverage:14.9% (58 of 387)

Metrics

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
MethodBranch coverage Cyclomatic complexity NPath complexity Sequence coverage
.cctor()100%10100%
.ctor()100%10100%
.ctor(...)0%600%
SetLDAPConfig(...)0%600%
GetWellKnownPrincipal(...)87.5%80100%
AddDomainController(...)100%100%
GetWellKnownPrincipalOutput()0%1300%
ConvertWellKnownPrincipal(...)60%100100%
GetUserGlobalCatalogMatches(...)50%2090%
ResolveIDAndType(...)50%6075%
ResolveCertTemplateByProperty(...)0%600%
LookupSidType(...)0%600%
LookupGuidType(...)0%600%
GetDomainNameFromSid(...)0%800%
GetSidFromDomainName(...)0%800%
DoRangedRetrieval()0%1600%
ResolveHostToSid()0%4000%
ResolveAccountName(...)0%1000%
ResolveDistinguishedName(...)0%1000%
QueryLDAP(...)100%10100%
QueryLDAP()9.37%32010.66%
CreateNewConnection(...)0%200%
QueryLDAP()6.66%30011.26%
GetForest(...)33.33%6080%
MakeSecurityDescriptor()100%100%
BuildLdapPath(...)100%40100%
TestLDAPConfig(...)0%800%
GetDomain(...)60%10073.91%
SetupLDAPQueryFilter(...)22.22%18024.56%
GetBaseEnterpriseDC(...)0%600%
UpdateLDAPConfig(...)100%100%
GetDomainNameFromSidLdap(...)0%600%
RequestNETBIOSNameFromComputer(...)0%800%
GetWorkstationInfo()0%600%
CreateSearchRequest(...)0%1200%
CreateGlobalCatalogConnection()12.5%16023.52%
CreateLDAPConnection()8.33%24020%
GetUsableDomainController()0%1600%
NormalizeDomainName(...)0%600%
ResolveDomainNetbiosToDns(...)0%600%
GetDomainRangeSize(...)75%16081.48%
DomainNameToDistinguishedName(...)100%60100%
GetConfigurationPath(...)0%600%
GetSchemaPath(...)0%600%
IsDomainController(...)0%200%
.cctor()100%10100%
.ctor()100%10100%
.ctor(...)0%600%
SetLDAPConfig(...)0%600%
GetWellKnownPrincipal(...)87.5%80100%
AddDomainController(...)100%100%
GetWellKnownPrincipalOutput()0%1300%
ConvertWellKnownPrincipal(...)60%100100%
GetUserGlobalCatalogMatches(...)50%2090%
ResolveIDAndType(...)50%6075%
ResolveCertTemplateByProperty(...)0%600%
LookupSidType(...)0%600%
LookupGuidType(...)0%600%
GetDomainNameFromSid(...)0%800%
GetSidFromDomainName(...)0%800%
DoRangedRetrieval()0%1600%
ResolveHostToSid()0%4200%
ResolveAccountName(...)0%1000%
ResolveDistinguishedName(...)0%1000%
QueryLDAP(...)100%10100%
QueryLDAP()8.33%3609.09%
CreateNewConnection(...)0%200%
QueryLDAP(...)100%10100%
GetNextBackoff(...)100%100%
GetForest(...)33.33%6080%
MakeSecurityDescriptor()100%100%
BuildLdapPath(...)100%40100%
TestLDAPConfig(...)0%800%
GetDomain(...)60%10073.91%
SetupLDAPQueryFilter(...)22.22%18024.56%
GetBaseEnterpriseDC(...)0%600%
UpdateLDAPConfig(...)100%100%
GetDomainNameFromSidLdap(...)0%600%
RequestNETBIOSNameFromComputer(...)0%800%
GetWorkstationInfo()0%600%
CreateSearchRequest(...)0%1200%
CreateGlobalCatalogConnection()12.5%16027.77%
CreateLDAPConnection()9.09%22024.39%
GetUsableDomainController()0%1600%
NormalizeDomainName(...)0%600%
ResolveDomainNetbiosToDns(...)0%600%
GetDomainRangeSize(...)75%16083.33%
DomainNameToDistinguishedName(...)100%60100%
GetConfigurationPath(...)0%600%
GetSchemaPath(...)0%600%
IsDomainController(...)0%200%

File(s)

@@ -103,1782 +104,1776 @@

D:\a\SharpHou  18using SharpHoundCommonLib.LDAPQueries;  19using SharpHoundCommonLib.OutputTypes;  20using SharpHoundCommonLib.Processors;21using SharpHoundRPC;22using SharpHoundRPC.NetAPINative;23using SharpHoundRPC.Wrappers;24using Domain = System.DirectoryServices.ActiveDirectory.Domain;25using SearchScope = System.DirectoryServices.Protocols.SearchScope;26using SecurityMasks = System.DirectoryServices.Protocols.SecurityMasks;2728namespace SharpHoundCommonLib29{30    public class LDAPUtils : ILDAPUtils31    {32        private const string NullCacheKey = "UNIQUENULL";3334        // The following byte stream contains the necessary message to request a NetBios name from a machine35        // http://web.archive.org/web/20100409111218/http://msdn.microsoft.com/en-us/library/system.net.sockets.socket.a - 136        private static readonly byte[] NameRequest = - 137        { - 138            0x80, 0x94, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, - 139            0x00, 0x00, 0x00, 0x00, 0x20, 0x43, 0x4b, 0x41,21using SharpHoundRPC.NetAPINative;22using Domain = System.DirectoryServices.ActiveDirectory.Domain;23using SearchScope = System.DirectoryServices.Protocols.SearchScope;24using SecurityMasks = System.DirectoryServices.Protocols.SecurityMasks;2526namespace SharpHoundCommonLib27{28    public class LDAPUtils : ILDAPUtils29    {30        private const string NullCacheKey = "UNIQUENULL";3132        // The following byte stream contains the necessary message to request a NetBios name from a machine33        // http://web.archive.org/web/20100409111218/http://msdn.microsoft.com/en-us/library/system.net.sockets.socket.a + 134        private static readonly byte[] NameRequest = + 135        { + 136            0x80, 0x94, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, + 137            0x00, 0x00, 0x00, 0x00, 0x20, 0x43, 0x4b, 0x41, + 138            0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, + 139            0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41,  140            0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, - 141            0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, - 142            0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, - 143            0x41, 0x41, 0x41, 0x41, 0x41, 0x00, 0x00, 0x21, - 144            0x00, 0x01 - 145        };4647 - 148        private static readonly ConcurrentDictionary<string, ResolvedWellKnownPrincipal> - 149            SeenWellKnownPrincipals = new(); + 141            0x41, 0x41, 0x41, 0x41, 0x41, 0x00, 0x00, 0x21, + 142            0x00, 0x01 + 143        };4445 + 146        private static readonly ConcurrentDictionary<string, ResolvedWellKnownPrincipal> + 147            SeenWellKnownPrincipals = new();48 + 149        private static readonly ConcurrentDictionary<string, byte> DomainControllers = new();  50 - 151        private static readonly ConcurrentDictionary<string, byte> DomainControllers = new();52 - 6453        private readonly ConcurrentDictionary<string, Domain> _domainCache = new(); - 6454        private readonly ConcurrentDictionary<string, string> _domainControllerCache = new(); - 155        private static readonly TimeSpan MinBackoffDelay = TimeSpan.FromSeconds(2); - 156        private static readonly TimeSpan MaxBackoffDelay = TimeSpan.FromSeconds(10); - 157        private static readonly TimeSpan BackoffDelayMultiplier = TimeSpan.FromSeconds(2);58        private const int MaxRetries = 3;59 - 6460        private readonly ConcurrentDictionary<string, LdapConnection> _globalCatalogConnections = new(); - 6461        private readonly ConcurrentDictionary<string, string> _hostResolutionMap = new(); - 6462        private readonly ConcurrentDictionary<string, LdapConnection> _ldapConnections = new(); - 6463        private readonly ConcurrentDictionary<string, int> _ldapRangeSizeCache = new();64        private readonly ILogger _log;65        private readonly NativeMethods _nativeMethods; - 6466        private readonly ConcurrentDictionary<string, string> _netbiosCache = new();67        private readonly PortScanner _portScanner; - 6468        private LDAPConfig _ldapConfig = new(); + 6451        private readonly ConcurrentDictionary<string, Domain> _domainCache = new(); + 6452        private readonly ConcurrentDictionary<string, string> _domainControllerCache = new(); + 153        private static readonly TimeSpan MinBackoffDelay = TimeSpan.FromSeconds(2); + 154        private static readonly TimeSpan MaxBackoffDelay = TimeSpan.FromSeconds(20);55        private const int BackoffDelayMultiplier = 2;56        private const int MaxRetries = 3;57 + 6458        private readonly ConcurrentDictionary<string, LdapConnection> _globalCatalogConnections = new(); + 6459        private readonly ConcurrentDictionary<string, string> _hostResolutionMap = new(); + 6460        private readonly ConcurrentDictionary<string, LdapConnection> _ldapConnections = new(); + 6461        private readonly ConcurrentDictionary<string, int> _ldapRangeSizeCache = new();62        private readonly ILogger _log;63        private readonly NativeMethods _nativeMethods; + 6464        private readonly ConcurrentDictionary<string, string> _netbiosCache = new();65        private readonly PortScanner _portScanner; + 6466        private LDAPConfig _ldapConfig = new(); + 6467        private readonly ManualResetEvent _connectionResetEvent = new(false); + 6468        private readonly object _lockObj = new();  6970        /// <summary>71        ///     Creates a new instance of LDAP Utils with defaults72        /// </summary> - 6473        public LDAPUtils() - 6474        { - 6475            _nativeMethods = new NativeMethods(); - 6476            _portScanner = new PortScanner(); - 6477            _log = Logging.LogProvider.CreateLogger("LDAPUtils"); - 6478        }7980        /// <summary>81        ///     Creates a new instance of LDAP utils and allows overriding implementations82        /// </summary>83        /// <param name="nativeMethods"></param>84        /// <param name="scanner"></param>85        /// <param name="log"></param> - 086        public LDAPUtils(NativeMethods nativeMethods = null, PortScanner scanner = null, ILogger log = null) - 087        { - 088            _nativeMethods = nativeMethods ?? new NativeMethods(); - 089            _portScanner = scanner ?? new PortScanner(); - 090            _log = log ?? Logging.LogProvider.CreateLogger("LDAPUtils"); - 091        }9293        /// <summary>94        ///     Sets the configuration for LDAP queries95        /// </summary>96        /// <param name="config"></param>97        /// <exception cref="Exception"></exception>98        public void SetLDAPConfig(LDAPConfig config) - 099        { - 0100            _ldapConfig = config ?? throw new Exception("LDAP Configuration can not be null"); - 0101            _domainControllerCache.Clear(); - 0102            foreach (var kv in _globalCatalogConnections) - 0103            { - 0104                kv.Value.Dispose(); - 0105            } - 0106            _globalCatalogConnections.Clear(); - 0107            foreach (var kv in _ldapConnections) - 0108            { - 0109                kv.Value.Dispose(); - 0110            } - 0111            _ldapConnections.Clear(); - 0112        }7071        /// <summary>72        ///     Creates a new instance of LDAP Utils with defaults73        /// </summary> + 6474        public LDAPUtils() + 6475        { + 6476            _nativeMethods = new NativeMethods(); + 6477            _portScanner = new PortScanner(); + 6478            _log = Logging.LogProvider.CreateLogger("LDAPUtils"); + 6479        }8081        /// <summary>82        ///     Creates a new instance of LDAP utils and allows overriding implementations83        /// </summary>84        /// <param name="nativeMethods"></param>85        /// <param name="scanner"></param>86        /// <param name="log"></param> + 087        public LDAPUtils(NativeMethods nativeMethods = null, PortScanner scanner = null, ILogger log = null) + 088        { + 089            _nativeMethods = nativeMethods ?? new NativeMethods(); + 090            _portScanner = scanner ?? new PortScanner(); + 091            _log = log ?? Logging.LogProvider.CreateLogger("LDAPUtils"); + 092        }9394        /// <summary>95        ///     Sets the configuration for LDAP queries96        /// </summary>97        /// <param name="config"></param>98        /// <exception cref="Exception"></exception>99        public void SetLDAPConfig(LDAPConfig config) + 0100        { + 0101            _ldapConfig = config ?? throw new Exception("LDAP Configuration can not be null"); + 0102            _domainControllerCache.Clear(); + 0103            foreach (var kv in _globalCatalogConnections) + 0104            { + 0105                kv.Value.Dispose(); + 0106            }107 + 0108            _globalCatalogConnections.Clear(); + 0109            foreach (var kv in _ldapConnections) + 0110            { + 0111                kv.Value.Dispose(); + 0112            }  113114        /// <summary>115        ///     Turns a sid into a well known principal ID.116        /// </summary>117        /// <param name="sid"></param>118        /// <param name="domain"></param>119        /// <param name="commonPrincipal"></param>120        /// <returns>True if a well known principal was identified, false if not</returns>121        public bool GetWellKnownPrincipal(string sid, string domain, out TypedPrincipal commonPrincipal) - 4122        { - 5123            if (!WellKnownPrincipal.GetWellKnownPrincipal(sid, out commonPrincipal)) return false; - 3124            var tempDomain = domain ?? GetDomain()?.Name ?? "UNKNOWN"; - 3125            commonPrincipal.ObjectIdentifier = ConvertWellKnownPrincipal(sid, tempDomain); - 3126            SeenWellKnownPrincipals.TryAdd(commonPrincipal.ObjectIdentifier, new ResolvedWellKnownPrincipal - 3127            { - 3128                DomainName = domain, - 3129                WkpId = sid - 3130            }); - 3131            return true; - 4132        }133134        /// <summary>135        ///     Adds a SID to an internal list of domain controllers136        /// </summary>137        /// <param name="domainControllerSID"></param>138        public void AddDomainController(string domainControllerSID) - 0139        { - 0140            DomainControllers.TryAdd(domainControllerSID, new byte()); - 0141        }142143        /// <summary>144        ///     Gets output objects for currently observed well known principals145        /// </summary>146        /// <returns></returns>147        /// <exception cref="ArgumentOutOfRangeException"></exception>148        public IEnumerable<OutputBase> GetWellKnownPrincipalOutput(string domain) - 0149        { - 0150            foreach (var wkp in SeenWellKnownPrincipals) - 0151            { - 0152                WellKnownPrincipal.GetWellKnownPrincipal(wkp.Value.WkpId, out var principal); - 0153                OutputBase output = principal.ObjectType switch - 0154                { - 0155                    Label.User => new User(), - 0156                    Label.Computer => new Computer(), - 0157                    Label.Group => new Group(), - 0158                    Label.GPO => new GPO(), - 0159                    Label.Domain => new OutputTypes.Domain(), - 0160                    Label.OU => new OU(), - 0161                    Label.Container => new Container(), - 0162                    Label.Configuration => new Container(), - 0163                    _ => throw new ArgumentOutOfRangeException() - 0164                };165 - 0166                output.Properties.Add("name", $"{principal.ObjectIdentifier}@{wkp.Value.DomainName}".ToUpper()); - 0167                var domainSid = GetSidFromDomainName(wkp.Value.DomainName); - 0168                output.Properties.Add("domainsid", domainSid); - 0169                output.Properties.Add("domain", wkp.Value.DomainName.ToUpper()); - 0170                output.ObjectIdentifier = wkp.Key; - 0171                yield return output; - 0172            }173 - 0174            var entdc = GetBaseEnterpriseDC(domain); - 0175            entdc.Members = DomainControllers.Select(x => new TypedPrincipal(x.Key, Label.Computer)).ToArray(); - 0176            yield return entdc; - 0177        }178179        /// <summary>180        ///     Converts a181        /// </summary>182        /// <param name="sid"></param>183        /// <param name="domain"></param>184        /// <returns></returns>185        public string ConvertWellKnownPrincipal(string sid, string domain) - 3186        { - 3187            if (!WellKnownPrincipal.GetWellKnownPrincipal(sid, out _)) return sid;188 - 5189            if (sid != "S-1-5-9") return $"{domain}-{sid}".ToUpper();190 - 1191            var forest = GetForest(domain)?.Name; - 1192            if (forest == null) _log.LogWarning("Error getting forest, ENTDC sid is likely incorrect"); - 1193            return $"{forest ?? "UNKNOWN"}-{sid}".ToUpper(); - 3194        }195196        /// <summary>197        ///     Queries the global catalog to get potential SID matches for a username in the forest198        /// </summary>199        /// <param name="name"></param>200        /// <returns></returns>201        public string[] GetUserGlobalCatalogMatches(string name) - 1202        { - 1203            var tempName = name.ToLower(); - 1204            if (Cache.GetGCCache(tempName, out var sids)) - 0205                return sids;206 - 1207            var query = new LDAPFilter().AddUsers($"samaccountname={tempName}").GetFilter(); - 1208            var results = QueryLDAP(query, SearchScope.Subtree, new[] { "objectsid" }, globalCatalog: true) - 1209                .Select(x => x.GetSid()).Where(x => x != null).ToArray(); - 1210            Cache.AddGCCache(tempName, results); - 1211            return results; - 1212        }213214        /// <summary>215        ///     Uses an LDAP lookup to attempt to find the Label for a given SID216        ///     Will also convert to a well known principal ID if needed217        /// </summary>218        /// <param name="id"></param>219        /// <param name="fallbackDomain"></param>220        /// <returns></returns>221        public TypedPrincipal ResolveIDAndType(string id, string fallbackDomain) - 2222        {223            //This is a duplicated SID object which is weird and makes things unhappy. Throw it out - 2224            if (id.Contains("0ACNF")) - 1225                return null;226 - 1227            if (GetWellKnownPrincipal(id, fallbackDomain, out var principal)) - 1228                return principal; + 0114            _ldapConnections.Clear(); + 0115        }116117        /// <summary>118        ///     Turns a sid into a well known principal ID.119        /// </summary>120        /// <param name="sid"></param>121        /// <param name="domain"></param>122        /// <param name="commonPrincipal"></param>123        /// <returns>True if a well known principal was identified, false if not</returns>124        public bool GetWellKnownPrincipal(string sid, string domain, out TypedPrincipal commonPrincipal) + 4125        { + 5126            if (!WellKnownPrincipal.GetWellKnownPrincipal(sid, out commonPrincipal)) return false; + 3127            var tempDomain = domain ?? GetDomain()?.Name ?? "UNKNOWN"; + 3128            commonPrincipal.ObjectIdentifier = ConvertWellKnownPrincipal(sid, tempDomain); + 3129            SeenWellKnownPrincipals.TryAdd(commonPrincipal.ObjectIdentifier, new ResolvedWellKnownPrincipal + 3130            { + 3131                DomainName = domain, + 3132                WkpId = sid + 3133            }); + 3134            return true; + 4135        }136137        /// <summary>138        ///     Adds a SID to an internal list of domain controllers139        /// </summary>140        /// <param name="domainControllerSID"></param>141        public void AddDomainController(string domainControllerSID) + 0142        { + 0143            DomainControllers.TryAdd(domainControllerSID, new byte()); + 0144        }145146        /// <summary>147        ///     Gets output objects for currently observed well known principals148        /// </summary>149        /// <returns></returns>150        /// <exception cref="ArgumentOutOfRangeException"></exception>151        public IEnumerable<OutputBase> GetWellKnownPrincipalOutput(string domain) + 0152        { + 0153            foreach (var wkp in SeenWellKnownPrincipals) + 0154            { + 0155                WellKnownPrincipal.GetWellKnownPrincipal(wkp.Value.WkpId, out var principal); + 0156                OutputBase output = principal.ObjectType switch + 0157                { + 0158                    Label.User => new User(), + 0159                    Label.Computer => new Computer(), + 0160                    Label.Group => new Group(), + 0161                    Label.GPO => new GPO(), + 0162                    Label.Domain => new OutputTypes.Domain(), + 0163                    Label.OU => new OU(), + 0164                    Label.Container => new Container(), + 0165                    Label.Configuration => new Container(), + 0166                    _ => throw new ArgumentOutOfRangeException() + 0167                };168 + 0169                output.Properties.Add("name", $"{principal.ObjectIdentifier}@{wkp.Value.DomainName}".ToUpper()); + 0170                var domainSid = GetSidFromDomainName(wkp.Value.DomainName); + 0171                output.Properties.Add("domainsid", domainSid); + 0172                output.Properties.Add("domain", wkp.Value.DomainName.ToUpper()); + 0173                output.ObjectIdentifier = wkp.Key; + 0174                yield return output; + 0175            }176 + 0177            var entdc = GetBaseEnterpriseDC(domain); + 0178            entdc.Members = DomainControllers.Select(x => new TypedPrincipal(x.Key, Label.Computer)).ToArray(); + 0179            yield return entdc; + 0180        }181182        /// <summary>183        ///     Converts a184        /// </summary>185        /// <param name="sid"></param>186        /// <param name="domain"></param>187        /// <returns></returns>188        public string ConvertWellKnownPrincipal(string sid, string domain) + 3189        { + 3190            if (!WellKnownPrincipal.GetWellKnownPrincipal(sid, out _)) return sid;191 + 5192            if (sid != "S-1-5-9") return $"{domain}-{sid}".ToUpper();193 + 1194            var forest = GetForest(domain)?.Name; + 1195            if (forest == null) _log.LogWarning("Error getting forest, ENTDC sid is likely incorrect"); + 1196            return $"{forest ?? "UNKNOWN"}-{sid}".ToUpper(); + 3197        }198199        /// <summary>200        ///     Queries the global catalog to get potential SID matches for a username in the forest201        /// </summary>202        /// <param name="name"></param>203        /// <returns></returns>204        public string[] GetUserGlobalCatalogMatches(string name) + 1205        { + 1206            var tempName = name.ToLower(); + 1207            if (Cache.GetGCCache(tempName, out var sids)) + 0208                return sids;209 + 1210            var query = new LDAPFilter().AddUsers($"samaccountname={tempName}").GetFilter(); + 1211            var results = QueryLDAP(query, SearchScope.Subtree, new[] { "objectsid" }, globalCatalog: true) + 1212                .Select(x => x.GetSid()).Where(x => x != null).ToArray(); + 1213            Cache.AddGCCache(tempName, results); + 1214            return results; + 1215        }216217        /// <summary>218        ///     Uses an LDAP lookup to attempt to find the Label for a given SID219        ///     Will also convert to a well known principal ID if needed220        /// </summary>221        /// <param name="id"></param>222        /// <param name="fallbackDomain"></param>223        /// <returns></returns>224        public TypedPrincipal ResolveIDAndType(string id, string fallbackDomain) + 2225        {226            //This is a duplicated SID object which is weird and makes things unhappy. Throw it out + 2227            if (id.Contains("0ACNF")) + 1228                return null;  229 - 0230            var type = id.StartsWith("S-") ? LookupSidType(id, fallbackDomain) : LookupGuidType(id, fallbackDomain); - 0231            return new TypedPrincipal(id, type); - 2232        }233234        public TypedPrincipal ResolveCertTemplateByProperty(string propValue, string propertyName, string containerDN, s - 0235        { - 0236            var filter = new LDAPFilter().AddCertificateTemplates().AddFilter(propertyName + "=" + propValue, true); - 0237            var res = QueryLDAP(filter.GetFilter(), SearchScope.OneLevel, - 0238                         CommonProperties.TypeResolutionProps, adsPath: containerDN, domainName: domainName);239 - 0240            if (res == null) - 0241            { - 0242                _log.LogWarning("Could not find certificate template with '{propertyName}:{propValue}' under {containerD - 0243                return null;244            }245 - 0246            List<ISearchResultEntry> resList = new List<ISearchResultEntry>(res); - 0247            if (resList.Count == 0) - 0248            { - 0249                _log.LogWarning("Could not find certificate template with '{propertyName}:{propValue}' under {containerD - 0250                return null;251            }252 - 0253            if (resList.Count > 1) + 1230            if (GetWellKnownPrincipal(id, fallbackDomain, out var principal)) + 1231                return principal;232 + 0233            var type = id.StartsWith("S-") ? LookupSidType(id, fallbackDomain) : LookupGuidType(id, fallbackDomain); + 0234            return new TypedPrincipal(id, type); + 2235        }236237        public TypedPrincipal ResolveCertTemplateByProperty(string propValue, string propertyName, string containerDN,238            string domainName) + 0239        { + 0240            var filter = new LDAPFilter().AddCertificateTemplates().AddFilter(propertyName + "=" + propValue, true); + 0241            var res = QueryLDAP(filter.GetFilter(), SearchScope.OneLevel, + 0242                CommonProperties.TypeResolutionProps, adsPath: containerDN, domainName: domainName);243 + 0244            if (res == null) + 0245            { + 0246                _log.LogWarning( + 0247                    "Could not find certificate template with '{propertyName}:{propValue}' under {containerDN}; null res + 0248                    propertyName, propValue, containerDN); + 0249                return null;250            }251 + 0252            List<ISearchResultEntry> resList = new List<ISearchResultEntry>(res); + 0253            if (resList.Count == 0)  0254            { - 0255                _log.LogWarning("Found more than one certificate template with '{propertyName}:{propValue}' under {conta - 0256                return null;257            }258 - 0259            ISearchResultEntry searchResultEntry = resList.FirstOrDefault(); - 0260            return new TypedPrincipal(searchResultEntry.GetGuid(), Label.CertTemplate); - 0261        }262263        /// <summary>264        ///     Attempts to lookup the Label for a sid265        /// </summary>266        /// <param name="sid"></param>267        /// <param name="domain"></param>268        /// <returns></returns>269        public Label LookupSidType(string sid, string domain) - 0270        { - 0271            if (Cache.GetIDType(sid, out var type)) - 0272                return type;273 - 0274            var rDomain = GetDomainNameFromSid(sid) ?? domain;275 - 0276            var result = - 0277                QueryLDAP(CommonFilters.SpecificSID(sid), SearchScope.Subtree, CommonProperties.TypeResolutionProps, - 0278                        rDomain) - 0279                    .DefaultIfEmpty(null).FirstOrDefault();280 - 0281            type = result?.GetLabel() ?? Label.Base; - 0282            Cache.AddType(sid, type); - 0283            return type; - 0284        } + 0255                _log.LogWarning( + 0256                    "Could not find certificate template with '{propertyName}:{propValue}' under {containerDN}; empty li + 0257                    propertyName, propValue, containerDN); + 0258                return null;259            }260 + 0261            if (resList.Count > 1) + 0262            { + 0263                _log.LogWarning( + 0264                    "Found more than one certificate template with '{propertyName}:{propValue}' under {containerDN}", + 0265                    propertyName, propValue, containerDN); + 0266                return null;267            }268 + 0269            ISearchResultEntry searchResultEntry = resList.FirstOrDefault(); + 0270            return new TypedPrincipal(searchResultEntry.GetGuid(), Label.CertTemplate); + 0271        }272273        /// <summary>274        ///     Attempts to lookup the Label for a sid275        /// </summary>276        /// <param name="sid"></param>277        /// <param name="domain"></param>278        /// <returns></returns>279        public Label LookupSidType(string sid, string domain) + 0280        { + 0281            if (Cache.GetIDType(sid, out var type)) + 0282                return type;283 + 0284            var rDomain = GetDomainNameFromSid(sid) ?? domain;  285286        /// <summary>287        ///     Attempts to lookup the Label for a GUID288        /// </summary>289        /// <param name="guid"></param>290        /// <param name="domain"></param>291        /// <returns></returns>292        public Label LookupGuidType(string guid, string domain) - 0293        { - 0294            if (Cache.GetIDType(guid, out var type)) - 0295                return type;296 - 0297            var hex = Helpers.ConvertGuidToHexGuid(guid); - 0298            if (hex == null) - 0299                return Label.Base;300 - 0301            var result = - 0302                QueryLDAP($"(objectguid={hex})", SearchScope.Subtree, CommonProperties.TypeResolutionProps, domain) - 0303                    .DefaultIfEmpty(null).FirstOrDefault();304 - 0305            type = result?.GetLabel() ?? Label.Base; - 0306            Cache.AddType(guid, type); - 0307            return type; - 0308        }309310        /// <summary>311        ///     Attempts to find the domain associated with a SID312        /// </summary>313        /// <param name="sid"></param>314        /// <returns></returns>315        public string GetDomainNameFromSid(string sid) - 0316        {317            try - 0318            { - 0319                var parsedSid = new SecurityIdentifier(sid); - 0320                var domainSid = parsedSid.AccountDomainSid?.Value.ToUpper(); - 0321                if (domainSid == null) - 0322                    return null;323 - 0324                _log.LogDebug("Resolving sid {DomainSid}", domainSid);325 - 0326                if (Cache.GetDomainSidMapping(domainSid, out var domain)) - 0327                    return domain;328 - 0329                _log.LogDebug("No cache hit for {DomainSid}", domainSid); - 0330                domain = GetDomainNameFromSidLdap(domainSid); - 0331                _log.LogDebug("Resolved to {Domain}", domain);332333                //Cache both to and from so we can use this later - 0334                if (domain != null) - 0335                { - 0336                    Cache.AddSidToDomain(domainSid, domain); - 0337                    Cache.AddSidToDomain(domain, domainSid); - 0338                }339 - 0340                return domain;341            } - 0342            catch - 0343            { - 0344                return null;345            } - 0346        }347348        /// <summary>349        ///     Attempts to get the SID associated with a domain name350        /// </summary>351        /// <param name="domainName"></param>352        /// <returns></returns>353        public string GetSidFromDomainName(string domainName) - 0354        { - 0355            var tempDomainName = NormalizeDomainName(domainName); - 0356            if (tempDomainName == null) - 0357                return null; - 0358            if (Cache.GetDomainSidMapping(tempDomainName, out var sid)) return sid;359 - 0360            var domainObj = GetDomain(tempDomainName);361 - 0362            if (domainObj != null) - 0363                sid = domainObj.GetDirectoryEntry().GetSid();364            else - 0365                sid = null;366 - 0367            if (sid != null) - 0368            { - 0369                Cache.AddSidToDomain(sid, tempDomainName); - 0370                Cache.AddSidToDomain(tempDomainName, sid); - 0371            }372 - 0373            return sid; - 0374        }375376        // Saving this code for an eventual async implementation377        // public async IAsyncEnumerable<string> DoRangedRetrievalAsync(string distinguishedName, string attributeName)378        // {379        //     var domainName = Helpers.DistinguishedNameToDomain(distinguishedName);380        //     LdapConnection conn;381        //     try382        //     {383        //         conn = await CreateLDAPConnection(domainName, authType: _ldapConfig.AuthType);384        //     }385        //     catch386        //     {387        //         yield break;388        //     }389        //390        //     if (conn == null)391        //         yield break;392        //393        //     var index = 0;394        //     var step = 0;395        //     var currentRange = $"{attributeName};range={index}-*";396        //     var complete = false;397        //398        //     var searchRequest = CreateSearchRequest($"{attributeName}=*", SearchScope.Base, new[] {currentRange},399        //         domainName, distinguishedName);400        //401        //     var backoffDelay = MinBackoffDelay;402        //     var retryCount = 0;403        //404        //     while (true)405        //     {406        //         DirectoryResponse searchResult;407        //         try408        //         {409        //             searchResult = await Task.Factory.FromAsync(conn.BeginSendRequest, conn.EndSendRequest,410        //                 searchRequest,411        //                 PartialResultProcessing.NoPartialResultSupport, null);412        //         }413        //         catch (LdapException le) when (le.ErrorCode == 51 && retryCount < MaxRetries)414        //         {415        //             //Allow three retries with a backoff on each one if we get a "Server is Busy" error416        //             retryCount++;417        //             await Task.Delay(backoffDelay);418        //             backoffDelay = TimeSpan.FromSeconds(Math.Min(419        //                 backoffDelay.TotalSeconds * BackoffDelayMultiplier.TotalSeconds, MaxBackoffDelay.TotalSeconds420        //             continue;421        //         }422        //         catch (Exception e)423        //         {424        //             _log.LogWarning(e,"Caught exception during ranged retrieval for {DN}", distinguishedName);425        //             yield break;426        //         }427        //428        //         if (searchResult is SearchResponse response && response.Entries.Count == 1)429        //         {430        //             var entry = response.Entries[0];431        //             var attributeNames = entry?.Attributes?.AttributeNames;432        //             if (attributeNames != null)433        //             {434        //                 foreach (string attr in attributeNames)435        //                 {436        //                     //Set our current range to the name of the attribute, which will tell us how far we are i437        //                     currentRange = attr;438        //                     //Check if the string has the * character in it. If it does, we've reached the end of thi439        //                     complete = currentRange.IndexOf("*", 0, StringComparison.Ordinal) > 0;440        //                     //Set our step to the number of attributes that came back.441        //                     step = entry.Attributes[currentRange].Count;442        //                 }443        //             }444        //445        //446        //             foreach (string val in entry.Attributes[currentRange].GetValues(typeof(string)))447        //             {448        //                 yield return val;449        //                 index++;450        //             }451        //452        //             if (complete) yield break;453        //454        //             currentRange = $"{attributeName};range={index}-{index + step}";455        //             searchRequest.Attributes.Clear();456        //             searchRequest.Attributes.Add(currentRange);457        //         }458        //         else459        //         {460        //             yield break;461        //         }462        //     }463        // }464465        /// <summary>466        ///     Performs Attribute Ranged Retrieval467        ///     https://docs.microsoft.com/en-us/windows/win32/adsi/attribute-range-retrieval468        ///     The function self-determines the range and internally handles the maximum step allowed by the server469        /// </summary>470        /// <param name="distinguishedName"></param>471        /// <param name="attributeName"></param>472        /// <returns></returns>473        public IEnumerable<string> DoRangedRetrieval(string distinguishedName, string attributeName) - 0474        { - 0475            var domainName = Helpers.DistinguishedNameToDomain(distinguishedName); - 0476            var task = Task.Run(() => CreateLDAPConnection(domainName, authType: _ldapConfig.AuthType));477478            LdapConnection conn;479480            try - 0481            { - 0482                conn = task.ConfigureAwait(false).GetAwaiter().GetResult(); - 0483            } - 0484            catch - 0485            { - 0486                yield break;487            }488 - 0489            if (conn == null) - 0490                yield break;491 - 0492            var index = 0; - 0493            var step = 0; - 0494            var baseString = $"{attributeName}";495            //Example search string: member;range=0-1000 - 0496            var currentRange = $"{baseString};range={index}-*"; - 0497            var complete = false; + 0286            var result = + 0287                QueryLDAP(CommonFilters.SpecificSID(sid), SearchScope.Subtree, CommonProperties.TypeResolutionProps, + 0288                        rDomain) + 0289                    .DefaultIfEmpty(null).FirstOrDefault();290 + 0291            type = result?.GetLabel() ?? Label.Base; + 0292            Cache.AddType(sid, type); + 0293            return type; + 0294        }295296        /// <summary>297        ///     Attempts to lookup the Label for a GUID298        /// </summary>299        /// <param name="guid"></param>300        /// <param name="domain"></param>301        /// <returns></returns>302        public Label LookupGuidType(string guid, string domain) + 0303        { + 0304            if (Cache.GetIDType(guid, out var type)) + 0305                return type;306 + 0307            var hex = Helpers.ConvertGuidToHexGuid(guid); + 0308            if (hex == null) + 0309                return Label.Base;310 + 0311            var result = + 0312                QueryLDAP($"(objectguid={hex})", SearchScope.Subtree, CommonProperties.TypeResolutionProps, domain) + 0313                    .DefaultIfEmpty(null).FirstOrDefault();314 + 0315            type = result?.GetLabel() ?? Label.Base; + 0316            Cache.AddType(guid, type); + 0317            return type; + 0318        }319320        /// <summary>321        ///     Attempts to find the domain associated with a SID322        /// </summary>323        /// <param name="sid"></param>324        /// <returns></returns>325        public string GetDomainNameFromSid(string sid) + 0326        {327            try + 0328            { + 0329                var parsedSid = new SecurityIdentifier(sid); + 0330                var domainSid = parsedSid.AccountDomainSid?.Value.ToUpper(); + 0331                if (domainSid == null) + 0332                    return null;333 + 0334                _log.LogDebug("Resolving sid {DomainSid}", domainSid);335 + 0336                if (Cache.GetDomainSidMapping(domainSid, out var domain)) + 0337                    return domain;338 + 0339                _log.LogDebug("No cache hit for {DomainSid}", domainSid); + 0340                domain = GetDomainNameFromSidLdap(domainSid); + 0341                _log.LogDebug("Resolved to {Domain}", domain);342343                //Cache both to and from so we can use this later + 0344                if (domain != null) + 0345                { + 0346                    Cache.AddSidToDomain(domainSid, domain); + 0347                    Cache.AddSidToDomain(domain, domainSid); + 0348                }349 + 0350                return domain;351            } + 0352            catch + 0353            { + 0354                return null;355            } + 0356        }357358        /// <summary>359        ///     Attempts to get the SID associated with a domain name360        /// </summary>361        /// <param name="domainName"></param>362        /// <returns></returns>363        public string GetSidFromDomainName(string domainName) + 0364        { + 0365            var tempDomainName = NormalizeDomainName(domainName); + 0366            if (tempDomainName == null) + 0367                return null; + 0368            if (Cache.GetDomainSidMapping(tempDomainName, out var sid)) return sid;369 + 0370            var domainObj = GetDomain(tempDomainName);371 + 0372            if (domainObj != null) + 0373                sid = domainObj.GetDirectoryEntry().GetSid();374            else + 0375                sid = null;376 + 0377            if (sid != null) + 0378            { + 0379                Cache.AddSidToDomain(sid, tempDomainName); + 0380                Cache.AddSidToDomain(tempDomainName, sid); + 0381            }382 + 0383            return sid; + 0384        }385386        // Saving this code for an eventual async implementation387        // public async IAsyncEnumerable<string> DoRangedRetrievalAsync(string distinguishedName, string attributeName)388        // {389        //     var domainName = Helpers.DistinguishedNameToDomain(distinguishedName);390        //     LdapConnection conn;391        //     try392        //     {393        //         conn = await CreateLDAPConnection(domainName, authType: _ldapConfig.AuthType);394        //     }395        //     catch396        //     {397        //         yield break;398        //     }399        //400        //     if (conn == null)401        //         yield break;402        //403        //     var index = 0;404        //     var step = 0;405        //     var currentRange = $"{attributeName};range={index}-*";406        //     var complete = false;407        //408        //     var searchRequest = CreateSearchRequest($"{attributeName}=*", SearchScope.Base, new[] {currentRange},409        //         domainName, distinguishedName);410        //411        //     var backoffDelay = MinBackoffDelay;412        //     var retryCount = 0;413        //414        //     while (true)415        //     {416        //         DirectoryResponse searchResult;417        //         try418        //         {419        //             searchResult = await Task.Factory.FromAsync(conn.BeginSendRequest, conn.EndSendRequest,420        //                 searchRequest,421        //                 PartialResultProcessing.NoPartialResultSupport, null);422        //         }423        //         catch (LdapException le) when (le.ErrorCode == 51 && retryCount < MaxRetries)424        //         {425        //             //Allow three retries with a backoff on each one if we get a "Server is Busy" error426        //             retryCount++;427        //             await Task.Delay(backoffDelay);428        //             backoffDelay = TimeSpan.FromSeconds(Math.Min(429        //                 backoffDelay.TotalSeconds * BackoffDelayMultiplier.TotalSeconds, MaxBackoffDelay.TotalSeconds430        //             continue;431        //         }432        //         catch (Exception e)433        //         {434        //             _log.LogWarning(e,"Caught exception during ranged retrieval for {DN}", distinguishedName);435        //             yield break;436        //         }437        //438        //         if (searchResult is SearchResponse response && response.Entries.Count == 1)439        //         {440        //             var entry = response.Entries[0];441        //             var attributeNames = entry?.Attributes?.AttributeNames;442        //             if (attributeNames != null)443        //             {444        //                 foreach (string attr in attributeNames)445        //                 {446        //                     //Set our current range to the name of the attribute, which will tell us how far we are i447        //                     currentRange = attr;448        //                     //Check if the string has the * character in it. If it does, we've reached the end of thi449        //                     complete = currentRange.IndexOf("*", 0, StringComparison.Ordinal) > 0;450        //                     //Set our step to the number of attributes that came back.451        //                     step = entry.Attributes[currentRange].Count;452        //                 }453        //             }454        //455        //456        //             foreach (string val in entry.Attributes[currentRange].GetValues(typeof(string)))457        //             {458        //                 yield return val;459        //                 index++;460        //             }461        //462        //             if (complete) yield break;463        //464        //             currentRange = $"{attributeName};range={index}-{index + step}";465        //             searchRequest.Attributes.Clear();466        //             searchRequest.Attributes.Add(currentRange);467        //         }468        //         else469        //         {470        //             yield break;471        //         }472        //     }473        // }474475        /// <summary>476        ///     Performs Attribute Ranged Retrieval477        ///     https://docs.microsoft.com/en-us/windows/win32/adsi/attribute-range-retrieval478        ///     The function self-determines the range and internally handles the maximum step allowed by the server479        /// </summary>480        /// <param name="distinguishedName"></param>481        /// <param name="attributeName"></param>482        /// <returns></returns>483        public IEnumerable<string> DoRangedRetrieval(string distinguishedName, string attributeName) + 0484        { + 0485            var domainName = Helpers.DistinguishedNameToDomain(distinguishedName); + 0486            var task = Task.Run(() => CreateLDAPConnection(domainName, authType: _ldapConfig.AuthType));487488            LdapConnection conn;489490            try + 0491            { + 0492                conn = task.ConfigureAwait(false).GetAwaiter().GetResult(); + 0493            } + 0494            catch + 0495            { + 0496                yield break;497            }  498 - 0499            var searchRequest = CreateSearchRequest($"{attributeName}=*", SearchScope.Base, new[] { currentRange }, - 0500                domainName, distinguishedName); + 0499            if (conn == null) + 0500                yield break;  501 - 0502            if (searchRequest == null) - 0503                yield break;504 - 0505            var backoffDelay = MinBackoffDelay; - 0506            var retryCount = 0;507 - 0508            while (true) - 0509            {510                SearchResponse response;511                try - 0512                { - 0513                    response = (SearchResponse)conn.SendRequest(searchRequest); - 0514                } - 0515                catch (LdapException le) when (le.ErrorCode == (int)LdapErrorCodes.Busy && retryCount < MaxRetries) - 0516                {517                    //Allow three retries with a backoff on each one if we get a "Server is Busy" error - 0518                    retryCount++; - 0519                    Thread.Sleep(backoffDelay); - 0520                    backoffDelay = TimeSpan.FromSeconds(Math.Min( - 0521                    backoffDelay.TotalSeconds * BackoffDelayMultiplier.TotalSeconds, MaxBackoffDelay.TotalSeconds)); - 0522                    continue;523                } - 0524                catch (Exception e) - 0525                { - 0526                    _log.LogError(e, "Error doing ranged retrieval for {Attribute} on {Dn}", attributeName, distinguishe - 0527                    yield break;528                }529530                //If we ever get more than one response from here, something is horribly wrong - 0531                if (response?.Entries.Count == 1) - 0532                { - 0533                    var entry = response.Entries[0];534                    //Process the attribute we get back to determine a few things - 0535                    foreach (string attr in entry.Attributes.AttributeNames) - 0536                    {537                        //Set our current range to the name of the attribute, which will tell us how far we are in "pagi - 0538                        currentRange = attr;539                        //Check if the string has the * character in it. If it does, we've reached the end of this searc - 0540                        complete = currentRange.IndexOf("*", 0, StringComparison.Ordinal) > 0;541                        //Set our step to the number of attributes that came back. - 0542                        step = entry.Attributes[currentRange].Count; - 0543                    }544 - 0545                    foreach (string val in entry.Attributes[currentRange].GetValues(typeof(string))) + 0502            var index = 0; + 0503            var step = 0; + 0504            var baseString = $"{attributeName}";505            //Example search string: member;range=0-1000 + 0506            var currentRange = $"{baseString};range={index}-*"; + 0507            var complete = false;508 + 0509            var searchRequest = CreateSearchRequest($"{attributeName}=*", SearchScope.Base, new[] { currentRange }, + 0510                domainName, distinguishedName);511 + 0512            if (searchRequest == null) + 0513                yield break;514 + 0515            var backoffDelay = MinBackoffDelay; + 0516            var retryCount = 0;517 + 0518            while (true) + 0519            {520                SearchResponse response;521                try + 0522                { + 0523                    response = (SearchResponse)conn.SendRequest(searchRequest); + 0524                } + 0525                catch (LdapException le) when (le.ErrorCode == (int)LdapErrorCodes.Busy && retryCount < MaxRetries) + 0526                {527                    //Allow three retries with a backoff on each one if we get a "Server is Busy" error + 0528                    retryCount++; + 0529                    Thread.Sleep(backoffDelay); + 0530                    backoffDelay = GetNextBackoff(retryCount); + 0531                    continue;532                } + 0533                catch (Exception e) + 0534                { + 0535                    _log.LogError(e, "Error doing ranged retrieval for {Attribute} on {Dn}", attributeName, + 0536                        distinguishedName); + 0537                    yield break;538                }539540                //If we ever get more than one response from here, something is horribly wrong + 0541                if (response?.Entries.Count == 1) + 0542                { + 0543                    var entry = response.Entries[0];544                    //Process the attribute we get back to determine a few things + 0545                    foreach (string attr in entry.Attributes.AttributeNames)  0546                    { - 0547                        yield return val; - 0548                        index++; - 0549                    }550 - 0551                    if (complete) yield break;552 - 0553                    currentRange = $"{baseString};range={index}-{index + step}"; - 0554                    searchRequest.Attributes.Clear(); - 0555                    searchRequest.Attributes.Add(currentRange); - 0556                }557                else - 0558                {559                    //Something went wrong here. - 0560                    yield break;561                } - 0562            }563        }564565        /// <summary>566        ///     Takes a host in most applicable forms from AD and attempts to resolve it into a SID.567        /// </summary>568        /// <param name="hostname"></param>569        /// <param name="domain"></param>570        /// <returns></returns>571        public async Task<string> ResolveHostToSid(string hostname, string domain) - 0572        { - 0573            var strippedHost = Helpers.StripServicePrincipalName(hostname).ToUpper().TrimEnd('$');547                        //Set our current range to the name of the attribute, which will tell us how far we are in "pagi + 0548                        currentRange = attr;549                        //Check if the string has the * character in it. If it does, we've reached the end of this searc + 0550                        complete = currentRange.IndexOf("*", 0, StringComparison.Ordinal) > 0;551                        //Set our step to the number of attributes that came back. + 0552                        step = entry.Attributes[currentRange].Count; + 0553                    }554 + 0555                    foreach (string val in entry.Attributes[currentRange].GetValues(typeof(string))) + 0556                    { + 0557                        yield return val; + 0558                        index++; + 0559                    }560 + 0561                    if (complete) yield break;562 + 0563                    currentRange = $"{baseString};range={index}-{index + step}"; + 0564                    searchRequest.Attributes.Clear(); + 0565                    searchRequest.Attributes.Add(currentRange); + 0566                }567                else + 0568                {569                    //Something went wrong here. + 0570                    yield break;571                } + 0572            }573        }  574 - 0575            if (_hostResolutionMap.TryGetValue(strippedHost, out var sid)) return sid;576 - 0577            var normalDomain = NormalizeDomainName(domain);578579            string tempName; - 0580            string tempDomain = null;581582            //Step 1: Handle non-IP address values - 0583            if (!IPAddress.TryParse(strippedHost, out _)) - 0584            {585                // Format: ABC.TESTLAB.LOCAL - 0586                if (strippedHost.Contains(".")) - 0587                { - 0588                    var split = strippedHost.Split('.'); - 0589                    tempName = split[0]; - 0590                    tempDomain = string.Join(".", split.Skip(1).ToArray()); - 0591                }592                // Format: WINDOWS593                else - 0594                { - 0595                    tempName = strippedHost; - 0596                    tempDomain = normalDomain; - 0597                }598599                // Add $ to the end of the name to match how computers are stored in AD - 0600                tempName = $"{tempName}$".ToUpper(); - 0601                var principal = ResolveAccountName(tempName, tempDomain); - 0602                sid = principal?.ObjectIdentifier; - 0603                if (sid != null) - 0604                { - 0605                    _hostResolutionMap.TryAdd(strippedHost, sid); - 0606                    return sid;607                } - 0608            }609610            //Step 2: Try NetWkstaGetInfo611            //Next we'll try calling NetWkstaGetInfo in hopes of getting the NETBIOS name directly from the computer612            //We'll use the hostname that we started with instead of the one from our previous step - 0613            var workstationInfo = await GetWorkstationInfo(strippedHost); - 0614            if (workstationInfo.HasValue) - 0615            { - 0616                tempName = workstationInfo.Value.ComputerName; - 0617                tempDomain = workstationInfo.Value.LanGroup;618 - 0619                if (string.IsNullOrEmpty(tempDomain)) - 0620                    tempDomain = normalDomain;621 - 0622                if (!string.IsNullOrEmpty(tempName)) - 0623                {624                    //Append the $ to indicate this is a computer - 0625                    tempName = $"{tempName}$".ToUpper(); - 0626                    var principal = ResolveAccountName(tempName, tempDomain); - 0627                    sid = principal?.ObjectIdentifier; - 0628                    if (sid != null) - 0629                    { - 0630                        _hostResolutionMap.TryAdd(strippedHost, sid); - 0631                        return sid;632                    } - 0633                } - 0634            }575        /// <summary>576        ///     Takes a host in most applicable forms from AD and attempts to resolve it into a SID.577        /// </summary>578        /// <param name="hostname"></param>579        /// <param name="domain"></param>580        /// <returns></returns>581        public async Task<string> ResolveHostToSid(string hostname, string domain) + 0582        { + 0583            var strippedHost = Helpers.StripServicePrincipalName(hostname).ToUpper().TrimEnd('$'); + 0584            if (string.IsNullOrEmpty(strippedHost)) + 0585            { + 0586                return null;587            }588 + 0589            if (_hostResolutionMap.TryGetValue(strippedHost, out var sid)) return sid;590 + 0591            var normalDomain = NormalizeDomainName(domain);592593            string tempName; + 0594            string tempDomain = null;595596            //Step 1: Handle non-IP address values + 0597            if (!IPAddress.TryParse(strippedHost, out _)) + 0598            {599                // Format: ABC.TESTLAB.LOCAL + 0600                if (strippedHost.Contains(".")) + 0601                { + 0602                    var split = strippedHost.Split('.'); + 0603                    tempName = split[0]; + 0604                    tempDomain = string.Join(".", split.Skip(1).ToArray()); + 0605                }606                // Format: WINDOWS607                else + 0608                { + 0609                    tempName = strippedHost; + 0610                    tempDomain = normalDomain; + 0611                }612613                // Add $ to the end of the name to match how computers are stored in AD + 0614                tempName = $"{tempName}$".ToUpper(); + 0615                var principal = ResolveAccountName(tempName, tempDomain); + 0616                sid = principal?.ObjectIdentifier; + 0617                if (sid != null) + 0618                { + 0619                    _hostResolutionMap.TryAdd(strippedHost, sid); + 0620                    return sid;621                } + 0622            }623624            //Step 2: Try NetWkstaGetInfo625            //Next we'll try calling NetWkstaGetInfo in hopes of getting the NETBIOS name directly from the computer626            //We'll use the hostname that we started with instead of the one from our previous step + 0627            var workstationInfo = await GetWorkstationInfo(strippedHost); + 0628            if (workstationInfo.HasValue) + 0629            { + 0630                tempName = workstationInfo.Value.ComputerName; + 0631                tempDomain = workstationInfo.Value.LanGroup;632 + 0633                if (string.IsNullOrEmpty(tempDomain)) + 0634                    tempDomain = normalDomain;  635636            //Step 3: Socket magic637            // Attempt to request the NETBIOS name of the computer directly - 0638            if (RequestNETBIOSNameFromComputer(strippedHost, normalDomain, out tempName)) - 0639            { - 0640                tempDomain ??= normalDomain; - 0641                tempName = $"{tempName}$".ToUpper();642 - 0643                var principal = ResolveAccountName(tempName, tempDomain); - 0644                sid = principal?.ObjectIdentifier; - 0645                if (sid != null) - 0646                { - 0647                    _hostResolutionMap.TryAdd(strippedHost, sid); - 0648                    return sid;649                } - 0650            }651652            //Try DNS resolution next653            string resolvedHostname;654            try - 0655            { - 0656                resolvedHostname = (await Dns.GetHostEntryAsync(strippedHost)).HostName; - 0657            } - 0658            catch - 0659            { - 0660                resolvedHostname = null; - 0661            }662 - 0663            if (resolvedHostname != null) - 0664            { - 0665                var splitName = resolvedHostname.Split('.'); - 0666                tempName = $"{splitName[0]}$".ToUpper(); - 0667                tempDomain = string.Join(".", splitName.Skip(1));668 - 0669                var principal = ResolveAccountName(tempName, tempDomain); - 0670                sid = principal?.ObjectIdentifier; - 0671                if (sid != null) - 0672                { - 0673                    _hostResolutionMap.TryAdd(strippedHost, sid); - 0674                    return sid;675                } - 0676            }677678            //If we get here, everything has failed, and life is very sad. - 0679            tempName = strippedHost; - 0680            tempDomain = normalDomain;681 - 0682            if (tempName.Contains(".")) - 0683            { - 0684                _hostResolutionMap.TryAdd(strippedHost, tempName); - 0685                return tempName;686            }687 - 0688            tempName = $"{tempName}.{tempDomain}"; - 0689            _hostResolutionMap.TryAdd(strippedHost, tempName); - 0690            return tempName; - 0691        }692693        /// <summary>694        ///     Attempts to convert a bare account name (usually from session enumeration) to its corresponding ID and o695        /// </summary>696        /// <param name="name"></param>697        /// <param name="domain"></param>698        /// <returns></returns>699        public TypedPrincipal ResolveAccountName(string name, string domain) - 0700        { - 0701            if (string.IsNullOrWhiteSpace(name)) - 0702                return null;703 - 0704            if (Cache.GetPrefixedValue(name, domain, out var id) && Cache.GetIDType(id, out var type)) - 0705                return new TypedPrincipal - 0706                { - 0707                    ObjectIdentifier = id, - 0708                    ObjectType = type - 0709                };710 - 0711            var d = NormalizeDomainName(domain); - 0712            var result = QueryLDAP($"(samaccountname={name})", SearchScope.Subtree, - 0713                CommonProperties.TypeResolutionProps, - 0714                d).DefaultIfEmpty(null).FirstOrDefault();715 - 0716            if (result == null) - 0717            { - 0718                _log.LogDebug("ResolveAccountName - unable to get result for {Name}", name); - 0719                return null;720            }721 - 0722            type = result.GetLabel(); - 0723            id = result.GetObjectIdentifier(); + 0636                if (!string.IsNullOrEmpty(tempName)) + 0637                {638                    //Append the $ to indicate this is a computer + 0639                    tempName = $"{tempName}$".ToUpper(); + 0640                    var principal = ResolveAccountName(tempName, tempDomain); + 0641                    sid = principal?.ObjectIdentifier; + 0642                    if (sid != null) + 0643                    { + 0644                        _hostResolutionMap.TryAdd(strippedHost, sid); + 0645                        return sid;646                    } + 0647                } + 0648            }649650            //Step 3: Socket magic651            // Attempt to request the NETBIOS name of the computer directly + 0652            if (RequestNETBIOSNameFromComputer(strippedHost, normalDomain, out tempName)) + 0653            { + 0654                tempDomain ??= normalDomain; + 0655                tempName = $"{tempName}$".ToUpper();656 + 0657                var principal = ResolveAccountName(tempName, tempDomain); + 0658                sid = principal?.ObjectIdentifier; + 0659                if (sid != null) + 0660                { + 0661                    _hostResolutionMap.TryAdd(strippedHost, sid); + 0662                    return sid;663                } + 0664            }665666            //Try DNS resolution next667            string resolvedHostname;668            try + 0669            { + 0670                resolvedHostname = (await Dns.GetHostEntryAsync(strippedHost)).HostName; + 0671            } + 0672            catch + 0673            { + 0674                resolvedHostname = null; + 0675            }676 + 0677            if (resolvedHostname != null) + 0678            { + 0679                var splitName = resolvedHostname.Split('.'); + 0680                tempName = $"{splitName[0]}$".ToUpper(); + 0681                tempDomain = string.Join(".", splitName.Skip(1));682 + 0683                var principal = ResolveAccountName(tempName, tempDomain); + 0684                sid = principal?.ObjectIdentifier; + 0685                if (sid != null) + 0686                { + 0687                    _hostResolutionMap.TryAdd(strippedHost, sid); + 0688                    return sid;689                } + 0690            }691692            //If we get here, everything has failed, and life is very sad. + 0693            tempName = strippedHost; + 0694            tempDomain = normalDomain;695 + 0696            if (tempName.Contains(".")) + 0697            { + 0698                _hostResolutionMap.TryAdd(strippedHost, tempName); + 0699                return tempName;700            }701 + 0702            tempName = $"{tempName}.{tempDomain}"; + 0703            _hostResolutionMap.TryAdd(strippedHost, tempName); + 0704            return tempName; + 0705        }706707        /// <summary>708        ///     Attempts to convert a bare account name (usually from session enumeration) to its corresponding ID and o709        /// </summary>710        /// <param name="name"></param>711        /// <param name="domain"></param>712        /// <returns></returns>713        public TypedPrincipal ResolveAccountName(string name, string domain) + 0714        { + 0715            if (string.IsNullOrWhiteSpace(name)) + 0716                return null;717 + 0718            if (Cache.GetPrefixedValue(name, domain, out var id) && Cache.GetIDType(id, out var type)) + 0719                return new TypedPrincipal + 0720                { + 0721                    ObjectIdentifier = id, + 0722                    ObjectType = type + 0723                };  724 - 0725            if (id == null) - 0726            { - 0727                _log.LogDebug("ResolveAccountName - could not retrieve ID on {DN} for {Name}", result.DistinguishedName, - 0728                    name); - 0729                return null;730            }731 - 0732            Cache.AddPrefixedValue(name, domain, id); - 0733            Cache.AddType(id, type);734 - 0735            id = ConvertWellKnownPrincipal(id, domain);736 - 0737            return new TypedPrincipal - 0738            { - 0739                ObjectIdentifier = id, - 0740                ObjectType = type - 0741            }; - 0742        }743744        /// <summary>745        ///     Attempts to convert a distinguishedname to its corresponding ID and object type.746        /// </summary>747        /// <param name="dn">DistinguishedName</param>748        /// <returns>A <c>TypedPrincipal</c> object with the SID and Label</returns>749        public TypedPrincipal ResolveDistinguishedName(string dn) - 0750        { - 0751            if (Cache.GetConvertedValue(dn, out var id) && Cache.GetIDType(id, out var type)) - 0752                return new TypedPrincipal - 0753                { - 0754                    ObjectIdentifier = id, - 0755                    ObjectType = type - 0756                }; + 0725            var d = NormalizeDomainName(domain); + 0726            var result = QueryLDAP($"(samaccountname={name})", SearchScope.Subtree, + 0727                CommonProperties.TypeResolutionProps, + 0728                d).DefaultIfEmpty(null).FirstOrDefault();729 + 0730            if (result == null) + 0731            { + 0732                _log.LogDebug("ResolveAccountName - unable to get result for {Name}", name); + 0733                return null;734            }735 + 0736            type = result.GetLabel(); + 0737            id = result.GetObjectIdentifier();738 + 0739            if (id == null) + 0740            { + 0741                _log.LogDebug("ResolveAccountName - could not retrieve ID on {DN} for {Name}", result.DistinguishedName, + 0742                    name); + 0743                return null;744            }745 + 0746            Cache.AddPrefixedValue(name, domain, id); + 0747            Cache.AddType(id, type);748 + 0749            id = ConvertWellKnownPrincipal(id, domain);750 + 0751            return new TypedPrincipal + 0752            { + 0753                ObjectIdentifier = id, + 0754                ObjectType = type + 0755            }; + 0756        }  757 - 0758            var domain = Helpers.DistinguishedNameToDomain(dn); - 0759            var result = QueryLDAP("(objectclass=*)", SearchScope.Base, CommonProperties.TypeResolutionProps, domain, - 0760                    adsPath: dn) - 0761                .DefaultIfEmpty(null).FirstOrDefault();762 - 0763            if (result == null) - 0764            { - 0765                _log.LogDebug("ResolveDistinguishedName - No result for {DN}", dn); - 0766                return null;767            }768 - 0769            id = result.GetObjectIdentifier(); - 0770            if (id == null) - 0771            { - 0772                _log.LogDebug("ResolveDistinguishedName - could not retrieve object identifier from {DN}", dn); - 0773                return null;774            }775 - 0776            if (GetWellKnownPrincipal(id, domain, out var principal)) return principal;777 - 0778            type = result.GetLabel();779 - 0780            Cache.AddConvertedValue(dn, id); - 0781            Cache.AddType(id, type);758        /// <summary>759        ///     Attempts to convert a distinguishedname to its corresponding ID and object type.760        /// </summary>761        /// <param name="dn">DistinguishedName</param>762        /// <returns>A <c>TypedPrincipal</c> object with the SID and Label</returns>763        public TypedPrincipal ResolveDistinguishedName(string dn) + 0764        { + 0765            if (Cache.GetConvertedValue(dn, out var id) && Cache.GetIDType(id, out var type)) + 0766                return new TypedPrincipal + 0767                { + 0768                    ObjectIdentifier = id, + 0769                    ObjectType = type + 0770                };771 + 0772            var domain = Helpers.DistinguishedNameToDomain(dn); + 0773            var result = QueryLDAP("(objectclass=*)", SearchScope.Base, CommonProperties.TypeResolutionProps, domain, + 0774                    adsPath: dn) + 0775                .DefaultIfEmpty(null).FirstOrDefault();776 + 0777            if (result == null) + 0778            { + 0779                _log.LogDebug("ResolveDistinguishedName - No result for {DN}", dn); + 0780                return null;781            }  782 - 0783            id = ConvertWellKnownPrincipal(id, domain);784 - 0785            return new TypedPrincipal - 0786            { - 0787                ObjectIdentifier = id, - 0788                ObjectType = type - 0789            }; - 0790        } + 0783            id = result.GetObjectIdentifier(); + 0784            if (id == null) + 0785            { + 0786                _log.LogDebug("ResolveDistinguishedName - could not retrieve object identifier from {DN}", dn); + 0787                return null;788            }789 + 0790            if (GetWellKnownPrincipal(id, domain, out var principal)) return principal;  791792        /// <summary>793        ///     Queries LDAP using LDAPQueryOptions794        /// </summary>795        /// <param name="options"></param>796        /// <returns></returns>797        public IEnumerable<ISearchResultEntry> QueryLDAP(LDAPQueryOptions options) - 2798        { - 2799            return QueryLDAP( - 2800                options.Filter, - 2801                options.Scope, - 2802                options.Properties, - 2803                options.CancellationToken, - 2804                options.DomainName, - 2805                options.IncludeAcl, - 2806                options.ShowDeleted, - 2807                options.AdsPath, - 2808                options.GlobalCatalog, - 2809                options.SkipCache, - 2810                options.ThrowException - 2811            ); - 2812        }813814        /// <summary>815        ///     Performs an LDAP query using the parameters specified by the user.816        /// </summary>817        /// <param name="ldapFilter">LDAP filter</param>818        /// <param name="scope">SearchScope to query</param>819        /// <param name="props">LDAP properties to fetch for each object</param>820        /// <param name="cancellationToken">Cancellation Token</param>821        /// <param name="includeAcl">Include the DACL and Owner values in the NTSecurityDescriptor</param>822        /// <param name="showDeleted">Include deleted objects</param>823        /// <param name="domainName">Domain to query</param>824        /// <param name="adsPath">ADS path to limit the query too</param>825        /// <param name="globalCatalog">Use the global catalog instead of the regular LDAP server</param>826        /// <param name="skipCache">827        ///     Skip the connection cache and force a new connection. You must dispose of this connection828        ///     yourself.829        /// </param>830        /// <param name="throwException">Throw exceptions rather than logging the errors directly</param>831        /// <returns>All LDAP search results matching the specified parameters</returns>832        /// <exception cref="LDAPQueryException">833        ///     Thrown when an error occurs during LDAP query (only when throwException = true)834        /// </exception>835        public IEnumerable<ISearchResultEntry> QueryLDAP(string ldapFilter, SearchScope scope,836            string[] props, CancellationToken cancellationToken, string domainName = null, bool includeAcl = false,837            bool showDeleted = false, string adsPath = null, bool globalCatalog = false, bool skipCache = false,838            bool throwException = false) - 4839        { - 4840            var queryParams = SetupLDAPQueryFilter( - 4841                ldapFilter, scope, props, includeAcl, domainName, includeAcl, adsPath, globalCatalog, skipCache);842 - 4843            if (queryParams.Exception != null) - 4844            { - 4845                _log.LogWarning("Failed to setup LDAP Query Filter: {Message}", queryParams.Exception.Message); - 6846                if (throwException) throw new LDAPQueryException("Failed to setup LDAP Query Filter", queryParams.Except - 2847                yield break;848            }849 - 0850            var conn = queryParams.Connection; - 0851            var request = queryParams.SearchRequest; - 0852            var pageControl = queryParams.PageControl;853 - 0854            PageResultResponseControl pageResponse = null; - 0855            var backoffDelay = MinBackoffDelay; - 0856            var retryCount = 0; - 0857            while (true) - 0858            { - 0859                if (cancellationToken.IsCancellationRequested) - 0860                    yield break;861862                SearchResponse response;863                try - 0864                { - 0865                    _log.LogTrace("Sending LDAP request for {Filter}", ldapFilter); - 0866                    response = (SearchResponse)conn.SendRequest(request); - 0867                    if (response != null) - 0868                        pageResponse = (PageResultResponseControl)response.Controls - 0869                            .Where(x => x is PageResultResponseControl).DefaultIfEmpty(null).FirstOrDefault(); - 0870                }catch (LdapException le) when (le.ErrorCode == (int)LdapErrorCodes.ServerDown && - 0871                                                retryCount < MaxRetries) - 0872                { - 0873                    retryCount++; - 0874                    Thread.Sleep(backoffDelay); - 0875                    backoffDelay = TimeSpan.FromSeconds(Math.Min( - 0876                        backoffDelay.TotalSeconds * BackoffDelayMultiplier.TotalSeconds, MaxBackoffDelay.TotalSeconds)); - 0877                    conn = CreateNewConnection(domainName, globalCatalog, skipCache); - 0878                    if (conn == null) - 0879                    { - 0880                        _log.LogError("Unable to create replacement ldap connection for ServerDown exception. Breaking l - 0881                        yield break;882                    }883 - 0884                    _log.LogInformation("Created new LDAP connection after receiving ServerDown from server"); - 0885                    continue; - 0886                }catch (LdapException le) when (le.ErrorCode == (int)LdapErrorCodes.Busy && retryCount < MaxRetries) { - 0887                    retryCount++; - 0888                    Thread.Sleep(backoffDelay); - 0889                    backoffDelay = TimeSpan.FromSeconds(Math.Min( - 0890                        backoffDelay.TotalSeconds * BackoffDelayMultiplier.TotalSeconds, MaxBackoffDelay.TotalSeconds)); - 0891                    continue;892                } - 0893                catch (LdapException le) - 0894                { - 0895                    if (le.ErrorCode != 82) - 0896                        if (throwException) - 0897                            throw new LDAPQueryException( - 0898                                $"LDAP Exception in Loop: {le.ErrorCode}. {le.ServerErrorMessage}. {le.Message}. Filter: - 0899                                le);900                        else - 0901                            _log.LogWarning(le, - 0902                                "LDAP Exception in Loop: {ErrorCode}. {ServerErrorMessage}. {Message}. Filter: {Filter}. - 0903                                le.ErrorCode, le.ServerErrorMessage, le.Message, ldapFilter, domainName);904 - 0905                    yield break;906                } - 0907                catch (Exception e) - 0908                { - 0909                    _log.LogWarning(e, "Exception in LDAP loop for {Filter} and {Domain}", ldapFilter, domainName); - 0910                    if (throwException) - 0911                        throw new LDAPQueryException($"Exception in LDAP loop for {ldapFilter} and {domainName}", e);912 - 0913                    yield break;914                }915 - 0916                if (cancellationToken.IsCancellationRequested) - 0917                    yield break;918 - 0919                if (response == null || pageResponse == null) - 0920                    continue;921 - 0922                foreach (SearchResultEntry entry in response.Entries) - 0923                { - 0924                    if (cancellationToken.IsCancellationRequested) - 0925                        yield break;926 - 0927                    yield return new SearchResultEntryWrapper(entry, this); - 0928                }929 - 0930                if (pageResponse.Cookie.Length == 0 || response.Entries.Count == 0 || - 0931                    cancellationToken.IsCancellationRequested) - 0932                    yield break;933 - 0934                pageControl.Cookie = pageResponse.Cookie; - 0935            }936        }937938        private LdapConnection CreateNewConnection(string domainName = null, bool globalCatalog = false, bool skipCache  - 0939        { - 0940            var task = globalCatalog - 0941                ? Task.Run(() => CreateGlobalCatalogConnection(domainName, _ldapConfig.AuthType)) - 0942                : Task.Run(() => CreateLDAPConnection(domainName, skipCache, _ldapConfig.AuthType));943944            try - 0945            { - 0946                return task.ConfigureAwait(false).GetAwaiter().GetResult();947            } - 0948            catch - 0949            { - 0950                return null;951            } - 0952        }953954        /// <summary>955        ///     Performs an LDAP query using the parameters specified by the user.956        /// </summary>957        /// <param name="ldapFilter">LDAP filter</param>958        /// <param name="scope">SearchScope to query</param>959        /// <param name="props">LDAP properties to fetch for each object</param>960        /// <param name="includeAcl">Include the DACL and Owner values in the NTSecurityDescriptor</param>961        /// <param name="showDeleted">Include deleted objects</param>962        /// <param name="domainName">Domain to query</param>963        /// <param name="adsPath">ADS path to limit the query too</param>964        /// <param name="globalCatalog">Use the global catalog instead of the regular LDAP server</param>965        /// <param name="skipCache">966        ///     Skip the connection cache and force a new connection. You must dispose of this connection967        ///     yourself.968        /// </param>969        /// <param name="throwException">Throw exceptions rather than logging the errors directly</param>970        /// <returns>All LDAP search results matching the specified parameters</returns>971        /// <exception cref="LDAPQueryException">972        ///     Thrown when an error occurs during LDAP query (only when throwException = true)973        /// </exception>974        public virtual IEnumerable<ISearchResultEntry> QueryLDAP(string ldapFilter, SearchScope scope,975            string[] props, string domainName = null, bool includeAcl = false, bool showDeleted = false,976            string adsPath = null, bool globalCatalog = false, bool skipCache = false, bool throwException = false) - 1977        { - 1978            var queryParams = SetupLDAPQueryFilter( - 1979                ldapFilter, scope, props, includeAcl, domainName, includeAcl, adsPath, globalCatalog, skipCache);980 - 1981            if (queryParams.Exception != null) - 1982            { - 1983                if (throwException) throw queryParams.Exception;984 - 1985                _log.LogWarning(queryParams.Exception, "Failed to setup LDAP Query Filter"); - 1986                yield break;987            } - 0988            var conn = queryParams.Connection; - 0989            var request = queryParams.SearchRequest; - 0990            var pageControl = queryParams.PageControl;991 - 0992            PageResultResponseControl pageResponse = null; + 0792            type = result.GetLabel();793 + 0794            Cache.AddConvertedValue(dn, id); + 0795            Cache.AddType(id, type);796 + 0797            id = ConvertWellKnownPrincipal(id, domain);798 + 0799            return new TypedPrincipal + 0800            { + 0801                ObjectIdentifier = id, + 0802                ObjectType = type + 0803            }; + 0804        }805806        /// <summary>807        ///     Queries LDAP using LDAPQueryOptions808        /// </summary>809        /// <param name="options"></param>810        /// <returns></returns>811        public IEnumerable<ISearchResultEntry> QueryLDAP(LDAPQueryOptions options) + 2812        { + 2813            return QueryLDAP( + 2814                options.Filter, + 2815                options.Scope, + 2816                options.Properties, + 2817                options.CancellationToken, + 2818                options.DomainName, + 2819                options.IncludeAcl, + 2820                options.ShowDeleted, + 2821                options.AdsPath, + 2822                options.GlobalCatalog, + 2823                options.SkipCache, + 2824                options.ThrowException + 2825            ); + 2826        }827828        /// <summary>829        ///     Performs an LDAP query using the parameters specified by the user.830        /// </summary>831        /// <param name="ldapFilter">LDAP filter</param>832        /// <param name="scope">SearchScope to query</param>833        /// <param name="props">LDAP properties to fetch for each object</param>834        /// <param name="cancellationToken">Cancellation Token</param>835        /// <param name="includeAcl">Include the DACL and Owner values in the NTSecurityDescriptor</param>836        /// <param name="showDeleted">Include deleted objects</param>837        /// <param name="domainName">Domain to query</param>838        /// <param name="adsPath">ADS path to limit the query too</param>839        /// <param name="globalCatalog">Use the global catalog instead of the regular LDAP server</param>840        /// <param name="skipCache">841        ///     Skip the connection cache and force a new connection. You must dispose of this connection842        ///     yourself.843        /// </param>844        /// <param name="throwException">Throw exceptions rather than logging the errors directly</param>845        /// <returns>All LDAP search results matching the specified parameters</returns>846        /// <exception cref="LDAPQueryException">847        ///     Thrown when an error occurs during LDAP query (only when throwException = true)848        /// </exception>849        public IEnumerable<ISearchResultEntry> QueryLDAP(string ldapFilter, SearchScope scope,850            string[] props, CancellationToken cancellationToken, string domainName = null, bool includeAcl = false,851            bool showDeleted = false, string adsPath = null, bool globalCatalog = false, bool skipCache = false,852            bool throwException = false) + 5853        { + 5854            var queryParams = SetupLDAPQueryFilter( + 5855                ldapFilter, scope, props, includeAcl, domainName, includeAcl, adsPath, globalCatalog, skipCache);856 + 5857            if (queryParams.Exception != null) + 5858            { + 5859                _log.LogWarning("Failed to setup LDAP Query Filter: {Message}", queryParams.Exception.Message); + 5860                if (throwException) + 2861                    throw new LDAPQueryException("Failed to setup LDAP Query Filter", queryParams.Exception); + 3862                yield break;863            }864 + 0865            var conn = queryParams.Connection; + 0866            var request = queryParams.SearchRequest; + 0867            var pageControl = queryParams.PageControl;868 + 0869            PageResultResponseControl pageResponse = null; + 0870            var backoffDelay = MinBackoffDelay; + 0871            var retryCount = 0; + 0872            while (true) + 0873            { + 0874                if (cancellationToken.IsCancellationRequested) + 0875                    yield break;876877                SearchResponse response;878                try + 0879                { + 0880                    _log.LogTrace("Sending LDAP request for {Filter}", ldapFilter); + 0881                    response = (SearchResponse)conn.SendRequest(request); + 0882                    if (response != null) + 0883                        pageResponse = (PageResultResponseControl)response.Controls + 0884                            .Where(x => x is PageResultResponseControl).DefaultIfEmpty(null).FirstOrDefault(); + 0885                } + 0886                catch (LdapException le) when (le.ErrorCode == (int)LdapErrorCodes.ServerDown && + 0887                                               retryCount < MaxRetries) + 0888                {889                    /*A ServerDown exception indicates that our connection is no longer valid for one of many reasons.890                    However, this function is generally called by multiple threads, so we need to be careful in recreati891                    the connection. Using a semaphore, we can ensure that only one thread is actually recreating the con892                    while the other threads that hit the ServerDown exception simply wait. The initial caller will hold 893                    and do a backoff delay before trying to make a new connection which will replace the existing connec894                    _ldapConnections cache. Other threads will retrieve the new connection from the cache instead of mak895                    This minimizes overhead of new connections while still fixing our core problem.*/896897                    //Always increment retry count + 0898                    retryCount++;899900                    //Attempt to acquire a lock + 0901                    if (Monitor.TryEnter(_lockObj)) + 0902                    {903                        //If we've acquired the lock, we want to immediately signal our reset event so everyone else wai + 0904                        _connectionResetEvent.Reset();905                        try + 0906                        {907                            //Sleep for our backoff + 0908                            Thread.Sleep(backoffDelay);909                            //Explicitly skip the cache so we don't get the same connection back + 0910                            conn = CreateNewConnection(domainName, globalCatalog, true); + 0911                            if (conn == null) + 0912                            { + 0913                                _log.LogError( + 0914                                    "Unable to create replacement ldap connection for ServerDown exception. Breaking loo + 0915                                yield break;916                            }917 + 0918                            _log.LogInformation("Created new LDAP connection after receiving ServerDown from server"); + 0919                        }920                        finally + 0921                        {922                            //Reset our event + release the lock + 0923                            _connectionResetEvent.Set(); + 0924                            Monitor.Exit(_lockObj); + 0925                        } + 0926                    }927                    else + 0928                    {929                        //If someone else is holding the reset event, we want to just wait and then pull the newly creat930                        //This event will be released after the first entrant thread is done making a new connection931                        //The thread.sleep is to prevent a potential, very unlikely race + 0932                        Thread.Sleep(50); + 0933                        _connectionResetEvent.WaitOne(); + 0934                        conn = CreateNewConnection(domainName, globalCatalog); + 0935                    }936 + 0937                    backoffDelay = GetNextBackoff(retryCount); + 0938                    continue;939                } + 0940                catch (LdapException le) when (le.ErrorCode == (int)LdapErrorCodes.Busy && retryCount < MaxRetries) + 0941                { + 0942                    retryCount++; + 0943                    backoffDelay = GetNextBackoff(retryCount); + 0944                    continue;945                } + 0946                catch (LdapException le) + 0947                { + 0948                    if (le.ErrorCode != (int)LdapErrorCodes.LocalError) + 0949                    { + 0950                        if (throwException) + 0951                        { + 0952                            throw new LDAPQueryException( + 0953                                $"LDAP Exception in Loop: {le.ErrorCode}. {le.ServerErrorMessage}. {le.Message}. Filter: + 0954                                le);955                        }956 + 0957                        _log.LogWarning(le, + 0958                            "LDAP Exception in Loop: {ErrorCode}. {ServerErrorMessage}. {Message}. Filter: {Filter}. Dom + 0959                            le.ErrorCode, le.ServerErrorMessage, le.Message, ldapFilter, domainName); + 0960                    }961 + 0962                    if (le.ErrorCode == (int)LdapErrorCodes.ServerDown) + 0963                    { + 0964                        throw new LDAPQueryException( + 0965                            $"LDAP Exception in Loop: {le.ErrorCode}. {le.ServerErrorMessage}. {le.Message}. Filter: {ld + 0966                            le);967                    }968 + 0969                    yield break;970                } + 0971                catch (Exception e) + 0972                { + 0973                    _log.LogWarning(e, "Exception in LDAP loop for {Filter} and {Domain}", ldapFilter, domainName); + 0974                    if (throwException) + 0975                        throw new LDAPQueryException($"Exception in LDAP loop for {ldapFilter} and {domainName}", e);976 + 0977                    yield break;978                }979 + 0980                if (cancellationToken.IsCancellationRequested) + 0981                    yield break;982 + 0983                if (response == null || pageResponse == null) + 0984                    continue;985 + 0986                foreach (SearchResultEntry entry in response.Entries) + 0987                { + 0988                    if (cancellationToken.IsCancellationRequested) + 0989                        yield break;990 + 0991                    yield return new SearchResultEntryWrapper(entry, this); + 0992                }  993 - 0994            var backoffDelay = MinBackoffDelay; - 0995            var retryCount = 0;996 - 0997            while (true) - 0998            {999                SearchResponse response;10001001                try - 01002                { - 01003                    _log.LogTrace("Sending LDAP request for {Filter}", ldapFilter); - 01004                    response = (SearchResponse)conn.SendRequest(request); - 01005                    if (response != null) - 01006                        pageResponse = (PageResultResponseControl)response.Controls - 01007                            .Where(x => x is PageResultResponseControl).DefaultIfEmpty(null).FirstOrDefault(); - 01008                } - 01009                catch (LdapException le) when (le.ErrorCode == (int)LdapErrorCodes.Busy && retryCount < MaxRetries) - 01010                { - 01011                    retryCount++; - 01012                    Thread.Sleep(backoffDelay); - 01013                    backoffDelay = TimeSpan.FromSeconds(Math.Min( - 01014                        backoffDelay.TotalSeconds * BackoffDelayMultiplier.TotalSeconds, MaxBackoffDelay.TotalSeconds)); - 01015                    continue;1016                } - 01017                catch (LdapException le) when (le.ErrorCode == (int)LdapErrorCodes.ServerDown && - 01018                                               retryCount < MaxRetries) - 01019                { - 01020                    retryCount++; - 01021                    Thread.Sleep(backoffDelay); - 01022                    backoffDelay = TimeSpan.FromSeconds(Math.Min( - 01023                        backoffDelay.TotalSeconds * BackoffDelayMultiplier.TotalSeconds, MaxBackoffDelay.TotalSeconds)); - 01024                    conn = CreateNewConnection(domainName, globalCatalog, skipCache); - 01025                    if (conn == null) - 01026                    { - 01027                        _log.LogError("Unable to create replacement ldap connection for ServerDown exception. Breaking l - 01028                        yield break;1029                    }1030 - 01031                    _log.LogInformation("Created new LDAP connection after receiving ServerDown from server"); - 01032                    continue;1033                } - 01034                catch (LdapException le) - 01035                { - 01036                    if (le.ErrorCode != 82) - 01037                        if (throwException) - 01038                            throw new LDAPQueryException( - 01039                                $"LDAP Exception in Loop: {le.ErrorCode}. {le.ServerErrorMessage}. {le.Message}. Filter: - 01040                                le);1041                        else - 01042                            _log.LogWarning(le, - 01043                                "LDAP Exception in Loop: {ErrorCode}. {ServerErrorMessage}. {Message}. Filter: {Filter}. - 01044                                le.ErrorCode, le.ServerErrorMessage, le.Message, ldapFilter, domainName); - 01045                    yield break;1046                } - 01047                catch (Exception e) - 01048                { - 01049                    if (throwException) - 01050                        throw new LDAPQueryException( - 01051                            $"Exception in LDAP loop for {ldapFilter} and {domainName ?? "Default Domain"}", e);1052 - 01053                    _log.LogWarning(e, "Exception in LDAP loop for {Filter} and {Domain}", ldapFilter, - 01054                        domainName ?? "Default Domain"); - 01055                    yield break;1056                }1057 - 01058                if (response == null || pageResponse == null) continue;1059 - 01060                if (response.Entries == null) - 01061                    yield break;1062 - 01063                foreach (SearchResultEntry entry in response.Entries) - 01064                    yield return new SearchResultEntryWrapper(entry, this);1065 - 01066                if (pageResponse.Cookie.Length == 0 || response.Entries.Count == 0) - 01067                    yield break;1068 - 01069                pageControl.Cookie = pageResponse.Cookie; - 01070            }1071        }10721073        /// <summary>1074        ///     Gets the forest associated with a domain.1075        ///     If no domain is provided, defaults to current domain1076        /// </summary>1077        /// <param name="domainName"></param>1078        /// <returns></returns>1079        public virtual Forest GetForest(string domainName = null) - 351080        {1081            try - 351082            { - 351083                if (domainName == null && _ldapConfig.Username == null) - 351084                    return Forest.GetCurrentForest(); + 0994                if (pageResponse.Cookie.Length == 0 || response.Entries.Count == 0 || + 0995                    cancellationToken.IsCancellationRequested) + 0996                    yield break;997 + 0998                pageControl.Cookie = pageResponse.Cookie; + 0999            }1000        }10011002        private LdapConnection CreateNewConnection(string domainName = null, bool globalCatalog = false,1003            bool skipCache = false) + 01004        { + 01005            var task = globalCatalog + 01006                ? Task.Run(() => CreateGlobalCatalogConnection(domainName, _ldapConfig.AuthType)) + 01007                : Task.Run(() => CreateLDAPConnection(domainName, skipCache, _ldapConfig.AuthType));10081009            try + 01010            { + 01011                return task.ConfigureAwait(false).GetAwaiter().GetResult();1012            } + 01013            catch + 01014            { + 01015                return null;1016            } + 01017        }10181019        /// <summary>1020        ///     Performs an LDAP query using the parameters specified by the user.1021        /// </summary>1022        /// <param name="ldapFilter">LDAP filter</param>1023        /// <param name="scope">SearchScope to query</param>1024        /// <param name="props">LDAP properties to fetch for each object</param>1025        /// <param name="includeAcl">Include the DACL and Owner values in the NTSecurityDescriptor</param>1026        /// <param name="showDeleted">Include deleted objects</param>1027        /// <param name="domainName">Domain to query</param>1028        /// <param name="adsPath">ADS path to limit the query too</param>1029        /// <param name="globalCatalog">Use the global catalog instead of the regular LDAP server</param>1030        /// <param name="skipCache">1031        ///     Skip the connection cache and force a new connection. You must dispose of this connection1032        ///     yourself.1033        /// </param>1034        /// <param name="throwException">Throw exceptions rather than logging the errors directly</param>1035        /// <returns>All LDAP search results matching the specified parameters</returns>1036        /// <exception cref="LDAPQueryException">1037        ///     Thrown when an error occurs during LDAP query (only when throwException = true)1038        /// </exception>1039        public virtual IEnumerable<ISearchResultEntry> QueryLDAP(string ldapFilter, SearchScope scope,1040            string[] props, string domainName = null, bool includeAcl = false, bool showDeleted = false,1041            string adsPath = null, bool globalCatalog = false, bool skipCache = false, bool throwException = false) + 11042        { + 11043            return QueryLDAP(ldapFilter, scope, props, new CancellationToken(), domainName, includeAcl, showDeleted, + 11044                adsPath, globalCatalog, skipCache, throwException); + 11045        }10461047        private static TimeSpan GetNextBackoff(int retryCount) + 01048        { + 01049            return TimeSpan.FromSeconds(Math.Min( + 01050                MinBackoffDelay.TotalSeconds * Math.Pow(BackoffDelayMultiplier, retryCount), + 01051                MaxBackoffDelay.TotalSeconds)); + 01052        }10531054        /// <summary>1055        ///     Gets the forest associated with a domain.1056        ///     If no domain is provided, defaults to current domain1057        /// </summary>1058        /// <param name="domainName"></param>1059        /// <returns></returns>1060        public virtual Forest GetForest(string domainName = null) + 351061        {1062            try + 351063            { + 351064                if (domainName == null && _ldapConfig.Username == null) + 351065                    return Forest.GetCurrentForest();1066 + 01067                var domain = GetDomain(domainName); + 01068                return domain?.Forest;1069            } + 351070            catch + 351071            { + 351072                return null;1073            } + 351074        }10751076        /// <summary>1077        ///     Creates a new ActiveDirectorySecurityDescriptor1078        ///     Function created for testing purposes1079        /// </summary>1080        /// <returns></returns>1081        public ActiveDirectorySecurityDescriptor MakeSecurityDescriptor() + 01082        { + 01083            return new ActiveDirectorySecurityDescriptor(new ActiveDirectorySecurity()); + 01084        }  1085 - 01086                var domain = GetDomain(domainName); - 01087                return domain?.Forest;1088            } - 351089            catch - 351090            { - 351091                return null;1092            } - 351093        }10941095        /// <summary>1096        ///     Creates a new ActiveDirectorySecurityDescriptor1097        ///     Function created for testing purposes1086        public string BuildLdapPath(string dnPath, string domainName) + 21087        { + 21088            var domain = GetDomain(domainName)?.Name; + 21089            if (domain == null) + 11090                return null;1091 + 11092            var adPath = $"{dnPath},DC={domain.Replace(".", ",DC=")}"; + 11093            return adPath; + 21094        }10951096        /// <summary>1097        ///     Tests the current LDAP config to ensure its valid by pulling a domain object  1098        /// </summary>1099        /// <returns></returns>1100        public ActiveDirectorySecurityDescriptor MakeSecurityDescriptor()1099        /// <returns>True if connection was successful, else false</returns>1100        public bool TestLDAPConfig(string domain)  01101        { - 01102            return new ActiveDirectorySecurityDescriptor(new ActiveDirectorySecurity()); - 01103        } + 01102            var filter = new LDAPFilter(); + 01103            filter.AddDomains();  11041105        public string BuildLdapPath(string dnPath, string domainName) - 21106        { - 21107            var domain = GetDomain(domainName)?.Name; - 21108            if (domain == null) - 11109                return null;1110 - 11111            var adPath = $"{dnPath},DC={domain.Replace(".", ",DC=")}"; - 11112            return adPath; - 21113        } + 01105            var resDomain = GetDomain(domain)?.Name ?? domain; + 01106            _log.LogTrace("Testing LDAP connection for domain {Domain}", resDomain);1107 + 01108            var result = QueryLDAP(filter.GetFilter(), SearchScope.Subtree, CommonProperties.ObjectID, resDomain, + 01109                    throwException: true) + 01110                .DefaultIfEmpty(null).FirstOrDefault(); + 01111            _log.LogTrace("Result object from LDAP connection test is {DN}", result?.DistinguishedName ?? "null"); + 01112            return result != null; + 01113        }  1114  1115        /// <summary>1116        ///     Tests the current LDAP config to ensure its valid by pulling a domain object1117        /// </summary>1118        /// <returns>True if connection was successful, else false</returns>1119        public bool TestLDAPConfig(string domain) - 01120        { - 01121            var filter = new LDAPFilter(); - 01122            filter.AddDomains();1123 - 01124            var resDomain = GetDomain(domain)?.Name ?? domain; - 01125            _log.LogTrace("Testing LDAP connection for domain {Domain}", resDomain);1126 - 01127            var result = QueryLDAP(filter.GetFilter(), SearchScope.Subtree, CommonProperties.ObjectID, resDomain, - 01128                    throwException: true) - 01129                .DefaultIfEmpty(null).FirstOrDefault(); - 01130            _log.LogTrace("Result object from LDAP connection test is {DN}", result?.DistinguishedName ?? "null"); - 01131            return result != null; - 01132        }11331134        /// <summary>1135        ///     Gets the domain object associated with the specified domain name.1136        ///     Defaults to current domain if none specified1137        /// </summary>1138        /// <param name="domainName"></param>1139        /// <returns></returns>1140        public virtual Domain GetDomain(string domainName = null) - 51141        { - 51142            var cacheKey = domainName ?? NullCacheKey; - 71143            if (_domainCache.TryGetValue(cacheKey, out var domain)) return domain;11441145            try - 31146            {1147                DirectoryContext context; - 31148                if (_ldapConfig.Username != null) - 01149                    context = domainName != null - 01150                        ? new DirectoryContext(DirectoryContextType.Domain, domainName, _ldapConfig.Username, - 01151                            _ldapConfig.Password) - 01152                        : new DirectoryContext(DirectoryContextType.Domain, _ldapConfig.Username, - 01153                            _ldapConfig.Password);1154                else - 31155                    context = domainName != null - 31156                        ? new DirectoryContext(DirectoryContextType.Domain, domainName) - 31157                        : new DirectoryContext(DirectoryContextType.Domain);1158 - 31159                domain = Domain.GetDomain(context); - 01160            } - 31161            catch (Exception e) - 31162            { - 31163                _log.LogDebug(e, "GetDomain call failed at {StackTrace}", new StackFrame()); - 31164                domain = null; - 31165            }1166 - 31167            _domainCache.TryAdd(cacheKey, domain); - 31168            return domain; - 51169        }11701171        /// <summary>1172        ///     Setup LDAP query for filter1173        /// </summary>1174        /// <param name="ldapFilter">LDAP filter</param>1175        /// <param name="scope">SearchScope to query</param>1176        /// <param name="props">LDAP properties to fetch for each object</param>1177        /// <param name="includeAcl">Include the DACL and Owner values in the NTSecurityDescriptor</param>1178        /// <param name="domainName">Domain to query</param>1179        /// <param name="showDeleted">Include deleted objects</param>1180        /// <param name="adsPath">ADS path to limit the query too</param>1181        /// <param name="globalCatalog">Use the global catalog instead of the regular LDAP server</param>1182        /// <param name="skipCache">1183        ///     Skip the connection cache and force a new connection. You must dispose of this connection1184        ///     yourself.1185        /// </param>1186        /// <returns>Tuple of LdapConnection, SearchRequest, PageResultRequestControl and LDAPQueryException</returns>1187        // ReSharper disable once MemberCanBePrivate.Global1188        internal LDAPQueryParams SetupLDAPQueryFilter(1189            string ldapFilter,1190            SearchScope scope, string[] props, bool includeAcl = false, string domainName = null,1191            bool showDeleted = false,1192            string adsPath = null, bool globalCatalog = false, bool skipCache = false) - 51193        { - 51194            _log.LogTrace("Creating ldap connection for {Target} with filter {Filter}", - 51195                globalCatalog ? "Global Catalog" : "DC", ldapFilter); - 51196            var task = globalCatalog - 11197                ? Task.Run(() => CreateGlobalCatalogConnection(domainName, _ldapConfig.AuthType)) - 91198                : Task.Run(() => CreateLDAPConnection(domainName, skipCache, _ldapConfig.AuthType));1199 - 51200            var queryParams = new LDAPQueryParams();12011202            LdapConnection conn;1203            try - 51204            { - 51205                conn = task.ConfigureAwait(false).GetAwaiter().GetResult(); - 01206            } - 01207            catch (LdapException ldapException) - 01208            { - 01209                var errorString = - 01210                    $"LDAP Exception {ldapException.ErrorCode} when creating connection for {ldapFilter} and domain {dom - 01211                queryParams.Exception = new LDAPQueryException(errorString, ldapException); - 01212                return queryParams;1213            } - 51214            catch (LDAPQueryException ldapQueryException) - 51215            { - 51216                queryParams.Exception = ldapQueryException; - 51217                return queryParams;1218            } - 01219            catch (Exception e)1116        ///     Gets the domain object associated with the specified domain name.1117        ///     Defaults to current domain if none specified1118        /// </summary>1119        /// <param name="domainName"></param>1120        /// <returns></returns>1121        public virtual Domain GetDomain(string domainName = null) + 51122        { + 51123            var cacheKey = domainName ?? NullCacheKey; + 71124            if (_domainCache.TryGetValue(cacheKey, out var domain)) return domain;11251126            try + 31127            {1128                DirectoryContext context; + 31129                if (_ldapConfig.Username != null) + 01130                    context = domainName != null + 01131                        ? new DirectoryContext(DirectoryContextType.Domain, domainName, _ldapConfig.Username, + 01132                            _ldapConfig.Password) + 01133                        : new DirectoryContext(DirectoryContextType.Domain, _ldapConfig.Username, + 01134                            _ldapConfig.Password);1135                else + 31136                    context = domainName != null + 31137                        ? new DirectoryContext(DirectoryContextType.Domain, domainName) + 31138                        : new DirectoryContext(DirectoryContextType.Domain);1139 + 31140                domain = Domain.GetDomain(context); + 01141            } + 31142            catch (Exception e) + 31143            { + 31144                _log.LogDebug(e, "GetDomain call failed at {StackTrace}", new StackFrame()); + 31145                domain = null; + 31146            }1147 + 31148            _domainCache.TryAdd(cacheKey, domain); + 31149            return domain; + 51150        }11511152        /// <summary>1153        ///     Setup LDAP query for filter1154        /// </summary>1155        /// <param name="ldapFilter">LDAP filter</param>1156        /// <param name="scope">SearchScope to query</param>1157        /// <param name="props">LDAP properties to fetch for each object</param>1158        /// <param name="includeAcl">Include the DACL and Owner values in the NTSecurityDescriptor</param>1159        /// <param name="domainName">Domain to query</param>1160        /// <param name="showDeleted">Include deleted objects</param>1161        /// <param name="adsPath">ADS path to limit the query too</param>1162        /// <param name="globalCatalog">Use the global catalog instead of the regular LDAP server</param>1163        /// <param name="skipCache">1164        ///     Skip the connection cache and force a new connection. You must dispose of this connection1165        ///     yourself.1166        /// </param>1167        /// <returns>Tuple of LdapConnection, SearchRequest, PageResultRequestControl and LDAPQueryException</returns>1168        // ReSharper disable once MemberCanBePrivate.Global1169        internal LDAPQueryParams SetupLDAPQueryFilter(1170            string ldapFilter,1171            SearchScope scope, string[] props, bool includeAcl = false, string domainName = null,1172            bool showDeleted = false,1173            string adsPath = null, bool globalCatalog = false, bool skipCache = false) + 51174        { + 51175            _log.LogTrace("Creating ldap connection for {Target} with filter {Filter}", + 51176                globalCatalog ? "Global Catalog" : "DC", ldapFilter); + 51177            var task = globalCatalog + 11178                ? Task.Run(() => CreateGlobalCatalogConnection(domainName, _ldapConfig.AuthType)) + 91179                : Task.Run(() => CreateLDAPConnection(domainName, skipCache, _ldapConfig.AuthType));1180 + 51181            var queryParams = new LDAPQueryParams();11821183            LdapConnection conn;1184            try + 51185            { + 51186                conn = task.ConfigureAwait(false).GetAwaiter().GetResult(); + 01187            } + 01188            catch (LdapException ldapException) + 01189            { + 01190                var errorString = + 01191                    $"LDAP Exception {ldapException.ErrorCode} when creating connection for {ldapFilter} and domain {dom + 01192                queryParams.Exception = new LDAPQueryException(errorString, ldapException); + 01193                return queryParams;1194            } + 51195            catch (LDAPQueryException ldapQueryException) + 51196            { + 51197                queryParams.Exception = ldapQueryException; + 51198                return queryParams;1199            } + 01200            catch (Exception e) + 01201            { + 01202                var errorString = + 01203                    $"Exception getting LDAP connection for {ldapFilter} and domain {domainName ?? "Default Domain"}"; + 01204                queryParams.Exception = new LDAPQueryException(errorString, e); + 01205                return queryParams;1206            }12071208            //If we get a null connection, something went wrong, but we don't have an error to go with it for whatever r + 01209            if (conn == null) + 01210            { + 01211                var errorString = + 01212                    $"LDAP connection is null for filter {ldapFilter} and domain {domainName ?? "Default Domain"}"; + 01213                queryParams.Exception = new LDAPQueryException(errorString); + 01214                return queryParams;1215            }12161217            SearchRequest request;12181219            try  01220            { - 01221                var errorString = - 01222                    $"Exception getting LDAP connection for {ldapFilter} and domain {domainName ?? "Default Domain"}"; - 01223                queryParams.Exception = new LDAPQueryException(errorString, e); - 01224                return queryParams;1225            }12261227            //If we get a null connection, something went wrong, but we don't have an error to go with it for whatever r - 01228            if (conn == null) - 01229            { - 01230                var errorString = - 01231                    $"LDAP connection is null for filter {ldapFilter} and domain {domainName ?? "Default Domain"}"; - 01232                queryParams.Exception = new LDAPQueryException(errorString); - 01233                return queryParams;1234            }12351236            SearchRequest request;12371238            try - 01239            { - 01240                request = CreateSearchRequest(ldapFilter, scope, props, domainName, adsPath, showDeleted); - 01241            } - 01242            catch (LDAPQueryException ldapQueryException) - 01243            { - 01244                queryParams.Exception = ldapQueryException; - 01245                return queryParams;1246            }1247 - 01248            if (request == null) - 01249            { - 01250                var errorString = - 01251                    $"Search request is null for filter {ldapFilter} and domain {domainName ?? "Default Domain"}"; - 01252                queryParams.Exception = new LDAPQueryException(errorString); - 01253                return queryParams;1254            }1255 - 01256            var pageControl = new PageResultRequestControl(500); - 01257            request.Controls.Add(pageControl);1258 - 01259            if (includeAcl) - 01260                request.Controls.Add(new SecurityDescriptorFlagControl - 01261                { - 01262                    SecurityMasks = SecurityMasks.Dacl | SecurityMasks.Owner - 01263                });1264 - 01265            queryParams.Connection = conn; - 01266            queryParams.SearchRequest = request; - 01267            queryParams.PageControl = pageControl;1268 - 01269            return queryParams; - 51270        }12711272        private Group GetBaseEnterpriseDC(string domain) - 01273        { - 01274            var forest = GetForest(domain)?.Name; - 01275            if (forest == null) _log.LogWarning("Error getting forest, ENTDC sid is likely incorrect"); - 01276            var g = new Group { ObjectIdentifier = $"{forest}-S-1-5-9".ToUpper() }; - 01277            g.Properties.Add("name", $"ENTERPRISE DOMAIN CONTROLLERS@{forest ?? "UNKNOWN"}".ToUpper()); - 01278            g.Properties.Add("domainsid", GetSidFromDomainName(forest)); - 01279            g.Properties.Add("domain", forest); - 01280            return g; - 01281        }12821283        /// <summary>1284        ///     Updates the config for querying LDAP1285        /// </summary>1286        /// <param name="config"></param>1287        public void UpdateLDAPConfig(LDAPConfig config) - 01288        { - 01289            _ldapConfig = config; - 01290        }12911292        private string GetDomainNameFromSidLdap(string sid) - 01293        { - 01294            var hexSid = Helpers.ConvertSidToHexSid(sid); + 01221                request = CreateSearchRequest(ldapFilter, scope, props, domainName, adsPath, showDeleted); + 01222            } + 01223            catch (LDAPQueryException ldapQueryException) + 01224            { + 01225                queryParams.Exception = ldapQueryException; + 01226                return queryParams;1227            }1228 + 01229            if (request == null) + 01230            { + 01231                var errorString = + 01232                    $"Search request is null for filter {ldapFilter} and domain {domainName ?? "Default Domain"}"; + 01233                queryParams.Exception = new LDAPQueryException(errorString); + 01234                return queryParams;1235            }1236 + 01237            var pageControl = new PageResultRequestControl(500); + 01238            request.Controls.Add(pageControl);1239 + 01240            if (includeAcl) + 01241                request.Controls.Add(new SecurityDescriptorFlagControl + 01242                { + 01243                    SecurityMasks = SecurityMasks.Dacl | SecurityMasks.Owner + 01244                });1245 + 01246            queryParams.Connection = conn; + 01247            queryParams.SearchRequest = request; + 01248            queryParams.PageControl = pageControl;1249 + 01250            return queryParams; + 51251        }12521253        private Group GetBaseEnterpriseDC(string domain) + 01254        { + 01255            var forest = GetForest(domain)?.Name; + 01256            if (forest == null) _log.LogWarning("Error getting forest, ENTDC sid is likely incorrect"); + 01257            var g = new Group { ObjectIdentifier = $"{forest}-S-1-5-9".ToUpper() }; + 01258            g.Properties.Add("name", $"ENTERPRISE DOMAIN CONTROLLERS@{forest ?? "UNKNOWN"}".ToUpper()); + 01259            g.Properties.Add("domainsid", GetSidFromDomainName(forest)); + 01260            g.Properties.Add("domain", forest); + 01261            return g; + 01262        }12631264        /// <summary>1265        ///     Updates the config for querying LDAP1266        /// </summary>1267        /// <param name="config"></param>1268        public void UpdateLDAPConfig(LDAPConfig config) + 01269        { + 01270            _ldapConfig = config; + 01271        }12721273        private string GetDomainNameFromSidLdap(string sid) + 01274        { + 01275            var hexSid = Helpers.ConvertSidToHexSid(sid);1276 + 01277            if (hexSid == null) + 01278                return null;12791280            //Search using objectsid first + 01281            var result = + 01282                QueryLDAP($"(&(objectclass=domain)(objectsid={hexSid}))", SearchScope.Subtree, + 01283                    new[] { "distinguishedname" }, globalCatalog: true).DefaultIfEmpty(null).FirstOrDefault();1284 + 01285            if (result != null) + 01286            { + 01287                var domainName = Helpers.DistinguishedNameToDomain(result.DistinguishedName); + 01288                return domainName;1289            }12901291            //Try trusteddomain objects with the securityidentifier attribute + 01292            result = + 01293                QueryLDAP($"(&(objectclass=trusteddomain)(securityidentifier={sid}))", SearchScope.Subtree, + 01294                    new[] { "cn" }, globalCatalog: true).DefaultIfEmpty(null).FirstOrDefault();  1295 - 01296            if (hexSid == null) - 01297                return null;12981299            //Search using objectsid first - 01300            var result = - 01301                QueryLDAP($"(&(objectclass=domain)(objectsid={hexSid}))", SearchScope.Subtree, - 01302                    new[] { "distinguishedname" }, globalCatalog: true).DefaultIfEmpty(null).FirstOrDefault();1303 - 01304            if (result != null) - 01305            { - 01306                var domainName = Helpers.DistinguishedNameToDomain(result.DistinguishedName); - 01307                return domainName;1308            }13091310            //Try trusteddomain objects with the securityidentifier attribute - 01311            result = - 01312                QueryLDAP($"(&(objectclass=trusteddomain)(securityidentifier={sid}))", SearchScope.Subtree, - 01313                    new[] { "cn" }, globalCatalog: true).DefaultIfEmpty(null).FirstOrDefault();1314 - 01315            if (result != null) - 01316            { - 01317                var domainName = result.GetProperty(LDAPProperties.CanonicalName); - 01318                return domainName;1319            }13201321            //We didn't find anything so just return null - 01322            return null; - 01323        }13241325        /// <summary>1326        ///     Uses a socket and a set of bytes to request the NETBIOS name from a remote computer1327        /// </summary>1328        /// <param name="server"></param>1329        /// <param name="domain"></param>1330        /// <param name="netbios"></param>1331        /// <returns></returns>1332        private static bool RequestNETBIOSNameFromComputer(string server, string domain, out string netbios) - 01333        { - 01334            var receiveBuffer = new byte[1024]; - 01335            var requestSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp);1336            try - 01337            {1338                //Set receive timeout to 1 second - 01339                requestSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReceiveTimeout, 1000);1340                EndPoint remoteEndpoint;13411342                //We need to create an endpoint to bind too. If its an IP, just use that. - 01343                if (IPAddress.TryParse(server, out var parsedAddress)) - 01344                    remoteEndpoint = new IPEndPoint(parsedAddress, 137);1345                else1346                    //If its not an IP, we're going to try and resolve it from DNS1347                    try - 01348                    {1349                        IPAddress address; - 01350                        if (server.Contains(".")) - 01351                            address = Dns - 01352                                .GetHostAddresses(server).First(x => x.AddressFamily == AddressFamily.InterNetwork);1353                        else - 01354                            address = Dns.GetHostAddresses($"{server}.{domain}")[0];1355 - 01356                        if (address == null) - 01357                        { - 01358                            netbios = null; - 01359                            return false;1360                        }1361 - 01362                        remoteEndpoint = new IPEndPoint(address, 137); - 01363                    } - 01364                    catch - 01365                    {1366                        //Failed to resolve an IP, so return null - 01367                        netbios = null; - 01368                        return false;1369                    }1370 - 01371                var originEndpoint = new IPEndPoint(IPAddress.Any, 0); - 01372                requestSocket.Bind(originEndpoint);13731374                try - 01375                { - 01376                    requestSocket.SendTo(NameRequest, remoteEndpoint); - 01377                    var receivedByteCount = requestSocket.ReceiveFrom(receiveBuffer, ref remoteEndpoint); - 01378                    if (receivedByteCount >= 90) - 01379                    { - 01380                        netbios = new ASCIIEncoding().GetString(receiveBuffer, 57, 16).Trim('\0', ' '); - 01381                        return true;1382                    }1383 - 01384                    netbios = null; - 01385                    return false;1386                } - 01387                catch (SocketException) - 01388                { - 01389                    netbios = null; - 01390                    return false;1391                }1392            }1393            finally - 01394            {1395                //Make sure we close the socket if its open - 01396                requestSocket.Close(); - 01397            } - 01398        }13991400        /// <summary>1401        ///     Calls the NetWkstaGetInfo API on a hostname1402        /// </summary>1403        /// <param name="hostname"></param>1404        /// <returns></returns>1405        private async Task<NetAPIStructs.WorkstationInfo100?> GetWorkstationInfo(string hostname) - 01406        { - 01407            if (!await _portScanner.CheckPort(hostname)) - 01408                return null;1409 - 01410            var result = NetAPIMethods.NetWkstaGetInfo(hostname); - 01411            if (result.IsSuccess) return result.Value;1412 - 01413            return null; - 01414        } + 01296            if (result != null) + 01297            { + 01298                var domainName = result.GetProperty(LDAPProperties.CanonicalName); + 01299                return domainName;1300            }13011302            //We didn't find anything so just return null + 01303            return null; + 01304        }13051306        /// <summary>1307        ///     Uses a socket and a set of bytes to request the NETBIOS name from a remote computer1308        /// </summary>1309        /// <param name="server"></param>1310        /// <param name="domain"></param>1311        /// <param name="netbios"></param>1312        /// <returns></returns>1313        private static bool RequestNETBIOSNameFromComputer(string server, string domain, out string netbios) + 01314        { + 01315            var receiveBuffer = new byte[1024]; + 01316            var requestSocket = new Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp);1317            try + 01318            {1319                //Set receive timeout to 1 second + 01320                requestSocket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.ReceiveTimeout, 1000);1321                EndPoint remoteEndpoint;13221323                //We need to create an endpoint to bind too. If its an IP, just use that. + 01324                if (IPAddress.TryParse(server, out var parsedAddress)) + 01325                    remoteEndpoint = new IPEndPoint(parsedAddress, 137);1326                else1327                    //If its not an IP, we're going to try and resolve it from DNS1328                    try + 01329                    {1330                        IPAddress address; + 01331                        if (server.Contains(".")) + 01332                            address = Dns + 01333                                .GetHostAddresses(server).First(x => x.AddressFamily == AddressFamily.InterNetwork);1334                        else + 01335                            address = Dns.GetHostAddresses($"{server}.{domain}")[0];1336 + 01337                        if (address == null) + 01338                        { + 01339                            netbios = null; + 01340                            return false;1341                        }1342 + 01343                        remoteEndpoint = new IPEndPoint(address, 137); + 01344                    } + 01345                    catch + 01346                    {1347                        //Failed to resolve an IP, so return null + 01348                        netbios = null; + 01349                        return false;1350                    }1351 + 01352                var originEndpoint = new IPEndPoint(IPAddress.Any, 0); + 01353                requestSocket.Bind(originEndpoint);13541355                try + 01356                { + 01357                    requestSocket.SendTo(NameRequest, remoteEndpoint); + 01358                    var receivedByteCount = requestSocket.ReceiveFrom(receiveBuffer, ref remoteEndpoint); + 01359                    if (receivedByteCount >= 90) + 01360                    { + 01361                        netbios = new ASCIIEncoding().GetString(receiveBuffer, 57, 16).Trim('\0', ' '); + 01362                        return true;1363                    }1364 + 01365                    netbios = null; + 01366                    return false;1367                } + 01368                catch (SocketException) + 01369                { + 01370                    netbios = null; + 01371                    return false;1372                }1373            }1374            finally + 01375            {1376                //Make sure we close the socket if its open + 01377                requestSocket.Close(); + 01378            } + 01379        }13801381        /// <summary>1382        ///     Calls the NetWkstaGetInfo API on a hostname1383        /// </summary>1384        /// <param name="hostname"></param>1385        /// <returns></returns>1386        private async Task<NetAPIStructs.WorkstationInfo100?> GetWorkstationInfo(string hostname) + 01387        { + 01388            if (!await _portScanner.CheckPort(hostname)) + 01389                return null;1390 + 01391            var result = NetAPIMethods.NetWkstaGetInfo(hostname); + 01392            if (result.IsSuccess) return result.Value;1393 + 01394            return null; + 01395        }13961397        /// <summary>1398        ///     Creates a SearchRequest object for use in querying LDAP.1399        /// </summary>1400        /// <param name="filter">LDAP filter</param>1401        /// <param name="scope">SearchScope to query</param>1402        /// <param name="attributes">LDAP properties to fetch for each object</param>1403        /// <param name="domainName">Domain to query</param>1404        /// <param name="adsPath">ADS path to limit the query too</param>1405        /// <param name="showDeleted">Include deleted objects in results</param>1406        /// <returns>A built SearchRequest</returns>1407        private SearchRequest CreateSearchRequest(string filter, SearchScope scope, string[] attributes,1408            string domainName = null, string adsPath = null, bool showDeleted = false) + 01409        { + 01410            var domain = GetDomain(domainName)?.Name ?? domainName;1411 + 01412            if (domain == null) + 01413                throw new LDAPQueryException( + 01414                    $"Unable to create search request: GetDomain call failed for {domainName}");  14151416        /// <summary>1417        ///     Creates a SearchRequest object for use in querying LDAP.1418        /// </summary>1419        /// <param name="filter">LDAP filter</param>1420        /// <param name="scope">SearchScope to query</param>1421        /// <param name="attributes">LDAP properties to fetch for each object</param>1422        /// <param name="domainName">Domain to query</param>1423        /// <param name="adsPath">ADS path to limit the query too</param>1424        /// <param name="showDeleted">Include deleted objects in results</param>1425        /// <returns>A built SearchRequest</returns>1426        private SearchRequest CreateSearchRequest(string filter, SearchScope scope, string[] attributes,1427            string domainName = null, string adsPath = null, bool showDeleted = false) - 01428        { - 01429            var domain = GetDomain(domainName)?.Name ?? domainName;1430 - 01431            if (domain == null) - 01432                throw new LDAPQueryException($"Unable to create search request: GetDomain call failed for {domainName}")1433 - 01434            var adPath = adsPath?.Replace("LDAP://", "") ?? $"DC={domain.Replace(".", ",DC=")}";1435 - 01436            var request = new SearchRequest(adPath, filter, scope, attributes); - 01437            request.Controls.Add(new SearchOptionsControl(SearchOption.DomainScope)); - 01438            if (showDeleted) - 01439                request.Controls.Add(new ShowDeletedControl());1440 - 01441            return request; - 01442        }14431444        /// <summary>1445        ///     Creates a LDAP connection to a global catalog server1446        /// </summary>1447        /// <param name="domainName">Domain to connect too</param>1448        /// <param name="authType">Auth type to use. Defaults to Kerberos. Use Negotiate for netonly scenarios</param>1449        /// <returns>A connected LdapConnection or null</returns>1450        private async Task<LdapConnection> CreateGlobalCatalogConnection(string domainName = null,1451            AuthType authType = AuthType.Kerberos) - 11452        {1453            string targetServer; - 11454            if (_ldapConfig.Server != null) - 01455            { - 01456                targetServer = _ldapConfig.Server; - 01457            }1458            else - 11459            { - 11460                var domain = GetDomain(domainName); - 11461                if (domain == null) - 11462                { - 11463                    _log.LogDebug("Unable to create global catalog connection for domain {DomainName}: GetDomain failed" - 11464                    throw new LDAPQueryException($"GetDomain call failed for {domainName}");1465                }1466 - 01467                if (!_domainControllerCache.TryGetValue(domain.Name, out targetServer)) - 01468                    targetServer = await GetUsableDomainController(domain); + 01416            var adPath = adsPath?.Replace("LDAP://", "") ?? $"DC={domain.Replace(".", ",DC=")}";1417 + 01418            var request = new SearchRequest(adPath, filter, scope, attributes); + 01419            request.Controls.Add(new SearchOptionsControl(SearchOption.DomainScope)); + 01420            if (showDeleted) + 01421                request.Controls.Add(new ShowDeletedControl());1422 + 01423            return request; + 01424        }14251426        /// <summary>1427        ///     Creates a LDAP connection to a global catalog server1428        /// </summary>1429        /// <param name="domainName">Domain to connect too</param>1430        /// <param name="authType">Auth type to use. Defaults to Kerberos. Use Negotiate for netonly scenarios</param>1431        /// <returns>A connected LdapConnection or null</returns>1432        private async Task<LdapConnection> CreateGlobalCatalogConnection(string domainName = null,1433            AuthType authType = AuthType.Kerberos) + 11434        {1435            string targetServer; + 11436            if (_ldapConfig.Server != null) + 01437            { + 01438                targetServer = _ldapConfig.Server; + 01439            }1440            else + 11441            { + 11442                var domain = GetDomain(domainName); + 11443                if (domain == null) + 11444                { + 11445                    _log.LogDebug( + 11446                        "Unable to create global catalog connection for domain {DomainName}: GetDomain failed", + 11447                        domainName); + 11448                    throw new LDAPQueryException($"GetDomain call failed for {domainName}");1449                }1450 + 01451                if (!_domainControllerCache.TryGetValue(domain.Name, out targetServer)) + 01452                    targetServer = await GetUsableDomainController(domain); + 01453            }1454 + 01455            if (targetServer == null) + 01456                throw new LDAPQueryException($"No usable global catalog found for {domainName}");1457 + 01458            if (_globalCatalogConnections.TryGetValue(targetServer, out var connection)) + 01459                return connection;1460 + 01461            connection = new LdapConnection(new LdapDirectoryIdentifier(targetServer, 3268));1462 + 01463            connection.SessionOptions.ProtocolVersion = 3;1464 + 01465            if (_ldapConfig.Username != null) + 01466            { + 01467                var cred = new NetworkCredential(_ldapConfig.Username, _ldapConfig.Password); + 01468                connection.Credential = cred;  01469            }  1470 - 01471            if (targetServer == null) - 01472                throw new LDAPQueryException($"No usable global catalog found for {domainName}");1473 - 01474            if (_globalCatalogConnections.TryGetValue(targetServer, out var connection)) - 01475                return connection; + 01471            if (_ldapConfig.DisableSigning) + 01472            { + 01473                connection.SessionOptions.Sealing = false; + 01474                connection.SessionOptions.Signing = false; + 01475            }  1476 - 01477            connection = new LdapConnection(new LdapDirectoryIdentifier(targetServer, 3268)); + 01477            connection.AuthType = authType;  1478 - 01479            connection.SessionOptions.ProtocolVersion = 3;1480 - 01481            if (_ldapConfig.Username != null) - 01482            { - 01483                var cred = new NetworkCredential(_ldapConfig.Username, _ldapConfig.Password); - 01484                connection.Credential = cred; - 01485            }1486 - 01487            if (_ldapConfig.DisableSigning) - 01488            { - 01489                connection.SessionOptions.Sealing = false; - 01490                connection.SessionOptions.Signing = false; - 01491            }1492 - 01493            connection.AuthType = authType;1494 - 01495            _globalCatalogConnections.TryAdd(targetServer, connection); - 01496            return connection; - 01497        }14981499        /// <summary>1500        ///     Creates an LDAP connection with appropriate options based off the ldap configuration. Caches connections1501        /// </summary>1502        /// <param name="domainName">The domain to connect too</param>1503        /// <param name="skipCache">Skip the connection cache</param>1504        /// <param name="authType">Auth type to use. Defaults to Kerberos. Use Negotiate for netonly scenarios</param>1505        /// <returns>A connected LDAP connection or null</returns>1506        private async Task<LdapConnection> CreateLDAPConnection(string domainName = null, bool skipCache = false,1507            AuthType authType = AuthType.Kerberos) - 41508        {1509            string targetServer; - 41510            if (_ldapConfig.Server != null) - 01511                targetServer = _ldapConfig.Server;1512            else - 41513            { - 41514                var domain = GetDomain(domainName); - 41515                if (domain == null) - 41516                { - 41517                    _log.LogDebug("Unable to create ldap connection for domain {DomainName}: GetDomain failed", domainNa - 41518                    throw new LDAPQueryException($"Error creating LDAP connection: GetDomain call failed for {domainName1519                }1520 - 01521                if (!_domainControllerCache.TryGetValue(domain.Name, out targetServer)) - 01522                    targetServer = await GetUsableDomainController(domain); - 01523            }1524 - 01525            if (targetServer == null) - 01526                throw new LDAPQueryException($"No usable domain controller found for {domainName}");1527 - 01528            if (!skipCache) - 01529                if (_ldapConnections.TryGetValue(targetServer, out var conn)) - 01530                    return conn;1531 - 01532            var port = _ldapConfig.GetPort(); - 01533            var ident = new LdapDirectoryIdentifier(targetServer, port, false, false); - 01534            var connection = new LdapConnection(ident) { Timeout = new TimeSpan(0, 0, 5, 0) }; - 01535            if (_ldapConfig.Username != null) - 01536            { - 01537                var cred = new NetworkCredential(_ldapConfig.Username, _ldapConfig.Password); - 01538                connection.Credential = cred; - 01539            }15401541            //These options are important! - 01542            connection.SessionOptions.ProtocolVersion = 3; - 01543            connection.SessionOptions.ReferralChasing = ReferralChasingOptions.None; + 01479            _globalCatalogConnections.TryAdd(targetServer, connection); + 01480            return connection; + 01481        }14821483        /// <summary>1484        ///     Creates an LDAP connection with appropriate options based off the ldap configuration. Caches connections1485        /// </summary>1486        /// <param name="domainName">The domain to connect too</param>1487        /// <param name="skipCache">Skip the connection cache</param>1488        /// <param name="authType">Auth type to use. Defaults to Kerberos. Use Negotiate for netonly scenarios</param>1489        /// <returns>A connected LDAP connection or null</returns>1490        private async Task<LdapConnection> CreateLDAPConnection(string domainName = null, bool skipCache = false,1491            AuthType authType = AuthType.Kerberos) + 41492        {1493            string targetServer; + 41494            if (_ldapConfig.Server != null) + 01495                targetServer = _ldapConfig.Server;1496            else + 41497            { + 41498                var domain = GetDomain(domainName); + 41499                if (domain == null) + 41500                { + 41501                    _log.LogDebug("Unable to create ldap connection for domain {DomainName}: GetDomain failed", + 41502                        domainName); + 41503                    throw new LDAPQueryException( + 41504                        $"Error creating LDAP connection: GetDomain call failed for {domainName}");1505                }1506 + 01507                if (!_domainControllerCache.TryGetValue(domain.Name, out targetServer)) + 01508                    targetServer = await GetUsableDomainController(domain); + 01509            }1510 + 01511            if (targetServer == null) + 01512                throw new LDAPQueryException($"No usable domain controller found for {domainName}");1513 + 01514            if (!skipCache) + 01515                if (_ldapConnections.TryGetValue(targetServer, out var conn)) + 01516                    return conn;1517 + 01518            var port = _ldapConfig.GetPort(); + 01519            var ident = new LdapDirectoryIdentifier(targetServer, port, false, false); + 01520            var connection = new LdapConnection(ident) { Timeout = new TimeSpan(0, 0, 5, 0) }; + 01521            if (_ldapConfig.Username != null) + 01522            { + 01523                var cred = new NetworkCredential(_ldapConfig.Username, _ldapConfig.Password); + 01524                connection.Credential = cred; + 01525            }15261527            //These options are important! + 01528            connection.SessionOptions.ProtocolVersion = 3; + 01529            connection.SessionOptions.ReferralChasing = ReferralChasingOptions.None;1530 + 01531            if (_ldapConfig.DisableSigning) + 01532            { + 01533                connection.SessionOptions.Sealing = false; + 01534                connection.SessionOptions.Signing = false; + 01535            }1536 + 01537            if (_ldapConfig.SSL) + 01538                connection.SessionOptions.SecureSocketLayer = true;1539 + 01540            if (_ldapConfig.DisableCertVerification) + 01541                connection.SessionOptions.VerifyServerCertificate = (ldapConnection, certificate) => true;1542 + 01543            connection.AuthType = authType;  1544 - 01545            if (_ldapConfig.DisableSigning) + 01545            _ldapConnections.AddOrUpdate(targetServer, connection, (s, ldapConnection) =>  01546            { - 01547                connection.SessionOptions.Sealing = false; - 01548                connection.SessionOptions.Signing = false; - 01549            } + 01547                ldapConnection.Dispose(); + 01548                return connection; + 01549            });  1550 - 01551            if (_ldapConfig.SSL) - 01552                connection.SessionOptions.SecureSocketLayer = true; + 01551            return connection; + 01552        }  1553 - 01554            if (_ldapConfig.DisableCertVerification) - 01555                connection.SessionOptions.VerifyServerCertificate = (ldapConnection, certificate) => true;1556 - 01557            connection.AuthType = authType;1554        private async Task<string> GetUsableDomainController(Domain domain, bool gc = false) + 01555        { + 01556            if (!gc && _domainControllerCache.TryGetValue(domain.Name.ToUpper(), out var dc)) + 01557                return dc;  1558 - 01559            if (!skipCache) - 01560                _ldapConnections.TryAdd(targetServer, connection);1561 - 01562            return connection; - 01563        }15641565        private async Task<string> GetUsableDomainController(Domain domain, bool gc = false) - 01566        { - 01567            if (!gc && _domainControllerCache.TryGetValue(domain.Name.ToUpper(), out var dc)) - 01568                return dc;1569 - 01570            var port = gc ? 3268 : _ldapConfig.GetPort(); - 01571            var pdc = domain.PdcRoleOwner.Name; - 01572            if (await _portScanner.CheckPort(pdc, port)) - 01573            { - 01574                _domainControllerCache.TryAdd(domain.Name.ToUpper(), pdc); - 01575                _log.LogInformation("Found usable Domain Controller for {Domain} : {PDC}", domain.Name, pdc); - 01576                return pdc;1577            }15781579            //If the PDC isn't reachable loop through the rest - 01580            foreach (DomainController domainController in domain.DomainControllers) - 01581            { - 01582                var name = domainController.Name; - 01583                if (!await _portScanner.CheckPort(name, port)) continue; - 01584                _log.LogInformation("Found usable Domain Controller for {Domain} : {PDC}", domain.Name, name); - 01585                _domainControllerCache.TryAdd(domain.Name.ToUpper(), name); - 01586                return name;1587            }15881589            //If we get here, somehow we didn't get any usable DCs. Save it off as null - 01590            _domainControllerCache.TryAdd(domain.Name.ToUpper(), null); - 01591            _log.LogWarning("Unable to find usable domain controller for {Domain}", domain.Name); - 01592            return null; - 01593        }15941595        /// <summary>1596        ///     Normalizes a domain name to its full DNS name1597        /// </summary>1598        /// <param name="domain"></param>1599        /// <returns></returns>1600        internal string NormalizeDomainName(string domain) - 01601        { - 01602            if (domain == null) - 01603                return null;1604 - 01605            var resolved = domain;1606 - 01607            if (resolved.Contains(".")) - 01608                return domain.ToUpper();1609 - 01610            resolved = ResolveDomainNetbiosToDns(domain) ?? domain;1611 - 01612            return resolved.ToUpper(); - 01613        } + 01559            var port = gc ? 3268 : _ldapConfig.GetPort(); + 01560            var pdc = domain.PdcRoleOwner.Name; + 01561            if (await _portScanner.CheckPort(pdc, port)) + 01562            { + 01563                _domainControllerCache.TryAdd(domain.Name.ToUpper(), pdc); + 01564                _log.LogInformation("Found usable Domain Controller for {Domain} : {PDC}", domain.Name, pdc); + 01565                return pdc;1566            }15671568            //If the PDC isn't reachable loop through the rest + 01569            foreach (DomainController domainController in domain.DomainControllers) + 01570            { + 01571                var name = domainController.Name; + 01572                if (!await _portScanner.CheckPort(name, port)) continue; + 01573                _log.LogInformation("Found usable Domain Controller for {Domain} : {PDC}", domain.Name, name); + 01574                _domainControllerCache.TryAdd(domain.Name.ToUpper(), name); + 01575                return name;1576            }15771578            //If we get here, somehow we didn't get any usable DCs. Save it off as null + 01579            _domainControllerCache.TryAdd(domain.Name.ToUpper(), null); + 01580            _log.LogWarning("Unable to find usable domain controller for {Domain}", domain.Name); + 01581            return null; + 01582        }15831584        /// <summary>1585        ///     Normalizes a domain name to its full DNS name1586        /// </summary>1587        /// <param name="domain"></param>1588        /// <returns></returns>1589        internal string NormalizeDomainName(string domain) + 01590        { + 01591            if (domain == null) + 01592                return null;1593 + 01594            var resolved = domain;1595 + 01596            if (resolved.Contains(".")) + 01597                return domain.ToUpper();1598 + 01599            resolved = ResolveDomainNetbiosToDns(domain) ?? domain;1600 + 01601            return resolved.ToUpper(); + 01602        }16031604        /// <summary>1605        ///     Turns a domain Netbios name into its FQDN using the DsGetDcName function (TESTLAB -> TESTLAB.LOCAL)1606        /// </summary>1607        /// <param name="domainName"></param>1608        /// <returns></returns>1609        internal string ResolveDomainNetbiosToDns(string domainName) + 01610        { + 01611            var key = domainName.ToUpper(); + 01612            if (_netbiosCache.TryGetValue(key, out var flatName)) + 01613                return flatName;  16141615        /// <summary>1616        ///     Turns a domain Netbios name into its FQDN using the DsGetDcName function (TESTLAB -> TESTLAB.LOCAL)1617        /// </summary>1618        /// <param name="domainName"></param>1619        /// <returns></returns>1620        internal string ResolveDomainNetbiosToDns(string domainName) - 01621        { - 01622            var key = domainName.ToUpper(); - 01623            if (_netbiosCache.TryGetValue(key, out var flatName)) - 01624                return flatName;1625 - 01626            var domain = GetDomain(domainName); - 01627            if (domain != null) - 01628            { - 01629                _netbiosCache.TryAdd(key, domain.Name); - 01630                return domain.Name;1631            }1632 - 01633            var computerName = _ldapConfig.Server; + 01615            var domain = GetDomain(domainName); + 01616            if (domain != null) + 01617            { + 01618                _netbiosCache.TryAdd(key, domain.Name); + 01619                return domain.Name;1620            }1621 + 01622            var computerName = _ldapConfig.Server;1623 + 01624            var dci = _nativeMethods.CallDsGetDcName(computerName, domainName); + 01625            if (dci.IsSuccess) + 01626            { + 01627                flatName = dci.Value.DomainName; + 01628                _netbiosCache.TryAdd(key, flatName); + 01629                return flatName;1630            }1631 + 01632            return domainName.ToUpper(); + 01633        }  1634 - 01635            var dci = _nativeMethods.CallDsGetDcName(computerName, domainName); - 01636            if (dci.IsSuccess) - 01637            { - 01638                flatName = dci.Value.DomainName; - 01639                _netbiosCache.TryAdd(key, flatName); - 01640                return flatName;1641            }1642 - 01643            return domainName.ToUpper(); - 01644        }16451646        /// <summary>1647        /// Gets the range retrieval limit for a domain1648        /// </summary>1649        /// <param name="domainName"></param>1650        /// <param name="defaultRangeSize"></param>1651        /// <returns></returns>1652        public int GetDomainRangeSize(string domainName = null, int defaultRangeSize = 750) - 41653        { - 41654            var domainPath = DomainNameToDistinguishedName(domainName);1655            //Default to a page size of 750 for safety - 41656            if (domainPath == null) - 21657            { - 21658                _log.LogDebug("Unable to resolve domain {Domain} to distinguishedname to get page size", domainName ?? " - 21659                return defaultRangeSize;1660            }1661 - 21662            if (_ldapRangeSizeCache.TryGetValue(domainPath.ToUpper(), out var parsedPageSize)) - 01663            { - 01664                return parsedPageSize;1665            }1666 - 21667            var configPath = CommonPaths.CreateDNPath(CommonPaths.QueryPolicyPath, domainPath); - 21668            var enumerable = QueryLDAP("(objectclass=*)", SearchScope.Base, null, adsPath: configPath); - 21669            var config = enumerable.DefaultIfEmpty(null).FirstOrDefault(); - 31670            var pageSize = config?.GetArrayProperty(LDAPProperties.LdapAdminLimits).FirstOrDefault(x => x.StartsWith("Ma - 21671            if (pageSize == null) - 11672            { - 11673                _log.LogDebug("No LDAPAdminLimits object found for {Domain}", domainName); - 11674                _ldapRangeSizeCache.TryAdd(domainPath.ToUpper(), defaultRangeSize); - 11675                return defaultRangeSize;1676            }1677 - 11678            if (int.TryParse(pageSize.Split('=').Last(), out parsedPageSize)) - 11679            { - 11680                _ldapRangeSizeCache.TryAdd(domainPath.ToUpper(), parsedPageSize); - 11681                _log.LogInformation("Found page size {PageSize} for {Domain}", parsedPageSize, domainName ?? "current do - 11682                return parsedPageSize;1683            }1684 - 01685            _log.LogDebug("Failed to parse pagesize for {Domain}, returning default", domainName ?? "current domain");1686 - 01687            _ldapRangeSizeCache.TryAdd(domainPath.ToUpper(), defaultRangeSize); - 01688            return defaultRangeSize; - 41689        }16901691        private string DomainNameToDistinguishedName(string domain) - 41692        { - 41693            var resolvedDomain = GetDomain(domain)?.Name ?? domain; - 41694            return resolvedDomain == null ? null : $"DC={resolvedDomain.Replace(".", ",DC=")}"; - 41695        }16961697        private class ResolvedWellKnownPrincipal1698        { - 31699            public string DomainName { get; set; } - 31700            public string WkpId { get; set; }1701        }17021703        public string GetConfigurationPath(string domainName = null) - 01704        { - 01705            string path = domainName == null - 01706                ? "LDAP://RootDSE" - 01707                : $"LDAP://{NormalizeDomainName(domainName)}/RootDSE";17081709            DirectoryEntry rootDse; - 01710            if (_ldapConfig.Username != null) - 01711                rootDse = new DirectoryEntry(path, _ldapConfig.Username, _ldapConfig.Password);1712            else - 01713                rootDse = new DirectoryEntry(path);1714 - 01715            return $"{rootDse.Properties["configurationNamingContext"]?[0]}"; - 01716        }17171718        public string GetSchemaPath(string domainName) - 01719        { - 01720            string path = domainName == null - 01721                ? "LDAP://RootDSE" - 01722                : $"LDAP://{NormalizeDomainName(domainName)}/RootDSE";17231724            DirectoryEntry rootDse; - 01725            if (_ldapConfig.Username != null) - 01726                rootDse = new DirectoryEntry(path, _ldapConfig.Username, _ldapConfig.Password);1727            else - 01728                rootDse = new DirectoryEntry(path);1729 - 01730            return $"{rootDse.Properties["schemaNamingContext"]?[0]}"; - 01731        }17321733        public bool IsDomainController(string computerObjectId, string domainName) - 01734        { - 01735            var filter = new LDAPFilter().AddFilter(LDAPProperties.ObjectSID + "=" + computerObjectId, true).AddFilter(C - 01736            var res = QueryLDAP(filter.GetFilter(), SearchScope.Subtree, - 01737                         CommonProperties.ObjectID, domainName: domainName); - 01738            if (res.Count() > 0) - 01739                return true; - 01740            return false; - 01741        }1742    }1743}1635        /// <summary>1636        /// Gets the range retrieval limit for a domain1637        /// </summary>1638        /// <param name="domainName"></param>1639        /// <param name="defaultRangeSize"></param>1640        /// <returns></returns>1641        public int GetDomainRangeSize(string domainName = null, int defaultRangeSize = 750) + 41642        { + 41643            var domainPath = DomainNameToDistinguishedName(domainName);1644            //Default to a page size of 750 for safety + 41645            if (domainPath == null) + 21646            { + 21647                _log.LogDebug("Unable to resolve domain {Domain} to distinguishedname to get page size", + 21648                    domainName ?? "current domain"); + 21649                return defaultRangeSize;1650            }1651 + 21652            if (_ldapRangeSizeCache.TryGetValue(domainPath.ToUpper(), out var parsedPageSize)) + 01653            { + 01654                return parsedPageSize;1655            }1656 + 21657            var configPath = CommonPaths.CreateDNPath(CommonPaths.QueryPolicyPath, domainPath); + 21658            var enumerable = QueryLDAP("(objectclass=*)", SearchScope.Base, null, adsPath: configPath); + 21659            var config = enumerable.DefaultIfEmpty(null).FirstOrDefault(); + 21660            var pageSize = config?.GetArrayProperty(LDAPProperties.LdapAdminLimits) + 31661                .FirstOrDefault(x => x.StartsWith("MaxPageSize", StringComparison.OrdinalIgnoreCase)); + 21662            if (pageSize == null) + 11663            { + 11664                _log.LogDebug("No LDAPAdminLimits object found for {Domain}", domainName); + 11665                _ldapRangeSizeCache.TryAdd(domainPath.ToUpper(), defaultRangeSize); + 11666                return defaultRangeSize;1667            }1668 + 11669            if (int.TryParse(pageSize.Split('=').Last(), out parsedPageSize)) + 11670            { + 11671                _ldapRangeSizeCache.TryAdd(domainPath.ToUpper(), parsedPageSize); + 11672                _log.LogInformation("Found page size {PageSize} for {Domain}", parsedPageSize, + 11673                    domainName ?? "current domain"); + 11674                return parsedPageSize;1675            }1676 + 01677            _log.LogDebug("Failed to parse pagesize for {Domain}, returning default", domainName ?? "current domain");1678 + 01679            _ldapRangeSizeCache.TryAdd(domainPath.ToUpper(), defaultRangeSize); + 01680            return defaultRangeSize; + 41681        }16821683        private string DomainNameToDistinguishedName(string domain) + 41684        { + 41685            var resolvedDomain = GetDomain(domain)?.Name ?? domain; + 41686            return resolvedDomain == null ? null : $"DC={resolvedDomain.Replace(".", ",DC=")}"; + 41687        }16881689        private class ResolvedWellKnownPrincipal1690        { + 31691            public string DomainName { get; set; } + 31692            public string WkpId { get; set; }1693        }16941695        public string GetConfigurationPath(string domainName = null) + 01696        { + 01697            string path = domainName == null + 01698                ? "LDAP://RootDSE" + 01699                : $"LDAP://{NormalizeDomainName(domainName)}/RootDSE";17001701            DirectoryEntry rootDse; + 01702            if (_ldapConfig.Username != null) + 01703                rootDse = new DirectoryEntry(path, _ldapConfig.Username, _ldapConfig.Password);1704            else + 01705                rootDse = new DirectoryEntry(path);1706 + 01707            return $"{rootDse.Properties["configurationNamingContext"]?[0]}"; + 01708        }17091710        public string GetSchemaPath(string domainName) + 01711        { + 01712            string path = domainName == null + 01713                ? "LDAP://RootDSE" + 01714                : $"LDAP://{NormalizeDomainName(domainName)}/RootDSE";17151716            DirectoryEntry rootDse; + 01717            if (_ldapConfig.Username != null) + 01718                rootDse = new DirectoryEntry(path, _ldapConfig.Username, _ldapConfig.Password);1719            else + 01720                rootDse = new DirectoryEntry(path);1721 + 01722            return $"{rootDse.Properties["schemaNamingContext"]?[0]}"; + 01723        }17241725        public bool IsDomainController(string computerObjectId, string domainName) + 01726        { + 01727            var filter = new LDAPFilter().AddFilter(LDAPProperties.ObjectSID + "=" + computerObjectId, true) + 01728                .AddFilter(CommonFilters.DomainControllers, true); + 01729            var res = QueryLDAP(filter.GetFilter(), SearchScope.Subtree, + 01730                CommonProperties.ObjectID, domainName: domainName); + 01731            if (res.Count() > 0) + 01732                return true; + 01733            return false; + 01734        }1735    }1736} -

+

Methods/Properties

-.cctor()
-.ctor()
-.ctor(SharpHoundCommonLib.NativeMethods,SharpHoundCommonLib.Processors.PortScanner,Microsoft.Extensions.Logging.ILogger)
-SetLDAPConfig(SharpHoundCommonLib.LDAPConfig)
-GetWellKnownPrincipal(System.String,System.String,SharpHoundCommonLib.OutputTypes.TypedPrincipal&)
-AddDomainController(System.String)
-GetWellKnownPrincipalOutput()
-ConvertWellKnownPrincipal(System.String,System.String)
-GetUserGlobalCatalogMatches(System.String)
-ResolveIDAndType(System.String,System.String)
-ResolveCertTemplateByProperty(System.String,System.String,System.String,System.String)
-LookupSidType(System.String,System.String)
-LookupGuidType(System.String,System.String)
-GetDomainNameFromSid(System.String)
-GetSidFromDomainName(System.String)
-DoRangedRetrieval()
-ResolveHostToSid()
-ResolveAccountName(System.String,System.String)
-ResolveDistinguishedName(System.String)
-QueryLDAP(SharpHoundCommonLib.LDAPQueryOptions)
-QueryLDAP()
-CreateNewConnection(System.String,System.Boolean,System.Boolean)
-QueryLDAP()
-GetForest(System.String)
-MakeSecurityDescriptor()
-BuildLdapPath(System.String,System.String)
-TestLDAPConfig(System.String)
-GetDomain(System.String)
-SetupLDAPQueryFilter(System.String,System.DirectoryServices.Protocols.SearchScope,System.String[],System.Boolean,System.String,System.Boolean,System.String,System.Boolean,System.Boolean)
-GetBaseEnterpriseDC(System.String)
-UpdateLDAPConfig(SharpHoundCommonLib.LDAPConfig)
-GetDomainNameFromSidLdap(System.String)
-RequestNETBIOSNameFromComputer(System.String,System.String,System.String&)
-GetWorkstationInfo()
-CreateSearchRequest(System.String,System.DirectoryServices.Protocols.SearchScope,System.String[],System.String,System.String,System.Boolean)
-CreateGlobalCatalogConnection()
-CreateLDAPConnection()
-GetUsableDomainController()
-NormalizeDomainName(System.String)
-ResolveDomainNetbiosToDns(System.String)
-GetDomainRangeSize(System.String,System.Int32)
-DomainNameToDistinguishedName(System.String)
-DomainName()
-WkpId()
-GetConfigurationPath(System.String)
-GetSchemaPath(System.String)
-IsDomainController(System.String,System.String)
+.cctor()
+.ctor()
+.ctor(SharpHoundCommonLib.NativeMethods,SharpHoundCommonLib.Processors.PortScanner,Microsoft.Extensions.Logging.ILogger)
+SetLDAPConfig(SharpHoundCommonLib.LDAPConfig)
+GetWellKnownPrincipal(System.String,System.String,SharpHoundCommonLib.OutputTypes.TypedPrincipal&)
+AddDomainController(System.String)
+GetWellKnownPrincipalOutput()
+ConvertWellKnownPrincipal(System.String,System.String)
+GetUserGlobalCatalogMatches(System.String)
+ResolveIDAndType(System.String,System.String)
+ResolveCertTemplateByProperty(System.String,System.String,System.String,System.String)
+LookupSidType(System.String,System.String)
+LookupGuidType(System.String,System.String)
+GetDomainNameFromSid(System.String)
+GetSidFromDomainName(System.String)
+DoRangedRetrieval()
+ResolveHostToSid()
+ResolveAccountName(System.String,System.String)
+ResolveDistinguishedName(System.String)
+QueryLDAP(SharpHoundCommonLib.LDAPQueryOptions)
+QueryLDAP()
+CreateNewConnection(System.String,System.Boolean,System.Boolean)
+QueryLDAP(System.String,System.DirectoryServices.Protocols.SearchScope,System.String[],System.String,System.Boolean,System.Boolean,System.String,System.Boolean,System.Boolean,System.Boolean)
+GetNextBackoff(System.Int32)
+GetForest(System.String)
+MakeSecurityDescriptor()
+BuildLdapPath(System.String,System.String)
+TestLDAPConfig(System.String)
+GetDomain(System.String)
+SetupLDAPQueryFilter(System.String,System.DirectoryServices.Protocols.SearchScope,System.String[],System.Boolean,System.String,System.Boolean,System.String,System.Boolean,System.Boolean)
+GetBaseEnterpriseDC(System.String)
+UpdateLDAPConfig(SharpHoundCommonLib.LDAPConfig)
+GetDomainNameFromSidLdap(System.String)
+RequestNETBIOSNameFromComputer(System.String,System.String,System.String&)
+GetWorkstationInfo()
+CreateSearchRequest(System.String,System.DirectoryServices.Protocols.SearchScope,System.String[],System.String,System.String,System.Boolean)
+CreateGlobalCatalogConnection()
+CreateLDAPConnection()
+GetUsableDomainController()
+NormalizeDomainName(System.String)
+ResolveDomainNetbiosToDns(System.String)
+GetDomainRangeSize(System.String,System.Int32)
+DomainNameToDistinguishedName(System.String)
+DomainName()
+WkpId()
+GetConfigurationPath(System.String)
+GetSchemaPath(System.String)
+IsDomainController(System.String,System.String)