Forest, domain, OU, and container: Separating the organizational structure from the trust boundary
A forest brings domains together; an OU organizes objects inside a domain. First understand the tree, then separate an object’s location from permissions granted to it.
First see forest → domain → OU.
A forest contains one or more domains sharing schema and configuration. A domain stores accounts and replicates its directory data. An OU is a container type organizing user and computer objects within a domain.
In the example below, Tunahan is in the People OU and WS01 in Workstations. OU placement grants no permission. An OU is not a forest security boundary; placement, policy scope and permissions are separate questions.
Once the relationship is clear, explore the inheritance scene. Delegation grants specific identities specific management rights. A DACL is a permission list, an ACE is an entry, and inheritance controls how an entry applies to descendants. Rather than memorize CI/IO and WRITE_DAC on the first pass, follow who receives a right and where it applies.
- Forest · iyelabs.example
- Domain · iyelabs.example
- OU · People
- Tunahan · user account
- OU · Workstations
- WS01 · computer account
- OU · People
- Domain · iyelabs.example
OUs organize objects inside a domain. Their names grant no permissions; the next example separately examines inherited rights.
First explain the basic idea in your own words. Then follow the scene; interface names and evidence details are available below.
1. Core mechanism
Windows components / teknik ayrıntılar
In the AD DS logical model, a forest brings together one or more domains through shared schema, configuration, and global-catalog context. A domain is a directory partition. An OU is an organizationalUnit container within a domain naming context; general containers such as CN=Users can also hold objects. A DN expresses an object’s location in the tree, while nTSecurityDescriptor carries its security-control context.
Interfaces and specifications
- LDAP directory information tree: distinguished name (DN), relative distinguished name (RDN), and domain naming context.
- OU object class: organizationalUnit; schemaIDGUID bf967aa5-0de6-11d0-a285-00a003049e2.
- Object security: owner, DACL, SACL, and ACEs in nTSecurityDescriptor.
- ACE scope: trustee SID, access mask, inheritance flags, and—where applicable—object and inherited-object GUIDs.
- Delegation: granular rights written to an OU or parent-container ACL that can propagate to descendants under inheritance rules.
Four names, three different questions
A forest is the highest-level AD DS scope for domains that share schema and configuration. A domain is both a directory partition and an account and replication management scope.
OU and container objects hold objects in the domain tree. An OU has a specific role in classification, Group Policy scope of management, and delegation design; a general container is not automatically an OU.
The DN shows placement; the trust boundary is different
The DN CN=Tunahan,OU=Muhasebe,DC=iyelabs,DC=example shows the object’s RDN and its path through the hierarchy. It helps define management and search scope.
Moving an object to another OU can change its organizational placement and the policy or ACE context it inherits, but an OU does not create forest-level isolation by itself.
Delegation is an ACL relationship
An OU DACL grants specific rights to specific trustee SIDs. ACE inheritance flags determine whether a right propagates to descendants; object and inherited-object GUIDs can narrow the applicable class or property context.
Effective control is determined by evaluating explicit and inherited ACEs against the target object and requested right. The “OU manager” label does not mean unlimited authorization over the forest or a DC.
The artifact compares broad and narrow scope
The first ACE grants Generic All to the RID 1105 trustee with container inheritance. The second object-specific ACE, for RID 1106, is intended to apply WRITE_DAC only within CI|IO scope to descendant OU objects.
This synthetic SDDL is not a production ACL. The parser only separates tokens; it does not calculate canonical ACE order, effective access, or a Windows round-trip result. These are explicit validation boundaries.
State and data flow
- Within a forest’s shared schema/configuration, the object’s DN locates it in a domain naming context.
- The OU or parent-container DACL grants specific rights to a principal.
- Inheritance flags determine whether the right propagates to descendant objects.
- Object-specific ACE can narrow the right to certain class/attribute coverage.
- Effective control is evaluated from the trustee SID, explicit or inherited ACE, target object, and requested right.
- An OU organizes the administrative layout; it does not create forest-level security isolation.
2. Exploitation
Broken trust assumption
Broken assumption: “A department OU is a security boundary by itself.” An OU defines administrative and policy scope; an overly broad or incorrectly inherited ACE can grant more control over descendant objects than intended.
Technical prerequisites
- An attacker or incorrectly structured group has an effective ACE on the OU or a parent container.
- The ACE rights mask (for example, GA, WD, WP, CC, or DC) covers the required inheritance scope and target object class.
- The target object does not block inheritance, or an explicit DACL does not otherwise neutralize the right.
Exploitation mechanism
A broad or incorrectly inherited ACE can grant the ability to create or delete objects, change attributes, or modify the DACL beneath the OU. The effect is limited by the ACE’s right, trustee, object type, inherited-object type, and inheritance depth. Control of an OU is not control of the forest or a DC, but it can seriously affect identity and computer objects within that OU. Because higher-privileged service administrators can change the OU ACL, an OU is not a forest security boundary.
Do not mistake an organizational boundary for a security boundary
Department names and OU paths provide layout to people; the attack surface determines the actual trustee and scope in the ACL.
A single wide ACE inherited from the upper container can cover a large number of bottom objects.
Read the right together with its scope
WRITE_DAC is not the same as Generic All; object-specific and inherit-only flags change where the effect begins.
Instead of summarizing an ACE as “permission exists,” explain the right, object GUID, inherited-object GUID, trustee SID, and target object together.
3. Defense & Detection
Telemetry scope
- Source host: the domain controller processing the change; channel Security.
- Enable Audit Directory Service Changes for Success.
- For 5136, verify that the relevant write access is covered by the appropriate SACL; the absence of an event cannot prove that auditing or the SACL was correctly configured.
Events and relevant fields
- 5136 Version 0: AD object change.
- Relevant fields: SubjectUserSid, SubjectUserName, SubjectDomainName, SubjectLogonId, DSName, DSType, ObjectDN, ObjectGUID, ObjectClass, AttributeLDAPDisplayName, AttributeSyntaxOID, AttributeValue, OperationType, and OpCorrelationID.
- AttributeLDAPDisplayName=nTSecurityDescriptor identifies the changed security descriptor; ObjectClass=organizationalUnit can identify an OU target.
- Value Deleted and Value Added records with the same OpCorrelationID can be linked; the event does not calculate the ACE’s effective access result by itself.
Separate the change from its impact
Event 5136 may report a change to the nTSecurityDescriptor attribute. Separate the old and new descriptors from the target-object context to determine which ACE grants which principal effective access.
OpCorrelationID helps link the deleted and added value records for one change; matching the change to an approved record remains necessary.
Convert SDDL into a scope table
For each ACE, keep type, flags, rights, object GUID, inherited-object GUID, and trustee in separate columns. This prevents a broad Generic All entry from hiding a narrower WRITE_DAC entry.
The parser does not make an effective-access decision. Deny and allow order, group membership, object state, and inheritance must also be evaluated.
Detection logic · XPath
*[System[(EventID=5136)]] and *[EventData[Data[@Name='AttributeLDAPDisplayName']='nTSecurityDescriptor']]Query assumptions
- This is an unexecuted candidate filter for raw Windows Event Log XML field names.
- Narrow the OU scope further with an exact ObjectDN allowlist or a controlled DN-suffix rule.
- The record may be absent if Audit Directory Service Changes Success or the appropriate SACL is not configured.
- AttributeValue formatting was not verified in a lab for a specific build and configuration; the query relies only on the attribute name.
False positives
- Approved delegation-of-control changes and planned ACL maintenance.
- Provisioning automation and migration operations.
- Negative example: absence of 5136 cannot prove that auditing or the SACL is missing; presence of 5136 does not show the ACE’s effective access by itself.
Hardening
- Assign delegation directly to a managed group and limit the right and object-type scope.
- Review OU DACLs regularly, including explicit and inherited ACEs, trustee SIDs, and GUID coverage.
- Use a custom OU for objects that need management scope rather than relying on a default container; do not treat the OU as a security boundary.
- Evaluate isolation requirements against the forest/domain threat model and the privileges of service administrators.
- Compare audit changes with an approved change record; validate the SDDL through a Windows API round trip and on a controlled OU in a lab. These steps have not yet been performed.
Read the examples
READ THE EXAMPLE TOGETHER
SYNTHETIC TEACHING EXAMPLEWhich entries describe access, audit or integrity rules?
OU delegation scope · synthetic SDDL
A · Generic AllAllow entry. The mask scopes the allow/deny entry for its trustee. Effective access cannot be concluded without the request, token, order and object type. CI: inheritable by child containers.
OA · WRITE_DACObject-specific allow entry. The mask scopes the allow/deny entry for its trustee. Effective access cannot be concluded without the request, token, order and object type. CI: inheritable by child containers. IO: not effective on this object; effective only after inheritance. The inherit-object GUID restricts the inheriting object class: organizationalUnit · bf967aa5-0de6-11d0-a285-00aa003049e2.
(A;CI;GA;;;S-1-5-21-111111111-222222222-333333333-1105)(OA;CIIO;WD;;bf967aa5-0de6-11d0-a285-00aa003049e2;S-1-5-21-111111111-222222222-333333333-1106)This section is part of the security descriptor. Owner, primary group, DACL and SACL carry different information.
Reading an entry is different from concluding that someone can access the object. The request, token, ACE order and object type also matter.
This view explains SDDL entries; it does not run the Windows access decision. SACL audit and mandatory-label entries do not replace DACL permissions.
Scope of this example
Contains two ACEs. ACE 1: A/CI/GA, trustee RID 1105, no object GUID. ACE 2: OA/CIIO/WD, object GUID blank, inherited-object GUID set to the organizationalUnit schemaIDGUID, trustee RID 1106. This is not a production ACL or operational advice; no parser or Windows API round-trip test was run, and effective access is not calculated.
Open the raw record · SDDL
D:(A;CI;GA;;;S-1-5-21-111111111-222222222-333333333-1105)(OA;CIIO;WD;;bf967aa5-0de6-11d0-a285-00aa003049e2;S-1-5-21-111111111-222222222-333333333-1106)Two reality checks
- Assumption: Creating a separate department OU in the organization chart provides security isolation.
- In fact: An OU defines administrative classification, Group Policy, and delegation scope. Effective isolation depends on ACLs and broader architecture; an OU does not shield against forest-level service administrators.
- Assumption: Delegating an OU means Full Control over every object beneath it.
- In fact: The effect is limited by the ACE mask, trustee SID, inheritance flags, object and inherited-object GUIDs, and the target object’s inheritance state; some ACEs apply only to particular descendant classes.
YOUR TURN
Work through this story.
Go beyond recall: change a condition, read evidence, explain the reason for a decision.
1 / 3 · PREDICT
Tunahan is moved to a separate OU. Does this create isolation from forest administrators?
A hint
Organizational placement differs from the broadest security boundary.
Read the answer reasoning
No; an OU is a management/GPO/delegation scope.
An OU is not a forest-level hostile-administrator isolation boundary.
2 / 3 · READ EVIDENCE
Does this scope card establish the same right on Tunahan’s user object?
- Parent / Üst nesne
- OU=People
- Delegated right / Hak
- WRITE_DAC
- Applicable descendant class / Alt nesne sınıfı
- organizationalUnit
- Examined target class / Hedef sınıf
- user
A hint
Which objects match the descendant class?
Read the answer reasoning
No; the descendant OU-class condition does not match the user class.
A right on the parent is bounded by target class and inheritance scope.
3 / 3 · EXPLAIN
Why recheck effective permissions and policy after moving Tunahan to another OU?
A hint
Connect DN placement with inherited ACE/policy context.
Read the answer reasoning
A move changes parent and inheritance/GPO scope; effective rights depend on explicit/inherited ACEs, SID, target class and requested right. The OU name alone does not determine the outcome.
- I identified the new parent/inheritance context.
- I did not infer automatic Full Control or isolation from the OU name.
Your explanation is not automatically graded. Compare the checkpoints with your answer.
Open the case terminal · PowerShell / CMD
Training simulation · Commands and outputs belong to this case.
Read the account name and SID of this session.
Run the prepared script as supplied, or try the everyday commands below.
Ctrl / ⌘ + Enter: run · Shift + Enter: new line
PS C:\Users\tunahan>
Long output: scroll inside the terminal to read more.
Curious? Try everyday commands
Tap a command, then Run. User and network details follow the selected sample computer.
Recent commands in this session
These are learning practices; they do not affect certification exam scores.
Sources
- Microsoft · Understanding the Active Directory Logical Model
Forest, Domain, and Organizational Units sections: shared structure and logical scopes. - Microsoft · MS-GPOD glossary
“forest”, “domain”, and “distinguished name (DN)” definitions and security/management boundary terminology. - IETF · RFC 4512: LDAP Directory Information Models
§2.1–2.3: directory information tree, naming, and the DN/RDN model. - Microsoft · Organizational-Unit class
Class definition and schemaIDGUID bf967aa5-0de6-11d0-a285-00aa003049e2. - Microsoft · Delegating Administration by Using OU Objects
Detailed delegation and inheritable rights with OU objects. - Microsoft · Inheritance and Delegation of Administration
ACE inheritance and the object-specific delegation model. - Microsoft · ACE Strings
ACE string syntax: type, flags, rights, object GUID, inherited-object GUID, and trustee. - Microsoft · 5136(S): A directory service object was modified
Event Description, Version 0 XML, field descriptions, SACL requirements, and Directory Service Changes requirements.