Skip to content

Latest commit

 

History

24 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 

Repository files navigation

AdminSDHolder / SDProp: Cleanup-AdminCount

A language independent(!) Powershell Script to remove orphaned AdminCount=1 on User objects in Active Directory and enable ACL inheritance from parent OU. Repair/Cleanup User Accounts, protected by sdprop/AdminSDHolder process in Active Directory, that are no longer Member of one of the Protected Groups.

The Script doesn´t work initialliy with the displayname of the the group. The problem is, that´s a localized name and there is more than english.

The script uses the best common denominator: The Well-Known SID. Simple as that. The report of group membership is the localized version of the group.

Groups protected by sdprop (AdminSDHolder) process.

  • Account Operators
  • Administrator
  • Administrators
  • Backup Operators
  • Domain Admins
  • Domain Controllers
  • Enterprise Admins
  • Enterprise Key Admins
  • Key Admins
  • Krbtgt
  • Print Operators
  • Read-only Domain Controllers
  • Replicator
  • Schema Admins
  • Server Operators

Call Script in "Report Only" mode:

.\Cleanup-AdminCount.ps1

Call Script in "Clean Up and repair" mode:

.\Cleanup-AdminCount.ps1 -cleanup

Running Script - Both modi: grafik

Background / Information / Microsoft Ressources

Appendix C: Protected Accounts and Groups in Active Directory

2.4.2.4 Well-Known SID Structures

4.1.2.2 SID Filtering and Claims Transformation

About

A language independent(!) Powershell Script to remove orphaned AdminCounts on User objects in AD and enable ACL inheritance. Repair User Accounts, protected by sdprop/AdminSDHolder process in Active Directory, that are no longer Member of Protected Groups

Resources

Stars

17 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages