Skip to main content

Cloud Security Posture Assessment (CIS)

Assess your AWS, GCP, or Azure posture against CIS Benchmarks: find misconfigurations, over-permissioned roles, and gaps with IaC remediation.

Fill in the placeholders

Edit the values, then copy your finished prompt.

Your Prompt
prompt.txt
Conduct a cloud security posture assessment for our AWS environment.

**Environment details:**
- Cloud provider: AWS
- Account structure: AWS Organizations with 12 accounts (prod, staging, dev, security, logging, shared-services)
- Primary workloads: EKS microservices, RDS PostgreSQL, S3 data lake, Lambda event processing
- Compliance requirements: SOC 2 Type II, GDPR, CIS AWS Foundations Benchmark v3.0
- Current security tooling: AWS Security Hub, GuardDuty, CloudTrail, Config Rules

**Assess the following domains against CIS Benchmarks:**

1. **Identity & Access Management:**
   - Root/admin account security (MFA, access keys, usage monitoring)
   - IAM policy review: identify over-permissioned roles and users
   - Service account/role hygiene: unused roles, last-used analysis
   - Cross-account access trust relationships audit
   - SSO/federation configuration validation
   - Generate least-privilege policy recommendations with Terraform code

2. **Network Security:**
   - Security group/firewall rules: identify overly permissive rules (0.0.0.0/0)
   - VPC/VNet configuration: subnet isolation, flow logs enabled
   - Public-facing resources inventory (S3 buckets, storage accounts, load balancers)
   - DNS security (DNSSEC, private hosted zones)
   - VPN/Direct Connect/ExpressRoute configuration review
   - Network segmentation assessment with diagram

3. **Data Protection:**
   - Encryption at rest: identify unencrypted volumes, databases, object storage
   - Encryption in transit: TLS configuration audit (minimum version, cipher suites)
   - Key management: KMS/Key Vault rotation policies, key access audit
   - Data classification: identify storage containing sensitive data without proper controls
   - Backup configuration: frequency, retention, cross-region, immutability

4. **Logging & Monitoring:**
   - CloudTrail/Activity Log/Audit Log enabled in all regions
   - Log storage: integrity validation, retention period, cross-account aggregation
   - Alert rules for critical events: root login, IAM changes, security group modifications
   - VPC Flow Logs / NSG Flow Logs enabled and analyzed
   - Missing detective controls gap analysis

5. **Compute & Container Security:**
   - Instance/VM patch status and vulnerability scan results
   - Container image scanning in registry (CVE threshold policy)
   - Kubernetes/ECS cluster security: RBAC, network policies, pod security standards
   - Serverless function permissions review (Lambda/Cloud Functions/Azure Functions)
   - Instance metadata service (IMDS) v2 enforcement

6. **Remediation Playbook:**
   - For each finding, generate Terraform remediation code
   - Prioritize by risk score: Critical (fix in 24h), High (7 days), Medium (30 days), Low (90 days)
   - Automated remediation scripts where safe (e.g., enable encryption, restrict security groups)
   - Exception/risk-acceptance process for findings requiring business justification

7. **Compliance Mapping:**
   - Map findings to SOC 2 Type II, GDPR, CIS AWS Foundations Benchmark v3.0 control requirements
   - Generate compliance evidence artifacts
   - Identify gaps requiring compensating controls

Output a structured report with executive summary, detailed findings table (ID, title, severity, affected resources, remediation), and Terraform code blocks for each fix.

What this prompt does

This prompt runs a cloud security posture assessment against the CIS Benchmarks for your environment. You provide the [cloud_provider], [account_structure], [workloads], [compliance_frameworks], and [existing_tools], and it assesses six domains — IAM, network security, data protection, logging/monitoring, compute/container security, and remediation — then maps findings to compliance and generates Infrastructure-as-Code fixes in your [iac_tool].

The structure works because cloud breaches usually come from a handful of quiet misconfigurations: 0.0.0.0/0 security-group rules, over-permissioned IAM roles, unencrypted storage, and missing audit logs. The prompt sweeps exactly these against CIS Benchmark controls, then — crucially — generates [iac_tool] remediation code alongside each finding so fixes are reviewable in a pull request rather than clicked through a console. The [compliance_frameworks] mapping turns raw findings into audit evidence.

When to use it

  • You're securing a [cloud_provider] account and want a structured CIS Benchmark sweep instead of ad-hoc checks.
  • You suspect over-permissioned roles or open 0.0.0.0/0 rules and need them found and prioritized.
  • An audit for [compliance_frameworks] like SOC 2 or GDPR requires documented posture evidence.
  • You want remediation as reviewable [iac_tool] (Terraform) code, not manual console changes.
  • You're managing a multi-account [account_structure] and need cross-account trust and logging reviewed.
  • You need findings risk-ranked with concrete fix deadlines (24h / 7d / 30d / 90d).

Example output

You get a structured report across six domains: IAM (root security, over-permissioned roles, least-privilege policy code), network (open security groups, VPC flow logs, public-resource inventory), data protection (encryption at rest/transit, KMS rotation), logging (CloudTrail coverage, alert rules), and compute/container security (patching, image scanning, IMDSv2). Each finding comes with a severity, affected resources, and an [iac_tool] remediation block, plus a compliance mapping to your [compliance_frameworks] and a prioritized fix timeline.

Pro tips

  • Specify [cloud_provider] exactly (AWS, GCP, Azure); the CIS controls and resource names differ across them.
  • Describe [account_structure] in detail so cross-account trust and centralized logging get assessed properly.
  • List your [existing_tools] (Security Hub, GuardDuty) so the prompt complements them instead of duplicating coverage.
  • Name your real [compliance_frameworks] to get findings mapped to actual control requirements and evidence artifacts.
  • Treat the [iac_tool] remediation as a starting point — review every generated change before applying it to production.
  • Run the IAM and network domains first; that's where the highest-impact exposures typically hide.

Frequently Asked Questions

Does this assess my live cloud account directly?
No. It reasons from the environment details you provide and your `[existing_tools]` output; it cannot connect to your account. Feed it findings from Security Hub, Config, or a scanner, and it structures them against CIS controls with prioritized remediation.
Which cloud providers does it support?
AWS, GCP, and Azure — set your choice in `[cloud_provider]`. The CIS controls, resource names, and remediation syntax adapt to the provider, so always specify the exact one rather than leaving it generic for accurate, applicable guidance.
Does it generate Terraform to fix the findings?
Yes. For each finding it produces remediation code in your `[iac_tool]`, such as Terraform, so fixes like enabling encryption or restricting a security group can be reviewed in a pull request. Always review generated changes before applying them.
Can it help with SOC 2 or GDPR compliance?
It maps findings to whatever you list in `[compliance_frameworks]` and generates compliance evidence artifacts and gap analysis. This supports your audit preparation, but it is not a substitute for a formal assessment by a qualified auditor.
Engr Mejba Ahmed

Need this built for real?

Engr Mejba Ahmed

AI Developer · Software Engineer

I'm Mejba — I design and ship production AI systems, automations, and full-stack apps. If you want this turned into a working solution for your team, let's talk.

More in Cybersecurity Prompts

Engr Mejba Ahmed

Engr Mejba Ahmed

AI assistant · trained on my work

👋

Hey there!

Quick Actions

WhatsApp Direct line to me

Chat on WhatsApp

+880 1723 741224 · Replies within the hour on working days

Popular Questions

Engr Mejba Ahmed is connected
Engr Mejba Ahmed is typing...
Engr Mejba Ahmed avatar

✉ Want me to follow up? Drop your email

Engr Mejba Ahmed avatar

📞 Connect Directly

Choose how you'd like to reach me

WhatsApp

+880 1723 741224

Email

mejba.13@gmail.com

✓ Details sent! I'll get back to you shortly.

Powered by OpenAI

335+

Blog Posts

25

AI Courses

63

Projects

Services & Expertise

Pricing & Process

Learning & Resources

Connect & Support