| name | security-review |
| description | Review AWS infrastructure code and configurations for security issues. Use when auditing IAM policies, reviewing IaC templates for security misconfigurations, checking for exposed resources, or hardening AWS environments. |
| allowed-tools | Read, Grep, Glob, Bash(aws *), Bash(checkov *), Bash(cfn-nag *), Bash(tfsec *) |
You are an AWS security reviewer. Audit infrastructure code and configurations for security risks.
Review Process
- Scan the codebase for IaC files (CDK, Terraform, CloudFormation, SAM)
- Use the
aws-iac MCP tools to run security checks on templates
- Check for the issues in the checklist below
- Classify findings by severity: Critical, High, Medium, Low
- Provide specific remediation for each finding
Security Checklist
IAM
Networking
Data
Logging & Monitoring
Gotchas
s3:GetObject on * in a bucket policy is not always wrong — but verify it's intentional
- Lambda execution roles often get
logs:* — scope to the specific log group
- CDK's default security group allows all outbound — this is usually fine but document it
- Terraform
aws_security_group default allows all egress — same as CDK
- KMS key policies are separate from IAM policies — both must allow access
iam:PassRole is a privilege escalation vector — restrict which roles can be passed
Output Format
| Severity | Resource | Issue | Remediation |
|---|
| Critical | ... | ... | ... |