Sub topic 1
The Organization Tree: Root, OUs, and Accounts
Prerequisites
This chapter assumes basic IAM knowledge, including identity-based policies, roles, and policy evaluation. You should also be able to read JSON policy elements such as Effect, Action, Resource, and Condition.
The organization tree
AWS Organizations groups accounts into a hierarchy:
- The organization root is the top-level container.
- An organizational unit (OU) is a container for accounts or nested OUs.
- An account is the boundary where AWS resources and workloads run.
Policies attached higher in the tree can apply to descendants.
A policy attached to the root applies to every member account. A policy attached to an OU applies to that OU and its child accounts and OUs. A policy attached directly to an account applies only there. The management account is special: service control policies (SCPs) do not restrict principals in it.
Authorization policy types
AWS Organizations supports authorization policies that set organization-wide guardrails:
- An SCP sets the maximum permissions available to IAM principals in member accounts.
- An RCP sets the maximum permissions available on supported resources in member accounts.
Neither policy grants permissions. An IAM identity-based policy or resource-based policy must still allow the request.
Before attaching either type, enable it on the organization root. The following commands use placeholder IDs:
aws organizations list-roots
aws organizations enable-policy-type \
--root-id r-example \
--policy-type SERVICE_CONTROL_POLICY
aws organizations enable-policy-type \
--root-id r-example \
--policy-type RESOURCE_CONTROL_POLICYAttaching policies and inheritance
After creating a policy, attach it to a root, OU, or account by using the target ID. Effective permissions must satisfy every applicable guardrail. A deny at any inherited level overrides an allow elsewhere.
What SCPs do not restrict
SCPs restrict actions requested by IAM users and roles in member accounts. They do not:
- Grant permissions.
- Restrict principals in the management account.
- Affect service-linked roles.
- Directly control resource access without a principal request.
- Replace IAM policies, permission boundaries, or resource-based policies.
SCPs can still restrict the member-account root user. RCPs provide a separate resource-focused guardrail and apply only to supported AWS services and resources.
Exercise
An SCP allows ec2:RunInstances, but an IAM role has no policy allowing it. Can the role launch an instance?
Show answer
No. The SCP permits the maximum possible action, but an identity-based or resource-based policy must also grant it.