Skip to content

Lesson 8 of 14 · 15m

OUs Are Scopes, and Groups Are the Plumbing

OUs exist for GPO targeting and delegation ACLs — AdminSDHolder, group scope math, AGDLP, trust direction, and machine account hygiene.

An OU is a scope, not an org chart

An OU exists for exactly two reasons: to target GPOs and to carry a delegation ACL. The org-chart-shaped tree — an OU per department, three levels deep — is decoration that costs you the first time the org renames a department. Design it around what applies policy differently: workstations vs. servers vs. DCs (DCs get their own protected OU with the DC GPO anyway), pilot vs. broad, kiosks vs. desktops.

A distinction that confuses everyone once: CN=Users and CN=Computers are containers, not OUs — you can't link a GPO to them, which is why "redirect new objects" (redirusr / redircmp) exists as a practice instead of "policy the default container."

Delegation is the second job. Right-click → Delegate Control writes ACEs on the OU — reset passwords, manage group membership, create computer objects. This is how helpdesk gets "reset passwords in the Users OU" without landing in Account Operators, which is broader than anyone wants. Inspect what was actually granted with dsacls "OU=Users,DC=contoso,DC=local" — the wizard is friendly, the ACL is the truth.

The trap attached to protected groups: membership in Domain Admins, Account Operators, Administrators and the rest of the protected set puts an object under AdminSDHolder — every ~60 minutes SDProp overwrites the object's ACL with the protected template. Delegate rights on a helpdesk user, promote them to a protected group, and your delegation is silently wiped within the hour. This is exactly why separate -a admin accounts exist: the daily account stays unprotected, the admin account stays protected, and neither inherits the other's ACL.

Group scope math

Three scopes, each with a real constraint:

  • Global — members must be same-domain; the group itself can be used anywhere. This is where users go.
  • Domain Local — grants rights only inside its own domain, but accepts members from anywhere. This is where permissions attach.
  • Universal — any member, used anywhere, stored in the Global Catalog. GC replication means every membership change replicates forest-wide. Nest globals into universals and leave the universal stable; churning it is how you generate replication traffic and broken ACL caches.

AGDLP is the mnemonic and the practice: Accounts go into Globals, Globals into Domain Locals, Domain Locals get the Permission. When a second domain appears, you don't redesign.

SIDs worth recognizing on sight: S-1-5-32-544 is BUILTIN\Administrators, S-1-5-11 is Authenticated Users, S-1-5-18 is SYSTEM. Domain SIDs are the domain SID plus a RID — 500 is the built-in Administrator, 512 is Domain Admins — which is exactly the shorthand attackers grep for after dumping a DC.

Trusts and machine accounts

Inside a forest, parent-child and tree-root trusts are transitive and automatic — Kerberos paths just work. The trusts you create are external and forest trusts, and direction matters: a one-way trust lets the trusted domain's users reach resources in the trusting domain — the arrow points opposite intuition. SID filtering (the quarantine) is on by default so foreign privileged SIDs don't ride in on a trust; SIDHistory abuse is the attack it blocks.

Computers hold credentials too. Machine accounts have passwords that rotate every 30 days, and "the trust relationship between this workstation and the primary domain failed" is an out-of-sync machine password — fix it with Reset-ComputerMachinePassword -Server dc01 -Credential (Get-Credential) or a rejoin, not a reinstall. The usual cause is a reverted snapshot or a months-dead box rejoining the network — same class of problem as USN rollback, smaller blast radius.

And stale computer objects are inventory debt: lastLogonTimestamp (replicated, 9–14-day precision) and pwdLastSet are how you find machines that died six months ago and still hold a place in AD — each one a valid domain credential whose password nobody will ever rotate by logging on.

Keep the tree flat and scope-shaped, delegate through the wizard but verify with dsacls, AGDLP for permissions, and sweep stale machines on a schedule — every one of them is a valid domain credential sitting in a decommissioned closet.

Was this lesson helpful?

Sign in to rate

Keep reading

Related articles from the SudoSecurity blog.