Full-stack security audit for Web, Mobile, Backend, IaC, Compliance, LLM/AI. OWASP Top 10:2025, MASVS v2, CIS Benchmarks, PCI-DSS, GDPR. CLI + Chrome MCP. Triggered by "security audit", "vulnerability scan", "pentest".
Full-stack vulnerability assessment skill covering Application, Infrastructure, Backend, Mobile, Compliance, and Advanced Detection. Combines codebase static analysis, CLI/SQL configuration checks, and Chrome MCP dashboard inspection to audit all layers end-to-end.
code-reviewer agent for general code quality.When evaluating findings, reject these false-positive rationalizations:
Chrome MCP inspection requires a browser with active login sessions. Before running targets that include dashboard checks (vercel, supabase, web, all):
https://vercel.com/dashboardhttps://supabase.com/dashboardIf Chrome MCP is unavailable, the audit proceeds with CLI/code-only checks and flags skipped dashboard items.
The audit runs in two stages to work around subagent tool limitations:
Phases 1-8 code/config checks use Grep, Glob, Bash, Read — tools available to all agent types. These can be parallelized across multiple subagents:
[Main Context] Orchestrator
├── [Subagent A] Web Application Audit (Grep, Bash)
├── [Subagent B] Backend Audit (Grep, Bash)
├── [Subagent C] Mobile Audit (Grep, Bash)
├── [Subagent D] IaC / Compliance / Advanced (Grep, Bash)
└── [Main Context] Cross-Layer Analysis (synthesize subagent results)
Chrome MCP tools (mcp__chrome-devtools__*) are only available in the main context, not in subagents. Dashboard inspection MUST run in the main orchestrator:
[Main Context] Chrome MCP Inspection
├── Navigate to Vercel Dashboard → take_screenshot → inspect settings
├── Navigate to Supabase Dashboard → take_screenshot → inspect settings
└── Compile dashboard findings with manual remediation steps
Important: Never delegate Chrome MCP checks to subagents — they will silently skip them. The main orchestrator must execute all mcp__chrome-devtools__* calls directly.
When findings exceed 10 items or span 3+ layers, pause and ask the user:
"Found X findings (Critical: N / High: N / Medium: N / Low: N). Would you like to generate a report file?"
security-audit-report-YYYY-MM-DD.md in the project rootDashboard settings found via Chrome MCP cannot be fixed by CLI or code changes. For each dashboard finding, include:
Example format in report:
### [HIGH-003] Vercel Deployment Protection Disabled
- **Current Value**: Deployment Protection = OFF
- **Recommended Value**: Deployment Protection = Vercel Authentication
- **Manual Remediation Steps**:
1. Vercel Dashboard → Project Settings → Deployment Protection
2. Select "Standard Protection"
3. Enable "Vercel Authentication"
4. Verify protection level for Preview Deployments
5. Click "Save"
- **Impact**: Public access to Preview URLs will be restricted. Sharing with external stakeholders requires configuring Shareable Links.
/security-audit -> Interactive target selection
/security-audit all -> Full-stack end-to-end audit (recommended)
/security-audit nextjs -> Next.js application only
/security-audit vercel -> Vercel infrastructure only
/security-audit supabase -> Supabase backend only
/security-audit ios -> iOS app only
/security-audit android -> Android app only
/security-audit flutter -> Flutter app only
/security-audit react-native -> React Native app only
/security-audit mobile -> All mobile platforms (iOS + Android + Flutter + RN)
/security-audit web -> Next.js + Vercel + Supabase (full web stack)
/security-audit python -> Python (Django/FastAPI/Flask)
/security-audit go -> Go
/security-audit rails -> Ruby on Rails
/security-audit rust -> Rust
/security-audit backend -> All backend frameworks
/security-audit terraform -> Terraform IaC
/security-audit aws -> AWS infrastructure
/security-audit gcp -> GCP infrastructure
/security-audit azure -> Azure infrastructure
/security-audit iac -> All IaC (Terraform + AWS + GCP + Azure)
/security-audit compliance -> PCI-DSS, HIPAA, SOX, GDPR, CCPA, SOC2, ISO27001
/security-audit supply-chain -> Supply chain and dependency security
/security-audit container -> Container and Kubernetes security
/security-audit cicd -> CI/CD pipeline security
/security-audit secrets -> Secret scanning (git history + code)
/security-audit llm -> LLM/AI security (OWASP Top 10 for LLM)
/security-audit advanced -> All advanced detection
Understand the target codebase structure.
references/nextjs-security.md| Priority | Check | Method |
|---|---|---|
| Critical | Server Actions auth/authz/validation | Grep |
| Critical | Next.js version CVE assessment | Bash |
| Critical | NEXT_PUBLIC_ secret exposure | Grep |
| High | Middleware bypass resistance | Grep |
| High | Image optimization SSRF (remotePatterns) | Grep |
| High | CSP and security headers | Grep |
| Medium | Server/Client Component data leakage | Grep |
references/web-testing.mdreferences/vercel-security.md| Priority | Check | Method |
|---|---|---|
| Critical | Environment variable secret exposure | CLI |
| High | Deployment Protection settings | Chrome MCP |
| High | Git Fork Protection | Chrome MCP |
| Medium | Firewall / WAF rules | Chrome MCP |
references/supabase-security.md| Priority | Check | Method |
|---|---|---|
| Critical | RLS enabled on all public tables | SQL |
| Critical | service_role key client exposure | Grep |
| Critical | Overly permissive RLS policies | SQL |
| High | SECURITY DEFINER functions | SQL |
| High | Auth settings (MFA, email confirm) | Chrome MCP |
references/terraform-security.mdreferences/aws-security.mdreferences/gcp-security.mdreferences/azure-security.mdreferences/python-security.md| Priority | Check | Method |
|---|---|---|
| Critical | SQL Injection (raw queries, ORM misuse) | Grep |
| Critical | Command Injection detection | Grep |
| Critical | Insecure deserialization detection | Grep |
| High | Django DEBUG/SECRET_KEY/ALLOWED_HOSTS | Grep |
| High | SSTI (template injection) | Grep |
| Medium | CSRF configuration | Grep |
references/go-security.mdreferences/rails-security.mdreferences/rust-security.mdreferences/ios-testing.md| Priority | Check | Method |
|---|---|---|
| Critical | Keychain access attributes | Grep |
| Critical | ATS config and Certificate Pinning | Grep + Bash |
| Critical | Biometric authentication | Grep |
| High | NSUserDefaults sensitive data | Grep |
| High | WebView security | Grep |
references/android-security.md| Priority | Check | Method |
|---|---|---|
| Critical | SharedPreferences sensitive data | Grep |
| Critical | Network Security Config | Grep |
| Critical | Exported components | Grep |
| High | WebView JavaScript enabled | Grep |
| High | Root/emulator detection | Grep |
references/flutter-security.mdreferences/react-native-security.mdreferences/compliance-financial.md| Priority | Check | Method |
|---|---|---|
| Critical | PAN/credit card data in code | Grep |
| Critical | PHI field exposure | Grep |
| High | Encryption at rest/in transit | Grep |
| High | Audit logging implementation | Grep |
| Medium | Access control / RBAC | Grep |
references/compliance-privacy.md| Priority | Check | Method |
|---|---|---|
| Critical | PII field identification | Grep |
| Critical | Consent management | Grep |
| High | Data retention policies | Grep |
| High | Right to erasure implementation | Grep |
| Medium | Data classification | Grep |
references/supply-chain-security.mdreferences/container-security.mdreferences/cicd-security.mdreferences/secret-scanning.mdreferences/llm-security.md| Priority | Check | Method |
|---|---|---|
| Critical | Hardcoded secrets in code/history | Grep + Bash |
| Critical | Prompt injection vulnerabilities | Grep |
| Critical | Container running as root | Grep |
| High | GitHub Actions unpinned actions | Grep |
| High | Dependency confusion risk | Grep + Bash |
| High | Kubernetes RBAC misconfig | Grep |
| Medium | SBOM generation | Bash |
Evaluate threats that span multiple layers.
# Full-Stack Security Audit Report
**Target**: [project name]
**Date**: [YYYY-MM-DD]
**Scope**: [selected targets]
## Executive Summary
- Critical: X / High: Y / Medium: Z / Low: W
- Top priority: [one-line summary]
## Layer Summary
| Layer | Critical | High | Medium | Low |
|--------------|----------|------|--------|-----|
| Web App | X | X | X | X |
| Infrastructure | X | X | X | X |
| Backend | X | X | X | X |
| Mobile | X | X | X | X |
| Compliance | X | X | X | X |
| Advanced | X | X | X | X |
| Cross-Layer | X | X | X | X |
## Findings
### Code/Config Findings
### [CRITICAL-001] [vulnerability title]
- **Layer**: [Web / Infrastructure / Backend / Mobile / Compliance / Advanced / Cross-layer]
- **Category**: OWASP [A01/MASVS-STORAGE/CIS/PCI-DSS/etc.]
- **Location**: `file_path:line_number`
- **Description**: What the vulnerability is
- **Impact**: What happens if exploited
- **Remediation**: diff-format code fix
### Dashboard Findings (Manual Remediation Required)
### [HIGH-XXX] [dashboard setting title]
- **Layer**: [Vercel / Supabase / AWS Console / GCP Console / Azure Portal]
- **Category**: [Configuration / Access Control / Encryption / etc.]
- **Current Value**: [value observed via Chrome MCP]
- **Recommended Value**: [security-recommended value]
- **Manual Remediation Steps**:
1. [Dashboard URL / screen path]
2. [Specific action steps]
3. [Save / apply instructions]
- **Impact**: [Side effects on existing functionality]
## Remediation Roadmap
| Priority | Action | Layer | Type |
|----------|--------|-------|------|
| Immediate | Fix Critical vulnerabilities | - | Code |
| Immediate | Fix Critical dashboard settings | - | Manual |
| Short-term | Fix High vulnerabilities | - | Code |
| Short-term | Fix High dashboard settings | - | Manual |
| Mid-term | Architecture improvements | - | Code |
| Tool | Purpose |
|---|---|
| Grep/Glob | Static pattern detection in code |
| Bash | CLI commands (npm audit, pip-audit, cargo-audit, etc.) |
| Bash (SQL) | Direct Supabase DB queries (RLS status, etc.) |
| Bash (Cloud CLI) | AWS CLI, gcloud, az commands for infrastructure audit |
| Chrome MCP | Vercel/Supabase dashboard settings inspection |
| security-reviewer agent | OWASP Top 10 code review |
| security role | Threat modeling, CVE correlation |
| WebSearch | Latest CVE/advisory lookup |