Skip to main content
skill CX Codex

iac-security-review — Claude Code skill: review and install

iac-security-review reviews Terraform, Kubernetes, and CloudFormation for security misconfigurations. Use it before an infrastructure change is reviewed or deployed.

CC-BY-4.0 196 installs ★ 230 updated 2026-10-15

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add OWASP/secure-agent-playbook --skill iac-security-review -a claude-code
Open on GitHub

What iac-security-review does

The skill identifies the IaC type from file extensions and content, then checks the configuration across security areas. It looks for excessive permissions, credentials in code, open ingress, public resources, missing encryption, weak storage settings, disabled audit logging, and supply-chain risks.

Its checks use CIS Benchmarks, cloud-provider security guidance, and Pod Security Standards for Kubernetes. Each finding includes a resource path, an explanation of the misconfiguration, an attack scenario, a corrected code example, and a severity rating. Findings are ordered by severity and followed by a summary and secure-configuration improvements.

File type determines the review path: .tf and .tofu files map to Terraform/OpenTofu, manifests with apiVersion and kind map to Kubernetes, and templates containing AWS:: map to CloudFormation. Helm charts receive Kubernetes checks with Helm-specific coverage. For Kubernetes, privileged containers are part of the platform-specific review.

What it helps with

  • spot excessive permissions and wildcard policies
  • find credentials hardcoded in infrastructure files
  • check ingress rules for open ports and public exposure
  • detect missing encryption and audit logging
  • flag unpinned versions and unverified modules or images

Example prompts for the agent

  • Review the Terraform files in infra/ for excessive permissions, embedded secrets, and public resources.
  • Check these Kubernetes manifests against Pod Security Standards and sort the findings by severity.
  • Review the CloudFormation templates and give an attack scenario plus a fixed code example for each finding.

How to install iac-security-review

1Skills CLI (Vercel)

npx skills add OWASP/secure-agent-playbook --skill iac-security-review -a claude-code

2Manually: put the files in place

~/.claude/skills/iac-security-review/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/iac-security-review/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about iac-security-review

How do I install iac-security-review in Claude Code?

Run npx skills add OWASP/secure-agent-playbook --skill iac-security-review -a claude-code. The skill file will be available at ~/.claude/skills/iac-security-review/SKILL.md.

What does iac-security-review do?

It reviews Terraform, Kubernetes, and CloudFormation for security risks, then reports findings with severity, attack scenarios, and corrected code examples.

Which security standards does the skill use?

It checks configurations against CIS Benchmarks, cloud-provider security guidance, and Pod Security Standards for Kubernetes.

Source text

SKILL.md · CC-BY-4.0
---
name: iac-security-review
description: Security review of Infrastructure-as-Code (Terraform, Kubernetes, CloudFormation). Use when reviewing IaC files for misconfigurations, overpermissioning, exposed resources, missing encryption, secrets in code, and supply chain risks. Covers CIS benchmarks and cloud security best practices.
license: CC-BY-4.0
---

# IaC Security Review

Review infrastructure-as-code for security risks by following the full procedure in `plays/iac-security-review.md`.

## Steps

1. **Detect IaC Type** — Identify the infrastructure technology from file extensions and content:
   - `.tf` / `.tofu` files → Terraform/OpenTofu (reference `data/secure-code-prompts/terraform.md`)
   - Kubernetes manifests (apiVersion, kind: Deployment/Pod/Service) → Kubernetes (reference `data/secure-code-prompts/kubernetes.md`)
   - CloudFormation templates (AWSTemplateFormatVersion, Resources with AWS::) → CloudFormation (reference `data/secure-code-prompts/cloudformation.md`)
   - Helm charts (`Chart.yaml`, templates/) → Kubernetes review with Helm-specific checks

2. **Systematic Review by Security Domain** (priority order):
   - **Identity & Access Management** — Overly permissive policies, wildcard permissions, hardcoded credentials, privilege escalation paths
   - **Secrets Management** — Hardcoded secrets, plaintext credentials, missing vault/secret manager integration
   - **Network Security** — Open ingress (`0.0.0.0/0`), unrestricted ports, missing segmentation, public exposure
   - **Encryption** — Missing encryption at rest/in transit, weak algorithms, default keys
   - **Storage Security** — Public buckets, unencrypted volumes, missing versioning
   - **Logging & Monitoring** — Missing audit trails, disabled CloudTrail/audit logging
   - **Resource Exposure** — Databases, admin interfaces, APIs exposed to internet
   - **Supply Chain** — Unpinned versions, untrusted sources, unverified modules/images
   - **Platform-Specific Risks** — Terraform state exposure, K8s privileged containers, CFN nested stack integrity

3. **Check Against Benchmarks** — Validate configurations against:
   - CIS Benchmarks (AWS/Azure/GCP/Kubernetes)
   - Cloud provider security best practices
   - Pod Security Standards (for Kubernetes)

4. **Produce Findings** — For each finding: cite resource path, explain the misconfiguration, describe attack scenario, provide fixed code example, rate severity.

## Output

Findings sorted by severity using `templates/finding.md` format, summary with severity counts, and secure configuration improvements section.

## References

- CIS Benchmarks (AWS, Azure, GCP, Kubernetes)
- OWASP Infrastructure Security Cheat Sheet
- NSA/CISA Kubernetes Hardening Guide
- Cloud provider Well-Architected Frameworks

© OWASP · CC-BY-4.0 · OWASP/secure-agent-playbook

Similar skills

All skills for Security →

From the same set18

The whole set →
agent-security-audit agent-security-audit is a Claude Code skill that checks AI agent configurations for vulnerabilities. Run it when reviewing CLAUDE.md files, MCP configs, and agent orchestration code. CX Codex +1 302installs mobile-code-review mobile-code-review audits native Android and iOS source code for security vulnerabilities against the OWASP MASVS v2.1.0 benchmark. CX Codex +1 224installs prompt-injection-test prompt-injection-test runs an LLM app through prompt injection attacks from the Arcanum PI Taxonomy. Use it when red-teaming your own AI app or checking how well its guardrails hold. CX Codex +1 220installs mcp-server-review mcp-server-review is a Claude Code skill that audits MCP server code and client settings for security risks. Run it to review a server or assess it before installation. CX Codex +1 217installs securability-engineering securability-engineering — a skill that generates code adhering to FIASSE v1.0.4 and ASVS controls by default. Use it when building security-sensitive functions, APIs, or components that must pass review without rework. CX Codex +1 191installs multi-agentic-threat-model multi-agentic-threat-model conducts systematic threat modeling for multi-agent architectures using CSA MAESTRO and OWASP guidelines. CX Codex +1 188installs llm-risk-assess llm-risk-assess assesses LLM applications against OWASP Top 10 for LLM Applications 2025. Built for teams embedding models in chatbots, RAG pipelines, or AI agents. CX Codex +1 186installs prd-securability-enhancement prd-securability-enhancement enriches PRDs, user stories, and feature specs with OWASP ASVS controls and FIASSE guidance before developers write code. CX Codex +1 170installs

Project sponsors

Companies that keep this analytics open