Introduction
The worst AWS governance setup I've ever inherited was also, technically, the most secure. Every non-standard action required a ticket. The security team had written SCPs that denied anything they hadn't explicitly reviewed. Developers couldn't spin up an EC2 instance without filing a request. The environment hadn't had a significant security incident in two years. It also hadn't shipped a meaningful feature in six months, because every attempt to use a new AWS service required a governance review that took three weeks.
Security theater isn't security. When your AWS governance model makes developers route around the guardrails (using personal AWS accounts for experimentation, hardcoding credentials to avoid IAM complexity, shipping to production from local machines to dodge the locked-down CI/CD pipeline), you haven't reduced risk. You've moved it somewhere you can't see it.
AWS Service Control Policies, permission boundaries, and AWS Config rules are powerful governance primitives. Used well, they enforce security and compliance automatically while giving teams the autonomy to move fast. Used poorly, they become organizational friction that people learn to work around. This post is about the difference, and how to build a governance layer that actually holds at scale.
The Difference Between a Guardrail and a Roadblock
The analogy is literal: a guardrail on a highway prevents you from driving off a cliff. It doesn't slow you down. It's not in your lane. You don't think about it unless you're about to make a catastrophic mistake. A roadblock stops everyone, regardless of where they're going or whether they pose any risk.
Most AWS governance implementations start as guardrails and drift toward roadblocks over time. The drift happens through accumulation: each security finding generates a new restriction. Each incident produces a new SCP. Each audit recommendation adds a new Config rule. Nobody removes old controls when the underlying risk changes. After two years, you have a governance layer built from dozens of independent decisions that no one person fully understands, and developers who have learned that "following the process" is slower than finding a workaround.
The technical failure mode is more specific than "too many restrictions." It's restrictions without feedback mechanisms. When an SCP blocks an action, the developer gets an access denied error. They don't know which SCP caused it, which OU it's attached to, or who to contact to change it. When a Config rule marks a resource as non-compliant, the developer may not know the resource exists or what to do about it. The governance layer generates signals, but those signals don't reach the people who need to act on them.
Here's a concrete example of how this plays out: a platform team attaches an SCP to the Production OU that denies ec2:RunInstances without a specific tag set: a legitimate control to enforce cost allocation tagging. The SCP works correctly. The problem is that the error message from a failed RunInstances call is:
An error occurred (UnauthorizedOperation) when calling the RunInstances operation:
You are not authorized to perform this operation.
No indication that the SCP is the cause. No indication which tag is missing. The developer opens a ticket. The ticket sits for two days. The developer tries a workaround. This is the failure pattern: not the SCP itself, but the absence of a feedback loop that would let the developer self-correct in under five minutes.
AWS Deep Dive: Building Governance That Developers Can Work With
Service Control Policies: Architecture Before You Apply Them
SCPs are evaluated before IAM policies and cannot be overridden by any principal in a member account, including account root. This makes them the most powerful governance primitive in AWS Organizations, and the one most likely to cause an irreversible problem if applied carelessly.
The architecture of your SCP strategy matters as much as the content of individual policies. The patterns I use consistently:
Deny-by-default with explicit allow is the wrong model for most organizations. A full-deny SCP that only permits explicitly listed actions sounds secure. In practice, it means every new AWS service your team wants to use requires an SCP update: a centralized bottleneck that kills velocity. The right model for most organizations is an allow-by-default posture with targeted denies for specific high-risk actions and out-of-policy regions.
The Policy Staging OU is non-negotiable. Before any SCP touches a Production OU, it should be applied to a staging OU containing a non-production account and validated against real workloads. SCPs have no preview mode or dry-run capability. A misconfigured SCP attached to the wrong OU at the wrong level can lock your own automation out of accounts, and reversing it requires access to the management account, which may itself be restricted.
Region-deny SCPs are the highest return-on-investment control. Preventing resource creation in regions your organization doesn't operate in reduces your compliance audit surface, limits blast radius from compromised credentials, and costs developers nothing:
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "DenyNonApprovedRegions",
"Effect": "Deny",
"NotAction": [
"iam:*",
"organizations:*",
"support:*",
"sts:*",
"cloudfront:*",
"route53:*",
"waf:*"
],
"Resource": "*",
"Condition": {
"StringNotEquals": {
"aws:RequestedRegion": ["us-east-1", "us-west-2"]
}
}
}
]
}
The NotAction block is critical and non-obvious: IAM, STS, CloudFront, Route 53, and several other global services make API calls that don't specify a region or operate from us-east-1 regardless of where the caller is. Denying these services via a region condition breaks IAM Identity Center, CloudFormation cross-account operations, and Route 53 record management. Miss this and your region-restriction SCP will create an incident the first time anyone tries to assume a cross-account role from the console.
Build an SCP inventory and map every control to a specific risk. If you can't explain what incident or compliance requirement a given SCP is preventing, it probably shouldn't exist. I use a simple structure: SCP name, attached OUs, the risk it mitigates, the date it was added, and the last date it was reviewed. Controls without owners drift and accumulate until the governance layer is too complex for anyone to reason about.
Permission Boundaries: The Delegation Pattern That Removes Bottlenecks
Permission boundaries (covered in more depth in my IAM post) are the mechanism that makes delegated IAM management safe. In the governance context, they're important because they let you answer "yes" to developer requests that would otherwise require central IAM team involvement.
The delegation pattern works like this: the platform or security team defines a permission boundary policy that caps the maximum permissions any developer-created role can have. Then they give developers the ability to create IAM roles (which they need for Lambda execution roles, ECS task roles, and CI/CD service accounts), under the condition that every role they create carries that boundary:
{
"Sid": "RequireBoundaryOnRoleCreation",
"Effect": "Allow",
"Action": [
"iam:CreateRole",
"iam:PutRolePolicy",
"iam:AttachRolePolicy",
"iam:DetachRolePolicy"
],
"Resource": "*",
"Condition": {
"StringEquals": {
"iam:PermissionsBoundary": "arn:aws:iam::ACCOUNT_ID:policy/TeamBoundary"
}
}
}
This policy, in the developer's own IAM role policy, allows them to create and modify roles only if those roles have the TeamBoundary permission boundary attached. Without the boundary, the CreateRole call fails. The developer cannot create a role more permissive than what the boundary allows, including AdministratorAccess or iam:*.
The governance result: developers can self-serve IAM for their services without opening tickets. The platform team maintains the boundary policy and reviews it periodically. Privilege escalation risk is eliminated structurally, not through process.
The non-obvious limitation: permission boundaries don't automatically propagate when you update the boundary policy. If you add a new service to the boundary (say, adding bedrock:* to allow AI model access), existing roles are immediately updated because the boundary is evaluated dynamically. But if you remove a service from the boundary, existing roles that already have that permission in their identity policy will lose effective access immediately. Communicate boundary policy changes before applying them and verify that your change alert process covers boundary policies, not just SCPs.
AWS Config Rules: Compliance Signals That Reach the Right People
AWS Config evaluates resource configurations against rules you define and marks resources as compliant or non-compliant. In the context of guardrails vs. roadblocks, Config occupies a different layer than SCPs: SCPs prevent actions, Config detects drift after the fact and generates remediation signals.
The governance value of Config is in its feedback loop, not its detection capability. A Config rule that marks an S3 bucket as non-compliant for missing server-side encryption is only useful if that finding reaches the team responsible for the bucket within a timeframe that allows them to fix it before it becomes a compliance issue.
Build your Config architecture around the feedback loop first:
- Aggregate Config findings from all member accounts into a central Security account using Config Aggregator.
- Route Config rule violations to Security Hub as findings.
- From Security Hub, route high-severity findings to a Slack channel or PagerDuty workflow via EventBridge → SNS → Lambda.
- Tag every resource with an
ownertag and use that tag in the EventBridge routing to send findings to the right team Slack channel, not a single central security inbox that nobody monitors.
The automatic remediation feature in Config (using SSM Automation documents) is worth evaluating for specific high-confidence rules, for example, automatically enabling S3 bucket versioning on newly created buckets that don't have it. Be conservative with automatic remediation: it modifies production resources without human review, and a misconfigured remediation document can cause more damage than the misconfiguration it was fixing. Start with notify-and-remediate-manually, graduate to automatic only for controls where the remediation is non-destructive and the false-positive rate is near zero.
Enjoying this so far?
Join thousands of engineers receiving practical engineering, Cloud, Distributed Systems, Infrastructure and AI engineering insights.
No spam. Unsubscribe anytime.
Tradeoffs and Decision Framework
SCPs vs. IAM policies: which layer carries the control? Controls that must apply unconditionally across an entire account or OU (region restrictions, denial of dangerous global actions like organizations:LeaveOrganization, prevention of CloudTrail disabling), belong in SCPs. Controls that are team or workload-specific (which S3 buckets a service can access, which Secrets Manager secrets a Lambda function can read), belong in IAM policies. Mixing these creates governance layers that are both harder to reason about and harder to audit.
Preventive vs. detective controls. SCPs are preventive, they stop an action before it happens. Config rules are detective, they identify drift after it's happened. Both are necessary; neither is sufficient alone. Preventive controls reduce the frequency of compliance violations. Detective controls catch the violations that preventive controls miss (service-level limits, human error, actions taken from the management account where SCPs don't apply). The right governance architecture uses both layers with defined ownership for each.
Governance at what granularity? Attaching SCPs at the Root level applies them to every account in the Organization including the management account (which you almost never want, because it breaks things like account billing operations. Attaching at the OU level is the standard pattern. Attaching to individual accounts is useful for exceptions), a specific sandbox account that needs broader permissions for R&D, but should be tracked and reviewed, not used as a workaround for overly restrictive OU-level policies.
When to use Config auto-remediation vs. manual. Auto-remediation is appropriate for: enabling encryption on new resources that missed it, adding missing required tags, reverting public access settings on S3 buckets. It is not appropriate for: deleting resources, modifying security groups in ways that might block traffic, or any action that could affect availability. Err heavily toward manual remediation with alerting until you've run the rule in monitoring mode long enough to understand its false positive rate.
Lessons from the Field
1. The first SCP I write for any new AWS Organization is region restriction, and the second is CloudTrail protection. Denying cloudtrail:StopLogging, cloudtrail:DeleteTrail, and cloudtrail:UpdateTrail in member accounts via SCP, with an exemption for the management account's automation role, means an attacker with a compromised developer key cannot cover their tracks by disabling audit logging. This is the control that makes everything else in your governance model trustworthy.
2. Permission boundaries eliminated a 3-day average IAM ticket queue for a platform team I worked with. They had five engineers handling IAM requests across 20 product teams. We designed a permission boundary that covered all the services those product teams used, gave developers iam:CreateRole gated on the boundary condition, and deployed it via an SCP that denied role creation without the boundary at the OU level. The IAM ticket queue went from 40+ open items to fewer than 5 within two weeks. The five engineers redirected that time to actual security work.
3. Config Aggregator without a routing strategy is a noise machine. One client had Config Aggregator enabled across 12 accounts sending findings to Security Hub. Security Hub had 14,000 open findings. Nobody was looking at it. The signal-to-noise ratio was so bad that a real misconfiguration sat unaddressed for six weeks because it was buried. We suppressed findings for known-acceptable configurations, tuned severity thresholds, and built EventBridge rules to route high-severity findings to team Slack channels. The volume dropped to 80 actionable findings and the average remediation time dropped from weeks to hours.
4. Never apply an SCP to a production OU on a Friday. This is not a joke. SCPs have no rollback button in the traditional sense: you remove them, but any damage done in the window between application and removal may require manual remediation. I apply SCP changes in a 2-hour window at the start of a Tuesday or Wednesday, with the relevant platform engineers on a call and the management account console open. The policy gets applied to the staging OU first, validated for 30 minutes, then moved to production.
Final Thoughts
The goal of AWS governance isn't the absence of incidents. It's the reduction of blast radius when incidents happen anyway, combined with an environment where engineering teams can move fast without the governance layer as a constant source of friction. Those two goals are not in conflict if you design the controls correctly.
The pattern that consistently works: start with a small set of high-confidence, high-impact preventive controls (region restriction, CloudTrail protection, public S3 block) applied via SCP. Layer Config rules for detective coverage with a feedback loop that reaches the right team in under an hour. Use permission boundaries to enable delegation instead of centralized IAM management. Review and prune controls quarterly.
The governance model you build in the first six months of an AWS organization sets the tone for everything that follows: it shapes whether developers see security as a partner or an obstacle.
Key Takeaways
- SCPs are preventive and absolute: they evaluate before IAM and cannot be overridden by any principal in a member account, including root. Use them for organization-wide controls (region restriction, CloudTrail protection, preventing account departure from the org), not workload-specific access control.
- The
NotActionblock in region-restriction SCPs is not optional. IAM, STS, CloudFront, Route 53, and several global services make API calls that bypass region conditions, omitting them fromNotActionbreaks IAM Identity Center, cross-account role assumption, and Route 53 management from the moment the SCP is applied. - Permission boundaries allow developers to self-serve IAM for their services without privilege escalation risk. Gate
iam:CreateRoleon aiam:PermissionsBoundarycondition pointing to a platform-managed boundary policy, developers can create roles, but none can exceed the boundary's scope. - Config rules without a feedback loop are a compliance theater. Aggregate findings into Security Hub, route high-severity violations via EventBridge to team-specific Slack channels using resource owner tags, and measure remediation time, not finding count, as your governance metric.
- Build a Policy Staging OU and test every SCP there before applying it to production OUs. SCPs have no dry-run mode. A misconfigured SCP applied to the wrong OU level can lock your own automation out of production accounts; the only fix requires management account access and manual remediation.
- Governance controls should map to documented risks, not security instincts. Every SCP and Config rule should have a named owner, a documented threat it mitigates, and a review date. Controls without owners accumulate into governance layers nobody can reason about or safely modify.
- Automatic Config remediation belongs only on non-destructive, high-confidence rules. Start every new rule in monitoring mode, validate its false-positive rate over 30+ days, and reserve auto-remediation for actions like enabling encryption or adding tags, never for deleting resources or modifying networking in ways that could affect availability.
Get insights like this in your inbox
Join thousands of engineers receiving practical engineering, Cloud, Distributed Systems, Infrastructure and AI engineering insights.
No spam. Unsubscribe anytime.