Pentest Validation
Quality Gates:
- Authorization confirmed before ANY exploitation
- Target URL is staging/dev (NOT production)
- Budget cap enforced ($15 default)
- Time cap enforced (30 min default)
- All exploitation attempts logged
Quick Reference Card
The 4-Phase Pipeline
| Phase |
Agent(s) |
Purpose |
Parallelism |
| 1. Recon |
qe-security-scanner |
SAST, DAST, dependency scan, secrets |
Internal parallel |
| 2. Analysis |
qe-security-reviewer + qe-security-auditor |
Code review + compliance check |
Both in parallel |
| 3. Validation |
qe-pentest-validator |
Graduated exploit validation |
Per-vuln-type parallel |
| 4. Report |
qe-quality-gate |
"No Exploit, No Report" filter |
Sequential |
Graduated Exploitation Tiers
| Tier |
Handler |
Cost |
Latency |
Use When |
| 1 |
Agent Booster (WASM) |
$0 |
<1ms |
Code pattern is conclusive (eval, innerHTML, hardcoded creds) |
| 2 |
Haiku |
$0.0002 |
~500ms |
Need payload test against live target |
| 3 |
Sonnet/Opus |
$0.003-$0.015 |
2-5s |
Full exploit chain with data proof |
When to Use This Skill
| Scenario |
Tier |
Estimated Cost |
| PR security review (source only) |
1 |
$0 |
| Pre-release validation (staging) |
1-2 |
$1-5 |
| Full pentest validation |
1-3 |
$5-15 |
| Compliance audit evidence |
1-3 |
$5-15 |
Configuration
pentest:
target_url: https://staging.app.com # REQUIRED for Tier 2-3
source_repo: ./src # REQUIRED for Tier 1+
exploitation_tier: 2 # 1=pattern-only, 2=payload-test, 3=full-exploit
vuln_types: # Which pipelines to run
- injection # SQL, NoSQL, command injection
- xss # Reflected, stored, DOM XSS
- auth # Auth bypass, session, JWT
- ssrf # URL scheme abuse, metadata
max_cost_usd: 15 # Budget cap per run
timeout_minutes: 30 # Time cap per run
require_authorization: true # MUST confirm target ownership
no_production: true # Block production URLs
production_patterns: # URL patterns to block
- "*.prod.*"
- "api.*"
- "www.*"
Safeguards (Mandatory)
Authorization Gate
Every pentest validation run MUST:
- Display target URL and exploitation tier to user
- Require explicit confirmation: "I own/authorized testing of this target"
- Log authorization with timestamp
- Block if target URL matches production patterns
What This Skill Does NOT Do
- Full autonomous reconnaissance (Nmap, Subfinder)
- Zero-day exploit development
- Attack targets without explicit authorization
- Test production systems
- Store actual exfiltrated data (only proof of access)
- Social engineering or phishing simulation
- Port scanning or service discovery
Validation Pipelines
Injection Pipeline
| Attack |
Tier 1 (Pattern) |
Tier 2 (Payload) |
Tier 3 (Full) |
| SQL injection |
String concat in query |
' OR '1'='1 response diff |
UNION SELECT data extraction |
| NoSQL injection |
$where, $gt in query |
Operator injection test |
Collection enumeration |
| Command injection |
exec(), system() calls |
Command delimiter test |
Reverse shell proof |
| LDAP injection |
String concat in filter |
Wildcard injection |
Directory enumeration |
XSS Pipeline
| Attack |
Tier 1 (Pattern) |
Tier 2 (Payload) |
Tier 3 (Full) |
| Reflected XSS |
No output encoding |
<img onerror> reflection |
Browser JS execution via Playwright |
| Stored XSS |
innerHTML assignment |
Payload stored + retrieved |
Cookie theft PoC |
| DOM XSS |
document.write(location) |
Fragment injection |
DOM manipulation proof |
Auth Pipeline
| Attack |
Tier 1 (Pattern) |
Tier 2 (Payload) |
Tier 3 (Full) |
| JWT none |
No algorithm validation |
Modified JWT accepted |
Admin access with forged token |
| Session fixation |
No session rotation |
Pre-set session reused |
Cross-user session hijack |
| Credential stuffing |
No rate limiting |
100 attempts unblocked |
Valid credential discovery |
| IDOR |
No authorization check |
Access other user data |
Full CRUD on foreign resources |
SSRF Pipeline
| Attack |
Tier 1 (Pattern) |
Tier 2 (Payload) |
Tier 3 (Full) |
| Internal URL |
User-controlled URL fetch |
http://169.254.169.254 |
Cloud metadata extraction |
| DNS rebinding |
URL validation bypass |
Rebind to internal IP |
Internal service access |
| Protocol smuggling |
URL scheme not restricted |
file:///etc/passwd |
File content in response |
Agent Coordination
Orchestration Pattern
// Phase 1: Recon (parallel scans)
await Task("Security Scan", {
target: "./src",
layers: { sast: true, dast: true, dependencies: true, secrets: true }
}, "qe-security-scanner");
// Phase 2: Analysis (parallel review)
await Promise.all([
Task("Code Security Review", {
findings: phase1Results,
depth: "comprehensive"
}, "qe-security-reviewer"),
Task("Compliance Audit", {
findings: phase1Results,
frameworks: ["owasp-top-10"]
}, "qe-security-auditor")
]);
// Phase 3: Validation (graduated exploitation)
await Task("Exploit Validation", {
findings: [...phase1Results, ...phase2Results],
target_url: "https://staging.app.com",
exploitation_tier: 2,
vuln_types: ["injection", "xss", "auth", "ssrf"],
max_cost_usd: 15,
timeout_minutes: 30
}, "qe-pentest-validator");
// Phase 4: Report ("No Exploit, No Report" gate)
await Task("Security Quality Gate", {
findings: phase3Results.confirmedFindings,
gate: "no-exploit-no-report",
require_poc: true
}, "qe-quality-gate");
Finding Classification
| Status |
Meaning |
Action |
confirmed-exploitable |
Exploitation succeeded with PoC |
Report with evidence |
likely-exploitable |
Partial exploitation, defenses detected |
Report with caveats |
not-exploitable |
All exploitation attempts failed |
Filter from report |
inconclusive |
WAF/defense blocked, unclear if vulnerable |
Report for manual review |
Exploit Playbook Memory
Namespace Structure
aqe/pentest/
playbook/
exploit/{vuln_type}/{tech_stack}/{technique}
bypass/{defense_type}/{technique}
payload/{vuln_type}/{variant}
results/
validation-{timestamp}
poc/
{finding_id}-poc
Learning Loop
- Before validation: Query playbook for known patterns matching findings
- During validation: Try known payloads first (higher success rate)
- After validation: Store new successful patterns with confidence scores
- Over time: Agent converges on most effective payloads per tech stack
Cost Optimization
Estimated Cost by Scenario
| Scenario |
Tier Mix |
Findings |
Est. Cost |
Est. Time |
| PR check (source only) |
100% Tier 1 |
5 |
$0 |
<5s |
| Sprint validation |
70% T1, 30% T2 |
15 |
$2-5 |
5-10 min |
| Release validation |
40% T1, 40% T2, 20% T3 |
25 |
$8-15 |
15-30 min |
| Full pentest |
20% T1, 30% T2, 50% T3 |
40 |
$15-30 |
30-60 min |
Cost vs Shannon Comparison
| Metric |
Shannon |
AQE Pentest Validation |
| Cost per run |
~$50 |
$5-15 (graduated tiers) |
| Runtime |
60-90 min |
15-30 min (parallel pipelines) |
| False positive rate |
Low (exploit-proven) |
Low (same principle) |
| Learning |
None (static prompts) |
ReasoningBank playbook |
Success Metrics
| Metric |
Target |
Measurement |
| False positive reduction |
>60% of findings eliminated |
Pre/post validator comparison |
| Exploit confirmation rate |
>80% of confirmed findings truly exploitable |
Manual PoC verification |
| Cost per run |
<$15 USD |
Token tracking per pipeline |
| Time per run |
<30 minutes |
Execution time metrics |
| Playbook growth |
100+ patterns after 6 months |
Memory namespace count |
Related Skills
Remember
"No Exploit, No Report." A vulnerability scanner that can't prove exploitation delivers uncertain value. This skill transforms security findings from theoretical risks into proven vulnerabilities with evidence. Every confirmed finding comes with a reproducible proof-of-concept. Every false positive is eliminated before it reaches the report.
Think proof, not prediction. Don't report what MIGHT be vulnerable. Prove what IS vulnerable.
1---
2inclusion: auto
3name: qe-pentest-validation
4description: "Orchestrate security finding validation through graduated exploitation. 4-phase pipeline: recon (SAST/DAST), analysis (code review), validation (exploit proof), report (No Exploit, No Report gate). Eliminates false positives by proving exploitability."
5tags: [pentest, exploitation, security-validation, shannon, no-exploit-no-report, graduated-exploitation]
6---
7
8# Pentest Validation
9
10<default_to_action>
11When validating security findings:
121. REQUIRE explicit authorization for target URL
132. SCAN with qe-security-scanner (SAST + dependency + secrets)
143. ANALYZE with qe-security-reviewer + qe-security-auditor (parallel)
154. VALIDATE with qe-pentest-validator (graduated exploitation, parallel per vuln type)
165. REPORT only confirmed findings with PoC evidence ("No Exploit, No Report")
176. UPDATE exploit playbook with new patterns
18
19**Quality Gates:**
20- Authorization confirmed before ANY exploitation
21- Target URL is staging/dev (NOT production)
22- Budget cap enforced ($15 default)
23- Time cap enforced (30 min default)
24- All exploitation attempts logged
25</default_to_action>
26
27## Quick Reference Card
28
29### The 4-Phase Pipeline
30
31| Phase | Agent(s) | Purpose | Parallelism |
32|-------|----------|---------|-------------|
33| **1. Recon** | qe-security-scanner | SAST, DAST, dependency scan, secrets | Internal parallel |
34| **2. Analysis** | qe-security-reviewer + qe-security-auditor | Code review + compliance check | Both in parallel |
35| **3. Validation** | qe-pentest-validator | Graduated exploit validation | Per-vuln-type parallel |
36| **4. Report** | qe-quality-gate | "No Exploit, No Report" filter | Sequential |
37
38### Graduated Exploitation Tiers
39
40| Tier | Handler | Cost | Latency | Use When |
41|------|---------|------|---------|----------|
42| **1** | Agent Booster (WASM) | $0 | <1ms | Code pattern is conclusive (eval, innerHTML, hardcoded creds) |
43| **2** | Haiku | $0.0002 | ~500ms | Need payload test against live target |
44| **3** | Sonnet/Opus | $0.003-$0.015 | 2-5s | Full exploit chain with data proof |
45
46### When to Use This Skill
47
48| Scenario | Tier | Estimated Cost |
49|----------|------|----------------|
50| PR security review (source only) | 1 | $0 |
51| Pre-release validation (staging) | 1-2 | $1-5 |
52| Full pentest validation | 1-3 | $5-15 |
53| Compliance audit evidence | 1-3 | $5-15 |
54
55---
56
57## Configuration
58
59```yaml
60pentest:
61 target_url: https://staging.app.com # REQUIRED for Tier 2-3
62 source_repo: ./src # REQUIRED for Tier 1+
63 exploitation_tier: 2 # 1=pattern-only, 2=payload-test, 3=full-exploit
64 vuln_types: # Which pipelines to run
65 - injection # SQL, NoSQL, command injection
66 - xss # Reflected, stored, DOM XSS
67 - auth # Auth bypass, session, JWT
68 - ssrf # URL scheme abuse, metadata
69 max_cost_usd: 15 # Budget cap per run
70 timeout_minutes: 30 # Time cap per run
71 require_authorization: true # MUST confirm target ownership
72 no_production: true # Block production URLs
73 production_patterns: # URL patterns to block
74 - "*.prod.*"
75 - "api.*"
76 - "www.*"
77```
78
79---
80
81## Safeguards (Mandatory)
82
83### Authorization Gate
84Every pentest validation run MUST:
851. Display target URL and exploitation tier to user
862. Require explicit confirmation: "I own/authorized testing of this target"
873. Log authorization with timestamp
884. Block if target URL matches production patterns
89
90### What This Skill Does NOT Do
91- Full autonomous reconnaissance (Nmap, Subfinder)
92- Zero-day exploit development
93- Attack targets without explicit authorization
94- Test production systems
95- Store actual exfiltrated data (only proof of access)
96- Social engineering or phishing simulation
97- Port scanning or service discovery
98
99---
100
101## Validation Pipelines
102
103### Injection Pipeline
104| Attack | Tier 1 (Pattern) | Tier 2 (Payload) | Tier 3 (Full) |
105|--------|-------------------|-------------------|----------------|
106| SQL injection | String concat in query | `' OR '1'='1` response diff | UNION SELECT data extraction |
107| NoSQL injection | `$where`, `$gt` in query | Operator injection test | Collection enumeration |
108| Command injection | `exec()`, `system()` calls | Command delimiter test | Reverse shell proof |
109| LDAP injection | String concat in filter | Wildcard injection | Directory enumeration |
110
111### XSS Pipeline
112| Attack | Tier 1 (Pattern) | Tier 2 (Payload) | Tier 3 (Full) |
113|--------|-------------------|-------------------|----------------|
114| Reflected XSS | No output encoding | `<img onerror>` reflection | Browser JS execution via Playwright |
115| Stored XSS | `innerHTML` assignment | Payload stored + retrieved | Cookie theft PoC |
116| DOM XSS | `document.write(location)` | Fragment injection | DOM manipulation proof |
117
118### Auth Pipeline
119| Attack | Tier 1 (Pattern) | Tier 2 (Payload) | Tier 3 (Full) |
120|--------|-------------------|-------------------|----------------|
121| JWT none | No algorithm validation | Modified JWT accepted | Admin access with forged token |
122| Session fixation | No session rotation | Pre-set session reused | Cross-user session hijack |
123| Credential stuffing | No rate limiting | 100 attempts unblocked | Valid credential discovery |
124| IDOR | No authorization check | Access other user data | Full CRUD on foreign resources |
125
126### SSRF Pipeline
127| Attack | Tier 1 (Pattern) | Tier 2 (Payload) | Tier 3 (Full) |
128|--------|-------------------|-------------------|----------------|
129| Internal URL | User-controlled URL fetch | `http://169.254.169.254` | Cloud metadata extraction |
130| DNS rebinding | URL validation bypass | Rebind to internal IP | Internal service access |
131| Protocol smuggling | URL scheme not restricted | `file:///etc/passwd` | File content in response |
132
133---
134
135## Agent Coordination
136
137### Orchestration Pattern
138```typescript
139// Phase 1: Recon (parallel scans)
140await Task("Security Scan", {
141 target: "./src",
142 layers: { sast: true, dast: true, dependencies: true, secrets: true }
143}, "qe-security-scanner");
144
145// Phase 2: Analysis (parallel review)
146await Promise.all([
147 Task("Code Security Review", {
148 findings: phase1Results,
149 depth: "comprehensive"
150 }, "qe-security-reviewer"),
151
152 Task("Compliance Audit", {
153 findings: phase1Results,
154 frameworks: ["owasp-top-10"]
155 }, "qe-security-auditor")
156]);
157
158// Phase 3: Validation (graduated exploitation)
159await Task("Exploit Validation", {
160 findings: [...phase1Results, ...phase2Results],
161 target_url: "https://staging.app.com",
162 exploitation_tier: 2,
163 vuln_types: ["injection", "xss", "auth", "ssrf"],
164 max_cost_usd: 15,
165 timeout_minutes: 30
166}, "qe-pentest-validator");
167
168// Phase 4: Report ("No Exploit, No Report" gate)
169await Task("Security Quality Gate", {
170 findings: phase3Results.confirmedFindings,
171 gate: "no-exploit-no-report",
172 require_poc: true
173}, "qe-quality-gate");
174```
175
176### Finding Classification
177| Status | Meaning | Action |
178|--------|---------|--------|
179| `confirmed-exploitable` | Exploitation succeeded with PoC | Report with evidence |
180| `likely-exploitable` | Partial exploitation, defenses detected | Report with caveats |
181| `not-exploitable` | All exploitation attempts failed | Filter from report |
182| `inconclusive` | WAF/defense blocked, unclear if vulnerable | Report for manual review |
183
184---
185
186## Exploit Playbook Memory
187
188### Namespace Structure
189```
190aqe/pentest/
191 playbook/
192 exploit/{vuln_type}/{tech_stack}/{technique}
193 bypass/{defense_type}/{technique}
194 payload/{vuln_type}/{variant}
195 results/
196 validation-{timestamp}
197 poc/
198 {finding_id}-poc
199```
200
201### Learning Loop
2021. **Before validation**: Query playbook for known patterns matching findings
2032. **During validation**: Try known payloads first (higher success rate)
2043. **After validation**: Store new successful patterns with confidence scores
2054. **Over time**: Agent converges on most effective payloads per tech stack
206
207---
208
209## Cost Optimization
210
211### Estimated Cost by Scenario
212| Scenario | Tier Mix | Findings | Est. Cost | Est. Time |
213|----------|----------|----------|-----------|-----------|
214| PR check (source only) | 100% Tier 1 | 5 | $0 | <5s |
215| Sprint validation | 70% T1, 30% T2 | 15 | $2-5 | 5-10 min |
216| Release validation | 40% T1, 40% T2, 20% T3 | 25 | $8-15 | 15-30 min |
217| Full pentest | 20% T1, 30% T2, 50% T3 | 40 | $15-30 | 30-60 min |
218
219### Cost vs Shannon Comparison
220| Metric | Shannon | AQE Pentest Validation |
221|--------|---------|----------------------|
222| Cost per run | ~$50 | $5-15 (graduated tiers) |
223| Runtime | 60-90 min | 15-30 min (parallel pipelines) |
224| False positive rate | Low (exploit-proven) | Low (same principle) |
225| Learning | None (static prompts) | ReasoningBank playbook |
226
227---
228
229## Success Metrics
230
231| Metric | Target | Measurement |
232|--------|--------|-------------|
233| False positive reduction | >60% of findings eliminated | Pre/post validator comparison |
234| Exploit confirmation rate | >80% of confirmed findings truly exploitable | Manual PoC verification |
235| Cost per run | <$15 USD | Token tracking per pipeline |
236| Time per run | <30 minutes | Execution time metrics |
237| Playbook growth | 100+ patterns after 6 months | Memory namespace count |
238
239---
240
241## Related Skills
242
243- [security-testing](../security-testing/) - OWASP vulnerability scanning
244- [qe-security-compliance](../qe-security-compliance/) - SAST/DAST automation
245- [compliance-testing](../compliance-testing/) - Regulatory compliance
246- [api-testing-patterns](../api-testing-patterns/) - API security testing
247- [chaos-engineering-resilience](../chaos-engineering-resilience/) - Security under chaos
248
249---
250
251## Remember
252
253**"No Exploit, No Report."** A vulnerability scanner that can't prove exploitation delivers uncertain value. This skill transforms security findings from theoretical risks into proven vulnerabilities with evidence. Every confirmed finding comes with a reproducible proof-of-concept. Every false positive is eliminated before it reaches the report.
254
255**Think proof, not prediction.** Don't report what MIGHT be vulnerable. Prove what IS vulnerable.