TestimoX

API Reference

Class

EmptyGroupFinder

Namespace ADPlayground.Groups
Assembly ADPlayground
Modifiers static

Provides methods for locating Active Directory groups based on member count and type while ignoring built-in and well-known administrative groups.

Inheritance

  • Object
  • EmptyGroupFinder

Methods

public static IEnumerable<String> FilterGroups(IEnumerable<ValueTuple<String, Int32, Int32, GroupType>> groups, GroupType groupType, Int32 minMemberCount = 0, Nullable<Int32> maxMemberCount = null) #
Returns: IEnumerable<String>

Filters provided group data to those that match member count thresholds and group type.

Parameters

groups System.Collections.Generic.IEnumerable{System.ValueTuple{System.String,System.Int32,System.Int32,ADPlayground.GroupType}} requiredposition: 0
Tuple of distinguished name, RID, member count and group type.
groupType ADPlayground.GroupType requiredposition: 1
Group type to filter for.
minMemberCount System.Int32 = 0 optionalposition: 2
Minimum member count threshold.
maxMemberCount System.Nullable{System.Int32} = null optionalposition: 3
Maximum member count threshold or null for no maximum.

Returns

Collection of group distinguished names.

GetEmptySecurityGroups 2 overloads
public static IEnumerable<String> GetEmptySecurityGroups(String domainName) #
Returns: IEnumerable<String>

Enumerates security groups in the specified domain that have zero members.

Parameters

domainName System.String requiredposition: 0
Target domain name.

Returns

Collection of group distinguished names.

public static IEnumerable<String> GetEmptySecurityGroups() #
Returns: IEnumerable<String>

Enumerates all domains in the current forest and returns empty security groups.

Returns

Collection of group distinguished names.

GetGroupsByMemberCount 2 overloads
public static IEnumerable<String> GetGroupsByMemberCount(String domainName, GroupType groupType, Int32 minMemberCount = 0, Nullable<Int32> maxMemberCount = null) #
Returns: IEnumerable<String>

Enumerates groups in the specified domain that match member count thresholds and group type.

Parameters

domainName System.String requiredposition: 0
Target domain name.
groupType ADPlayground.GroupType requiredposition: 1
Group type to search for.
minMemberCount System.Int32 = 0 optionalposition: 2
Minimum member count threshold.
maxMemberCount System.Nullable{System.Int32} = null optionalposition: 3
Maximum member count threshold or null for no maximum.

Returns

Collection of group distinguished names.

public static IEnumerable<String> GetGroupsByMemberCount(GroupType groupType, Int32 minMemberCount = 0, Nullable<Int32> maxMemberCount = null) #
Returns: IEnumerable<String>

Enumerates all domains in the current forest and returns groups that match member count thresholds and group type.

Parameters

groupType ADPlayground.GroupType requiredposition: 0
Group type to search for.
minMemberCount System.Int32 = 0 optionalposition: 1
Minimum member count threshold.
maxMemberCount System.Nullable{System.Int32} = null optionalposition: 2
Maximum member count threshold or null for no maximum.

Returns

Collection of group distinguished names.