Files
nexus/wiki/concepts/SCP-Security-Control-Policy.md
2026-04-29 00:02:51 +08:00

43 lines
2.0 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
---
title: "SCP (Security Control Policy)"
type: concept
tags: ["AWS", "Security", "Landing-Zone", "Tagging", "OU"]
sources: ["ctp-topic-10-aws-landing-zone-lz-data-collection-tagging-related-security"]
last_updated: 2026-04-28
---
## Definition
SCPSecurity Control Policy是 AWS Organizations 中的一种策略类型通过「显式拒绝」deny逻辑强制执行组织范围内的安全与合规规则。与 IAM 策略不同SCP 作用于组织单元OU或账户级别控制谁可以执行什么操作而不是授予权限。
## Core Mechanism
- **基于标签的 SCP**:拒绝资源在不符合预期标签值的情况下被创建(如:拒绝在特定 OU 中创建没有 `Environment: Production` 标签的 EC2 实例)
- **OU 分层执行**SCP 在 OU 层级自上而下继承,高层级 OU 的拒绝策略优先级最高
- **防止标签篡改**:阻止普通用户通过修改标签(如从 `Team: ADM` 改为 `Team: ITOM`)绕过安全审计或访问控制
## In AWS Landing Zone Context
在 [[AWS-Landing-Zone]] 架构中SCP 是 Landing Zone 治理的关键组件:
- 与 [[Checkpoint-Firewall]] 的标签驱动策略联动SCPs 确保只有正确标记的资源进入云环境Checkpoint 基于标签实施网络层访问控制
- SCP 是「防护栏」Guardrails的核心实现手段
- 补充 AWS IAM 的「授予权限」模型,提供强制拒绝能力
## Example Use Case
```
# 拒绝在没有 Owner 标签的情况下创建 EC2
{
"Effect": "Deny",
"Action": "ec2:RunInstances",
"Resource": "arn:aws:ec2:*:*:instance/*",
"Condition": {
"Null": {
"aws:RequestTag/Owner": "true"
}
}
}
```
## Connections
- [[AWS-Landing-Zone]] — SCP 是 LZ 治理的核心工具
- [[Checkpoint-Firewall]] — SCP + Checkpoint 构成标签驱动的端到端安全体系
- [[ctp-topic-10-aws-landing-zone-lz-data-collection-tagging-related-security]]
- [[ctp-topic-28-aws-tag-validation-tool]] — SCP 强制执行标签Tag Validation Tool 审计存量资源