Skip to content
Back to skills

Infrastructure Compliance Auditor

ASecurity

Audits a JSON description of your infrastructure (169 controls, 11 domains, 10 frameworks), your identity and access setup (55 controls plus MFA coverage and service-account checks) and a domain's DNS records (SPF, DKIM, DMARC, DNSSEC, CAA, MTA-STS, dangling CNAMEs), then lists each failed control with the value found and the fix. Use when preparing SOC 2, ISO 27001, HIPAA or PCI-DSS technical evidence, reviewing cloud or access-control posture, or checking a domain's email-authentication and...

  • 1,271 stars
  • 0 votes
  • 0 copies
  • 5 views
  • Added May 29, 2026
ai-agentspythonrustgobashawsgcpazuretestingapici/cd

Works with

  • cli
  • api

Security analysis

A100/100

Pro scans all 7 files and shows the line behind each finding

Scanned December 4, 2026

npx -y skills add borghei/Claude-Skills --skill infrastructure-compliance-auditor --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Infrastructure Compliance Auditor?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Infrastructure Compliance Auditor
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/borghei-infrastructure-compliance-auditor/badge)](https://www.skillsdirectory.com/skills/borghei-infrastructure-compliance-auditor)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: infrastructure-compliance-auditor
description: >
  Audits a JSON description of your infrastructure (169 controls, 11 domains, 10 frameworks),
  your identity and access setup (55 controls plus MFA coverage and service-account checks) and a
  domain's DNS records (SPF, DKIM, DMARC, DNSSEC, CAA, MTA-STS, dangling CNAMEs), then lists each
  failed control with the value found and the fix. Use when preparing SOC 2, ISO 27001, HIPAA or
  PCI-DSS technical evidence, reviewing cloud or access-control posture, or checking a domain's
  email-authentication and takeover risk. Not a scanner: it reads the config or records you give it.
license: MIT + Commons Clause
metadata:
  version: 1.1.0
  author: borghei
  category: compliance
  domain: infrastructure-security
  updated: 2026-06-15
  tags: [infrastructure-audit, cloud-security, dns, tls, compliance-automation]
---
# Infrastructure Compliance Auditor

Cross-cutting infrastructure security audit across ALL compliance frameworks. Replaces manual Vanta-style checks with deterministic, repeatable, evidence-generating infrastructure audits covering cloud, DNS, TLS, endpoints, access control, network, containers, CI/CD, secrets, logging, and physical security. Maps 169 infrastructure controls and 55 access controls to 10 standards (SOC 2, ISO 27001, HIPAA, GDPR, PCI-DSS, NIS2, DORA, NIST CSF, FedRAMP, CCPA) with severity-weighted scoring (heuristic weights).

## Core Capabilities

- **11 audit domains** — cloud (AWS/Azure/GCP), DNS, TLS/SSL, endpoints, access control, network, container/K8s, CI/CD, secrets, logging/monitoring, physical security
- **224 controls** (169 infrastructure, 55 access) — each with a check ID, severity rating, and multi-framework mapping
- **Framework mapping** — collect-evidence-once, map-to-many strategy across 10 standards
- **Deterministic scoring** — severity-weighted share of evaluated controls (0-100). The weights and rating bands are an internal heuristic, not a standard; controls with no data are excluded, never scored as pass or fail
- **Evidence generation** — text, JSON and markdown reports quoting the config value found and the setting to change

## When to Use

Reach for this skill on: "infrastructure audit", "cloud security audit", "infrastructure compliance", "DNS security audit", "TLS audit", "endpoint security", "access control audit", "network security assessment", "infrastructure security", "cloud compliance", "Vanta alternative", "compliance automation", "security posture assessment", "hardware security keys", or "YubiKey compliance".

## Clarify First

Before running the audit, settle the inputs below. When one is missing or vague and would change the result, ask about it; when it wouldn't, use a sensible default and say which one you used.

- **Audit domains:** which of the 11 (cloud, DNS, TLS, endpoints, access, network, container, CI/CD, secrets, logging, physical) are in scope (determines which checks run).
- **Target frameworks:** which standards to map findings to (SOC 2, ISO 27001, HIPAA, PCI-DSS, NIS2…) (drives the control mapping and report).
- **Infrastructure config:** the JSON describing actual state, including cloud provider (AWS/Azure/GCP) (the checks and CIS baseline depend on it).

Ask about the two or three inputs that matter most for this request, not the whole list. If the user wants a result straight away, produce it and state your assumptions at the top.

## Quick Start

All commands run from this skill folder. Build the config first, then audit it.

```bash
# 1. get a config skeleton: one null per control key (null = not provided, not scored)
python3 scripts/infra_audit_runner.py --generate-template --output infrastructure.json
python3 scripts/access_control_auditor.py --generate-template --output access_controls.json

# 2. fill in the real values, then audit
python3 scripts/infra_audit_runner.py infrastructure.json
python3 scripts/infra_audit_runner.py infrastructure.json --frameworks soc2,iso27001 --format markdown --output report.md
python3 scripts/access_control_auditor.py access_controls.json --format json --output access_report.json

# 3. DNS: live lookups with dig, or an offline snapshot of the records
python3 scripts/dns_security_checker.py --domain example.com --subdomains www,api
python3 scripts/dns_security_checker.py --records assets/flawed_dns_records.json --subdomains blog,shop
```

### Real output (excerpt)

`python3 scripts/infra_audit_runner.py assets/flawed_infrastructure.json`

```text
FIX 46 failed controls

Infrastructure compliance audit
Read: 126 controls evaluated, 43 not provided (not scored)
Score: 59.7/100 (Critical; severity-weighted share of evaluated controls, internal heuristic)
Failures: 9 Critical, 34 High, 3 Medium, 0 Low

[Critical] AC-MFA-002 Phishing-resistant MFA for privileged accounts
  Domain: access_control; frameworks: soc2, iso27001, nist_csf, fedramp
  found: access.mfa.phishing_resistant_admins = false (expected true)
  fix: Deploy FIDO2/WebAuthn hardware security keys for all admin accounts. Disable TOTP/SMS fallback for admins.
```

### Exit codes

| Code | Meaning |
|------|---------|
| 0 | Input read, no failed controls (or no failed DNS checks) |
| 1 | At least one failed control; findings printed |
| 2 | Unusable input, one line on stderr: unreadable/empty/invalid JSON, not a JSON object, none of the known keys, unknown `--frameworks` id, invalid domain, `dig` missing, domain does not resolve, DNS lookups failed |

Every command accepts `--format text|json|markdown` (text default; `--json` is an alias) and `--output FILE`.
A missing key or `null` means "not provided": it is reported as skipped, not scored. Boolean strings such as `"false"` are parsed, not treated as truthy.

Samples in `assets/`: `sample_*` exits 0, `flawed_*` exits 1, `malformed_*` exits 2, for each tool; `assets/contract.json` lists the runs.

## Tools

| Tool | Purpose | Input |
|------|---------|-------|
| `infra_audit_runner.py` | Full infrastructure audit across all 11 domains | JSON config describing infrastructure |
| `dns_security_checker.py` | DNS-specific security audit (SPF, DKIM, DMARC, DNSSEC, CAA, MTA-STS) | Domain name (live `dig`) or `--records` JSON snapshot |
| `access_control_auditor.py` | Access control, MFA, SSO, PAM, RBAC audit | JSON config describing access controls |

## References

Load the reference that matches the task — keep this file lean and pull detail on demand:

- **[references/audit-control-catalog.md](references/audit-control-catalog.md)** — the full 250+ control catalog across all 11 audit domains plus the framework coverage matrix. Read when you need exact check IDs, controls, severities, and framework mappings for any domain.
- **[references/audit-workflows.md](references/audit-workflows.md)** — audit workflows, pre/post-audit validation checklists, the severity-weighted scoring methodology, and success criteria. Read when planning or executing an audit and interpreting scores.
- **[references/tool-reference.md](references/tool-reference.md)** — CLI flag reference for the three audit scripts plus a troubleshooting table. Read when running the tools or diagnosing unexpected output.
- **[references/cloud-security-baseline.md](references/cloud-security-baseline.md)** — AWS / Azure / GCP CIS Benchmark deep-dive. Read for cloud-provider hardening detail beyond the catalog.
- **[references/access-control-standards.md](references/access-control-standards.md)** — MFA, SSO, PAM, Zero Trust, and YubiKey implementation standards. Read when designing identity and access controls.
- **[references/compliance-framework-mapping.md](references/compliance-framework-mapping.md)** — control-to-framework master mapping. Read when aligning evidence across multiple certifications.

## Scope & Limitations

**In Scope:**
- Infrastructure security audit across 11 domains: Cloud, DNS, TLS/SSL, Endpoints, Access Control, Network, Containers/K8s, CI/CD, Secrets, Logging/Monitoring, Physical Security
- Framework mapping to 10 compliance standards: SOC 2, ISO 27001, HIPAA, GDPR, PCI-DSS, NIS2, DORA, NIST CSF, FedRAMP, CCPA
- 224 individual control checks with severity-weighted scoring (heuristic weights)
- DNS security validation including SPF, DKIM, DMARC, DNSSEC, CAA, MTA-STS, and subdomain takeover risk
- Access control audit covering IdP, SSO, MFA, FIDO2/hardware keys, PAM, RBAC, service accounts, SSH keys, API keys, and Zero Trust
- Evidence-generating reports in JSON and markdown formats for auditor consumption

**Out of Scope:**
- Actual penetration testing, vulnerability scanning, or active exploitation -- this skill performs configuration-based assessment, not active testing
- Cloud provider API calls or live infrastructure scanning -- the tools read the JSON you supply; the only network use is `dig` DNS lookups in live DNS mode
- Compliance certification or attestation -- this skill identifies gaps but does not replace formal SOC 2, ISO 27001, or PCI-DSS audits
- Application security testing (SAST/DAST) beyond CI/CD pipeline configuration checks
- Compliance program management, policy writing, or governance documentation

**Important Notes:**
- Zero Trust architecture is increasingly expected across all frameworks; perimeter-based security alone is insufficient for SOC 2, ISO 27001, and NIS2
- Compliance automation platforms (Drata, Vanta, Sprinto) complement but do not replace the deterministic checks this tool provides

## Integration Points

| Skill | Integration | When to Use |
|-------|-------------|-------------|
| `soc2-compliance-expert` | SOC 2 Trust Services Criteria mapped to infrastructure controls; evidence collection for SOC 2 Type II | When infrastructure audit supports SOC 2 certification |
| `information-security-manager-iso27001` | ISO 27001 Annex A technological controls validated by infrastructure checks | When ISO 27001 certification requires evidence of technical control implementation |
| `nist-csf-specialist` | NIST CSF 2.0 Protect and Detect functions mapped to infrastructure domains | When building unified security posture across NIST and other frameworks |
| `dora-compliance-expert` | DORA Pillar 1 and Pillar 3 controls validated by infrastructure security checks | When financial entity requires infrastructure evidence for DORA compliance |
| `pci-dss-specialist` | PCI-DSS v4.0 network security, encryption, and access control requirements mapped to checks | When cardholder data environment requires infrastructure compliance validation |
| `gdpr-dsgvo-expert` | Technical privacy controls (encryption, access controls, data masking) supporting GDPR Art. 32 | When infrastructure controls support personal data protection requirements |

Files in this skill

  • SKILL.md73.6 KB
  • references/access-control-standards.md21.2 KB
  • references/cloud-security-baseline.md15.4 KB
  • references/compliance-framework-mapping.md19.3 KB
  • scripts/access_control_auditor.py36.3 KB
  • scripts/dns_security_checker.py37.5 KB
  • scripts/infra_audit_runner.py59.7 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.