Sub topic 5
What SCPs do not restrict
This chapter assumes you know how SCPs cap permissions for principals and how they inherit down the organization tree. An SCP is a broad guardrail, but it has gaps. If you don't know them, you may rely on a control that doesn't apply to the principal you care about.
SCPs only filter identities in member accounts
An SCP sets the maximum permissions for IAM users and roles in the accounts it applies to. It doesn't grant anything, and it doesn't reach everything. The main exemptions are:
| Not restricted by SCPs | Why it matters |
|---|---|
| Users and roles in the management account | Attaching an SCP to the root or to the management account has no effect on its principals. |
| Service-linked roles | AWS services use these roles to do work on your behalf, so SCPs can't break the service. |
| Principals outside your organization | An SCP applies only to your member accounts. It can't restrict an external account that reaches your resource through a resource-based policy. |
| A few root-user tasks | Examples are changing the AWS Support plan, registering for Enterprise Support, and configuring reverse DNS for Lightsail or EC2 email. |
| Some CloudFront functions | Trusted signer functionality for CloudFront private content is exempt. |
The root user of a member account is restricted by SCPs. Only the management account is exempt.
Consequences for guardrail design
Keep workloads out of the management account
Any workload that runs in the management account can't be limited by an SCP. Use that account only for organization administration, billing, and policy management. Put workloads in member accounts, where your guardrails apply.
SCPs do not control outside access
Suppose a bucket policy in a member account allows an external account to read objects. An SCP in your organization doesn't block that access, because the caller isn't one of your principals. Blocking it takes a resource control policy (RCP), which the later chapters cover. A bucket policy or an S3 setting that blocks public access can also help.
Service-linked roles keep working
You can't deny a service-linked role's actions with an SCP. A broad deny such as "no EC2 actions" won't stop Auto Scaling from launching instances through its service-linked role. The user who tries to launch an instance directly is still blocked.
The Region SCP's NotAction list is a different thing
The Region-restriction SCP from earlier uses NotAction to skip global services such as IAM and Route 53. That is a choice written into the policy. The exemptions in this chapter are built into the SCP mechanism, and you can't edit them.
Check which principals an SCP covers
Before you rely on a guardrail, confirm where it is attached and whether the target holds the principals you care about. This command lists the policies attached to a target:
aws organizations list-policies-for-target \
--target-id ou-exam-ple12345 \
--filter SERVICE_CONTROL_POLICYCheck the result against the account type. If the target is the management account, the policies listed there have no effect on its principals.
Exercise
A deny SCP for s3:DeleteBucket is attached to the organization root. A role in the management account deletes a bucket, and an Auto Scaling service-linked role performs an action the SCP denies. A role in a member account then tries to delete a bucket. Which of these three requests does the SCP block?
Show answer
It blocks only the member account role. The management account is not restricted by SCPs, and service-linked roles are also exempt, so those two requests are not affected by the SCP.