coverme-scanner 1.6.0 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli/index.js +2 -3
- package/dist/cli/index.js.map +1 -1
- package/dist/prompts/orchestration.md +258 -47
- package/dist/report/generator.d.ts +84 -17
- package/dist/report/generator.d.ts.map +1 -1
- package/dist/report/generator.js +166 -321
- package/dist/report/generator.js.map +1 -1
- package/dist/report/index.d.ts +3 -3
- package/dist/report/index.d.ts.map +1 -1
- package/dist/report/index.js +76 -14
- package/dist/report/index.js.map +1 -1
- package/dist/templates/report.html +1661 -528
- package/dist/types.d.ts +70 -5
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -2
- package/dist/templates/report-pdf.html +0 -1497
package/dist/cli/index.js
CHANGED
|
@@ -32,10 +32,9 @@ program
|
|
|
32
32
|
.action(scan_js_1.scan);
|
|
33
33
|
program
|
|
34
34
|
.command('report')
|
|
35
|
-
.description('Generate
|
|
35
|
+
.description('Generate HTML report from scan JSON')
|
|
36
36
|
.argument('[json-file]', 'Path to scan results JSON file (auto-detects if not provided)')
|
|
37
37
|
.option('-o, --output <path>', 'Output file path')
|
|
38
|
-
.option('-f, --format <format>', 'Output format: pdf, html', 'pdf')
|
|
39
38
|
.action(async (jsonFile, options) => {
|
|
40
39
|
let targetFile = jsonFile;
|
|
41
40
|
// Auto-detect scan.json if not provided
|
|
@@ -67,7 +66,7 @@ program
|
|
|
67
66
|
process.exit(1);
|
|
68
67
|
}
|
|
69
68
|
}
|
|
70
|
-
await (0, index_js_1.generateReport)(targetFile, options.output
|
|
69
|
+
await (0, index_js_1.generateReport)(targetFile, options.output);
|
|
71
70
|
});
|
|
72
71
|
// Agent management commands
|
|
73
72
|
const agentCmd = program
|
package/dist/cli/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":";;;AAEA,y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AAO,CAAC,KAAK,CAAC,6BAA6B,CAAC,CAAC;QAC7C,OAAO;IACT,CAAC;IAED,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,IAAA,iBAAY,EAAC,UAAU,EAAE,OAAO,CAAC,CAAC,CAAC;IAC7D,MAAM,GAAG,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,CAAC,CAAM,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,EAAE,KAAK,IAAI,CAAC,WAAW,EAAE,CAAC,CAAC;IAEnG,IAAI,GAAG,KAAK,CAAC,CAAC,EAAE,CAAC;QACf,OAAO,CAAC,KAAK,CAAC,gBAAgB,IAAI,aAAa,CAAC,CAAC;QACjD,OAAO;IACT,CAAC;IAED,MAAM,OAAO,GAAG,MAAM,CAAC,YAAY,CAAC,MAAM,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IACtD,IAAA,kBAAa,EAAC,UAAU,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;IAC3D,OAAO,CAAC,GAAG,CAAC,wBAAwB,OAAO,CAAC,IAAI,GAAG,CAAC,CAAC;AACvD,CAAC,CAAC,CAAC;AAEL,OAAO,CAAC,KAAK,EAAE,CAAC"}
|
|
@@ -13,14 +13,17 @@ Before scanning, understand what you're scanning and gather statistics:
|
|
|
13
13
|
### Step 1: Gather Project Statistics
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
|
+
# List ALL top-level directories (excluding hidden, node_modules, dist, build)
|
|
17
|
+
ls -d */ 2>/dev/null | grep -v -E '^(node_modules|dist|build|\.)/
|
|
18
|
+
|
|
16
19
|
# Count files and lines of code
|
|
17
20
|
find . -type f \( -name "*.ts" -o -name "*.js" -o -name "*.tsx" -o -name "*.jsx" -o -name "*.py" -o -name "*.go" -o -name "*.java" -o -name "*.rb" -o -name "*.php" -o -name "*.cs" -o -name "*.swift" -o -name "*.kt" \) -not -path "*/node_modules/*" -not -path "*/.git/*" -not -path "*/dist/*" -not -path "*/build/*" -not -path "*/__pycache__/*" | wc -l
|
|
18
21
|
|
|
19
22
|
# Count lines of code (approximate)
|
|
20
23
|
find . -type f \( -name "*.ts" -o -name "*.js" -o -name "*.tsx" -o -name "*.jsx" -o -name "*.py" -o -name "*.go" \) -not -path "*/node_modules/*" -not -path "*/.git/*" -not -path "*/dist/*" 2>/dev/null | head -100 | xargs wc -l 2>/dev/null | tail -1
|
|
21
24
|
|
|
22
|
-
# Generate project tree (
|
|
23
|
-
find . -maxdepth
|
|
25
|
+
# Generate project tree (2 levels deep)
|
|
26
|
+
find . -maxdepth 2 -type d -not -path "*/node_modules/*" -not -path "*/.git/*" -not -path "*/dist/*" -not -path "*/__pycache__/*" -not -path "*/build/*" | sort
|
|
24
27
|
```
|
|
25
28
|
|
|
26
29
|
### Step 2: Read Project Info
|
|
@@ -47,7 +50,7 @@ Include these statistics in the final report:
|
|
|
47
50
|
"stack": ["Node.js", "TypeScript", "React", "PostgreSQL", "Redis"],
|
|
48
51
|
"purpose": "1-2 sentence description of what this project does",
|
|
49
52
|
"architecture": "Monolith | Microservices | Serverless | Hybrid",
|
|
50
|
-
"keyComponents": ["
|
|
53
|
+
"keyComponents": ["backend-api/", "frontend/", "services/", "packages/", "etc"]
|
|
51
54
|
}
|
|
52
55
|
}
|
|
53
56
|
```
|
|
@@ -56,10 +59,43 @@ Include these statistics in the final report:
|
|
|
56
59
|
- `filesScanned` - Count of source code files analyzed (not node_modules/dist)
|
|
57
60
|
- `linesOfCode` - Total lines in source files (approximate is fine)
|
|
58
61
|
- `projectTree` - ASCII tree representation of main directories (use tree format with ├── and └──)
|
|
62
|
+
- `keyComponents` - **MUST include ALL top-level directories** containing source code. Do NOT skip any directory. List every folder from `ls -d */` excluding node_modules/dist/build/.git
|
|
59
63
|
|
|
60
64
|
This context helps readers understand the security findings in context.
|
|
61
65
|
|
|
62
|
-
### Step 3: Check for
|
|
66
|
+
### Step 3: Check for Previous Scan Results
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
cat .coverme/scan.json 2>/dev/null | head -5 || echo "NO_PREVIOUS_SCAN"
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
**IF previous scan.json exists:**
|
|
73
|
+
- Load previous findings to track what was resolved since the last scan
|
|
74
|
+
- Compare current findings against previous findings
|
|
75
|
+
- Any finding from previous scan NOT found in current scan = "Previously Resolved"
|
|
76
|
+
- Include a `previouslyResolved` array in the final output showing what was fixed
|
|
77
|
+
- This builds trust and shows security progress over time
|
|
78
|
+
|
|
79
|
+
**Format for previously resolved:**
|
|
80
|
+
```json
|
|
81
|
+
{
|
|
82
|
+
"id": "PREV-001",
|
|
83
|
+
"title": "Original finding title from previous scan",
|
|
84
|
+
"originalSeverity": "critical|high|medium|low",
|
|
85
|
+
"resolution": "How it was fixed — be specific: 'Replaced string concatenation with parameterized queries via Prisma ORM. Verified no raw SQL remains.'",
|
|
86
|
+
"resolvedDate": "Date of current scan"
|
|
87
|
+
}
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
**Example Previously Resolved section (from Officely report):**
|
|
91
|
+
- "DuckDB SQL Injection (was CRITICAL) — Resolved: enable_external_access=false sandbox + comprehensive SQL validation blocklist."
|
|
92
|
+
- "Admin API Fail-Open (was HIGH) — Resolved: Binds to 127.0.0.1, fail-closed when no ADMIN_ALLOWED_IPS. Three-layer defense."
|
|
93
|
+
- "Redis KEYS in Production (was HIGH) — Resolved: All paths now use SCAN via cursor-based scanKeys()."
|
|
94
|
+
|
|
95
|
+
**IF NO previous scan:**
|
|
96
|
+
- Skip — set `previouslyResolved` to empty array `[]`
|
|
97
|
+
|
|
98
|
+
### Step 4: Check for Runtime Verification (SSH)
|
|
63
99
|
|
|
64
100
|
```bash
|
|
65
101
|
cat .coverme/runtime.json 2>/dev/null || echo "NO_RUNTIME_CONFIG"
|
|
@@ -83,20 +119,22 @@ Every finding MUST include ALL these fields for the report to work:
|
|
|
83
119
|
```json
|
|
84
120
|
{
|
|
85
121
|
"id": "PREFIX-XXX",
|
|
86
|
-
"title": "
|
|
122
|
+
"title": "Descriptive title specific to the exact vulnerability (NOT generic category labels)",
|
|
87
123
|
"severity": "critical|high|medium|low|info",
|
|
88
124
|
"category": "Category name",
|
|
89
125
|
"file": "exact/path/to/file.ts",
|
|
90
126
|
"line": 123,
|
|
127
|
+
"endLine": 156,
|
|
91
128
|
"code": "the vulnerable/problematic code snippet",
|
|
92
|
-
"description": "
|
|
129
|
+
"description": "Precise technical narrative: what function has the issue, how it manifests, why it's dangerous. Include DREAD-D score inline for HIGH/CRITICAL.",
|
|
93
130
|
"impact": "Security impact - what an attacker could exploit, potential damage, real-world risk",
|
|
94
131
|
"attackChain": "Step-by-step exploitation: 1. Attacker does X, 2. System responds with Y, 3. Attacker gains Z",
|
|
95
|
-
"recommendation": "
|
|
132
|
+
"recommendation": "Immediately actionable: specific function names, specific patterns, specific code changes",
|
|
96
133
|
"cwe": "CWE-XXX (if applicable)",
|
|
97
134
|
"confidence": 85,
|
|
98
135
|
"fixOwner": "developer|devops|architect",
|
|
99
136
|
"fixType": "code|config|infrastructure|design",
|
|
137
|
+
"crossReferences": ["OTHER-ID-1"],
|
|
100
138
|
"dread": {
|
|
101
139
|
"damage": 8,
|
|
102
140
|
"reproducibility": 9,
|
|
@@ -138,8 +176,92 @@ Calculate DREAD score (1-10 for each, average for final score):
|
|
|
138
176
|
- 3.0-4.9 = LOW (backlog)
|
|
139
177
|
- 1.0-2.9 = INFO (document only)
|
|
140
178
|
|
|
179
|
+
## PROFESSIONAL WRITING STANDARDS
|
|
180
|
+
|
|
181
|
+
**Every finding must read as if written by an experienced security consultant, not a generic scanner.**
|
|
182
|
+
|
|
183
|
+
### Title Quality
|
|
184
|
+
Titles must be descriptive and specific to the exact vulnerability — not generic category labels.
|
|
185
|
+
|
|
186
|
+
**BAD (generic):**
|
|
187
|
+
- "Hardcoded credentials found"
|
|
188
|
+
- "Missing input validation"
|
|
189
|
+
- "XSS vulnerability"
|
|
190
|
+
|
|
191
|
+
**GOOD (descriptive, specific to the code):**
|
|
192
|
+
- "Hardcoded Tracker API Keys and Hash Salts in Helm Values"
|
|
193
|
+
- "Attestation Fallback Accepts Unverified Enclave Keys"
|
|
194
|
+
- "Credit Deduction After GPU Processing in Non-Streaming Path"
|
|
195
|
+
- "Command Injection via Unvalidated Model Name in pm2 delete"
|
|
196
|
+
|
|
197
|
+
### Description Quality
|
|
198
|
+
Descriptions must trace the exact technical flow: what function, what input, what happens, and what the consequence is — in ONE precise paragraph.
|
|
199
|
+
|
|
200
|
+
**BAD (vague):**
|
|
201
|
+
"There is a security issue with hardcoded credentials in the configuration file. This could allow unauthorized access."
|
|
202
|
+
|
|
203
|
+
**GOOD (precise technical narrative):**
|
|
204
|
+
"Staging and production Helm values contain hardcoded API keys (stg-tracker-api-key, prd-tracker-api-key) and hash salts in plaintext, committed to version control. Anyone with repo access can write arbitrary data to the tracker. DREAD-D: 6.5."
|
|
205
|
+
|
|
206
|
+
**GOOD (traces the full attack flow):**
|
|
207
|
+
"When the attestation bundle endpoint is unavailable, fetchEnclaveInfo() falls back to the legacy /api/v1/enclave endpoint and stores keys with keysVerified: false. The browser silently proceeds to encrypt messages with public keys that have not been cryptographically bound to hardware attestation — enabling a man-in-the-middle attack by a compromised gateway."
|
|
208
|
+
|
|
209
|
+
**GOOD (explains business logic flaw):**
|
|
210
|
+
"In the non-streaming path, credit deduction happens after the enclave has processed the request. A concurrent request could deplete credits between the pre-flight check and the deduction, consuming GPU resources without payment. The streaming path handles this correctly."
|
|
211
|
+
|
|
212
|
+
### Recommendation Quality
|
|
213
|
+
Recommendations must be immediately actionable — specific function names, specific patterns, specific code.
|
|
214
|
+
|
|
215
|
+
**BAD:**
|
|
216
|
+
"Fix the hardcoded credentials"
|
|
217
|
+
"Add input validation"
|
|
218
|
+
|
|
219
|
+
**GOOD:**
|
|
220
|
+
"Move to AWS Secrets Manager alongside existing KP_SECRETS_PATH pattern. Remove from version control. Rotate immediately."
|
|
221
|
+
"Extract to trackRedisMetrics(redis, models, userIdentifier) and call from both paths."
|
|
222
|
+
"Move validation to the top of startModels(). Apply in stopModels(). Use execFileAsync('pm2', ['delete', model])."
|
|
223
|
+
"Validate against whitelist from models.json or restrict to ^[a-zA-Z0-9_-]+$."
|
|
224
|
+
|
|
225
|
+
### Cross-Referencing
|
|
226
|
+
When multiple agents identify the same issue from different perspectives, MERGE them using dual IDs:
|
|
227
|
+
- "CR-02 / T-EKS-3: Hardcoded Tracker API Keys and Hash Salts in Helm Values"
|
|
228
|
+
- "T-EKS-4 / CR-18: User Identity Logged and Hash Truncated to 64 Bits"
|
|
229
|
+
- "T-BFF-3 / CR-08: Error Details Leaked to Clients"
|
|
230
|
+
|
|
231
|
+
This shows the issue was found independently from multiple angles, increasing confidence.
|
|
232
|
+
|
|
233
|
+
### Quantitative Precision
|
|
234
|
+
Always include specific numbers when available:
|
|
235
|
+
- Line counts: "160 lines of Redis metrics tracking code is duplicated verbatim"
|
|
236
|
+
- Percentages: "5.3% of the codebase"
|
|
237
|
+
- Bit lengths: "truncates SHA-256 to only 16 hex characters (64 bits)"
|
|
238
|
+
- Specific values: "session timeout of 24h", "maxAge: 31536000"
|
|
239
|
+
|
|
240
|
+
### DREAD Score Inline
|
|
241
|
+
For HIGH and CRITICAL findings, include the DREAD-D score directly in the description text: "DREAD-D: 6.3."
|
|
242
|
+
|
|
243
|
+
### Positive Observations Depth
|
|
244
|
+
Positive observations must cite specific technical evidence, not generic praise.
|
|
245
|
+
|
|
246
|
+
**BAD:**
|
|
247
|
+
"Good authentication implementation"
|
|
248
|
+
|
|
249
|
+
**GOOD:**
|
|
250
|
+
"Zero-Knowledge Architecture — EKS gateway genuinely never sees plaintext. Encrypted payloads flow through without decryption. Well-enforced across all components."
|
|
251
|
+
"Atomic Credit Operations — Lua scripts for token burning and balance deduction prevent cross-pod race conditions. Check-and-deduct is atomic."
|
|
252
|
+
"Secure File Handling — MIME + magic number validation, memory-only storage, size limits. secureDeleteFile() overwrites with random data before deletion."
|
|
253
|
+
|
|
254
|
+
---
|
|
255
|
+
|
|
141
256
|
## FIELD GUIDELINES
|
|
142
257
|
|
|
258
|
+
### description (REQUIRED — PROFESSIONAL QUALITY)
|
|
259
|
+
Write a precise technical narrative explaining:
|
|
260
|
+
1. **What** specific function/file/pattern has the issue
|
|
261
|
+
2. **How** the vulnerability manifests (trace the data flow)
|
|
262
|
+
3. **Why** it's dangerous (the consequence in one clause)
|
|
263
|
+
4. Include DREAD-D score inline for HIGH/CRITICAL: "DREAD-D: 6.5."
|
|
264
|
+
|
|
143
265
|
### impact (REQUIRED)
|
|
144
266
|
Explain the real-world security impact. Be specific about:
|
|
145
267
|
- What an attacker could do (e.g., "steal session tokens", "access other users' data")
|
|
@@ -148,6 +270,13 @@ Explain the real-world security impact. Be specific about:
|
|
|
148
270
|
|
|
149
271
|
Example: "An attacker could inject malicious scripts that steal session cookies, enabling full account takeover of any logged-in user"
|
|
150
272
|
|
|
273
|
+
### recommendation (REQUIRED — ACTIONABLE)
|
|
274
|
+
Must include at least one of:
|
|
275
|
+
- Specific function/method name to create or modify
|
|
276
|
+
- Specific configuration change with exact values
|
|
277
|
+
- Specific library/pattern to use
|
|
278
|
+
- Code snippet showing the fix
|
|
279
|
+
|
|
151
280
|
---
|
|
152
281
|
|
|
153
282
|
## PHASE 1: PARALLEL DISCOVERY
|
|
@@ -1212,36 +1341,52 @@ Output findings with proper fixOwner:
|
|
|
1212
1341
|
|
|
1213
1342
|
### AGENT 20: Executive Summary Generator (ID prefix: EXEC)
|
|
1214
1343
|
|
|
1215
|
-
After all other agents complete, generate an executive summary.
|
|
1344
|
+
After all other agents complete, generate an executive summary **written for leadership** — technically precise but accessible.
|
|
1345
|
+
|
|
1346
|
+
**WRITING GUIDELINES:**
|
|
1347
|
+
- The `overview` field should read like a professional security consultant's opening paragraph
|
|
1348
|
+
- Start with 1 sentence describing what the project IS (architecture, purpose)
|
|
1349
|
+
- Then state the overall security posture clearly
|
|
1350
|
+
- Then list the most significant remaining issues in one sentence
|
|
1351
|
+
- Use specific numbers and technical details, not vague language
|
|
1352
|
+
|
|
1353
|
+
**EXAMPLE of professional executive summary overview:**
|
|
1354
|
+
"Express-AI Officely is a confidential AI platform built on a three-tier encrypted architecture: a Next.js frontend with BFF pattern, an Express.js API gateway on EKS, and backend enclaves running inside AMD SEV-SNP encrypted VMs. No critical vulnerabilities remain. The most significant remaining issues are: unauthenticated enclave registration endpoints that could allow enclave impersonation (mitigated by network-level whitelisting), hardcoded secrets in Helm values, a monolithic 1000+ line chat handler creating maintenance risk, 3,200 lines of dead or duplicated code (5.3% of the codebase), and zero test coverage across all components."
|
|
1355
|
+
|
|
1356
|
+
**TOP RISKS writing quality:**
|
|
1357
|
+
Each risk must be a specific, actionable description — not a generic category.
|
|
1358
|
+
- BAD: "SQL injection vulnerability"
|
|
1359
|
+
- GOOD: "Unauthenticated enclave registration endpoints could allow impersonation (mitigated by network whitelisting)"
|
|
1360
|
+
- GOOD: "160 lines of Redis metrics tracking duplicated verbatim between streaming/non-streaming paths"
|
|
1216
1361
|
|
|
1217
1362
|
**OUTPUT FORMAT:**
|
|
1218
1363
|
```json
|
|
1219
1364
|
{
|
|
1220
1365
|
"executiveSummary": {
|
|
1221
|
-
"headline": "
|
|
1366
|
+
"headline": "0 Critical + 7 High findings — platform hardened but key gaps remain",
|
|
1222
1367
|
"riskLevel": "HIGH",
|
|
1368
|
+
"overview": "Professional 2-3 sentence summary as described above.",
|
|
1223
1369
|
"topRisks": [
|
|
1224
|
-
"
|
|
1225
|
-
"
|
|
1226
|
-
"
|
|
1370
|
+
"Specific risk description with technical detail and context",
|
|
1371
|
+
"Another risk with file reference and impact quantification",
|
|
1372
|
+
"Third risk with mitigation status noted if partial"
|
|
1227
1373
|
],
|
|
1228
1374
|
"positives": [
|
|
1229
|
-
"
|
|
1230
|
-
"
|
|
1231
|
-
"Good use of parameterized queries in core modules"
|
|
1375
|
+
"Specific strength with technical evidence — not generic praise",
|
|
1376
|
+
"Another strength citing specific libraries/patterns/algorithms"
|
|
1232
1377
|
],
|
|
1233
1378
|
"recommendedActions": [
|
|
1234
1379
|
{
|
|
1235
1380
|
"priority": 1,
|
|
1236
|
-
"action": "
|
|
1237
|
-
"owner": "
|
|
1238
|
-
"effort": "
|
|
1381
|
+
"action": "Remove hardcoded secrets from Helm values. Move to Secrets Manager. Rotate keys immediately.",
|
|
1382
|
+
"owner": "devops",
|
|
1383
|
+
"effort": "2-4 hours"
|
|
1239
1384
|
},
|
|
1240
1385
|
{
|
|
1241
1386
|
"priority": 2,
|
|
1242
|
-
"action": "Add
|
|
1243
|
-
"owner": "
|
|
1244
|
-
"effort": "
|
|
1387
|
+
"action": "Add shared-secret or mTLS auth to enclave status/register endpoints",
|
|
1388
|
+
"owner": "architect",
|
|
1389
|
+
"effort": "1-2 days"
|
|
1245
1390
|
}
|
|
1246
1391
|
],
|
|
1247
1392
|
"byOwner": {
|
|
@@ -1564,16 +1709,61 @@ Output:
|
|
|
1564
1709
|
|
|
1565
1710
|
---
|
|
1566
1711
|
|
|
1712
|
+
## PHASE 5: CROSS-REFERENCE MERGE
|
|
1713
|
+
|
|
1714
|
+
Before generating final output, identify findings that describe the same issue from different agent perspectives.
|
|
1715
|
+
|
|
1716
|
+
**Merge Process:**
|
|
1717
|
+
1. Compare all findings from Phase 1-4
|
|
1718
|
+
2. If two findings reference the same file+line range OR describe the same root cause:
|
|
1719
|
+
- Create a SINGLE finding with dual ID: "CR-02 / T-EKS-3"
|
|
1720
|
+
- Use the most descriptive title from either finding
|
|
1721
|
+
- Combine description details from both perspectives
|
|
1722
|
+
- Use the higher DREAD score
|
|
1723
|
+
- Populate `crossReferences` with both original IDs
|
|
1724
|
+
3. If findings are RELATED but NOT identical:
|
|
1725
|
+
- Keep as separate findings
|
|
1726
|
+
- Add each other's ID to `crossReferences` array
|
|
1727
|
+
|
|
1728
|
+
**Examples of cross-referenced findings:**
|
|
1729
|
+
- Security agent finds hardcoded key + Infrastructure agent finds same key in Helm values → MERGE
|
|
1730
|
+
- Auth agent finds missing MFA + Business logic agent finds MFA bypass → ADD crossReferences
|
|
1731
|
+
- Quality agent finds DRY violation in metrics code + Security agent finds same code → MERGE
|
|
1732
|
+
|
|
1733
|
+
---
|
|
1734
|
+
|
|
1567
1735
|
## PHASE 6: POSITIVE OBSERVATIONS
|
|
1568
1736
|
|
|
1569
|
-
Scan for good practices to include in the report
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1737
|
+
Scan for good practices to include in the report. Each positive observation must include **specific technical evidence** — not generic praise.
|
|
1738
|
+
|
|
1739
|
+
**FORMAT for each observation:**
|
|
1740
|
+
```json
|
|
1741
|
+
{
|
|
1742
|
+
"title": "Descriptive Title — 3-5 words",
|
|
1743
|
+
"description": "2-3 sentences of specific technical evidence. Name the specific functions, libraries, patterns, or configurations that demonstrate this strength. Include file references where relevant."
|
|
1744
|
+
}
|
|
1745
|
+
```
|
|
1746
|
+
|
|
1747
|
+
**BAD (generic, no evidence):**
|
|
1748
|
+
- "Good authentication implementation"
|
|
1749
|
+
- "Proper input validation"
|
|
1750
|
+
- "Secure coding practices"
|
|
1575
1751
|
|
|
1576
|
-
|
|
1752
|
+
**GOOD (specific, with evidence):**
|
|
1753
|
+
- {"title": "Zero-Knowledge Architecture", "description": "EKS gateway genuinely never sees plaintext. Encrypted payloads flow through without decryption. Well-enforced across all components."}
|
|
1754
|
+
- {"title": "Atomic Credit Operations", "description": "Lua scripts for token burning and balance deduction prevent cross-pod race conditions. Check-and-deduct is atomic."}
|
|
1755
|
+
- {"title": "Post-Quantum Cryptography", "description": "XWing (ML-KEM-768 + X25519) hybrid KEM, Ed25519 signing, AES-256-GCM. Key derivation: Argon2id + HKDF with proper alignment across browser/Node.js."}
|
|
1756
|
+
- {"title": "Secure File Handling", "description": "MIME + magic number validation, memory-only storage, size limits. secureDeleteFile() overwrites with random data before deletion."}
|
|
1757
|
+
|
|
1758
|
+
**CHECK FOR:**
|
|
1759
|
+
- Security controls that work well (name the specific middleware, library, or pattern)
|
|
1760
|
+
- Authentication/authorization strengths (name the provider, flow, and protections)
|
|
1761
|
+
- Input validation patterns (name the library and coverage)
|
|
1762
|
+
- Cryptographic implementations (name algorithms, key sizes, modes)
|
|
1763
|
+
- Architecture strengths (name the pattern and why it's secure)
|
|
1764
|
+
- Operational security (logging, monitoring, incident response)
|
|
1765
|
+
|
|
1766
|
+
Output as array of objects with `title` and `description` fields.
|
|
1577
1767
|
|
|
1578
1768
|
---
|
|
1579
1769
|
|
|
@@ -1635,20 +1825,23 @@ The final report should ONLY contain findings that are:
|
|
|
1635
1825
|
"executiveSummary": {
|
|
1636
1826
|
"headline": "3 Critical + 5 High findings require immediate attention",
|
|
1637
1827
|
"riskLevel": "CRITICAL | HIGH | MEDIUM | LOW",
|
|
1828
|
+
"overview": "A 2-3 sentence executive summary of the project architecture AND the overall security posture, written for leadership. Example: 'Express-AI Officely is a confidential AI platform built on a three-tier encrypted architecture. No critical vulnerabilities remain. The most significant remaining issues are: unauthenticated registration endpoints, hardcoded secrets in Helm values, and zero test coverage.'",
|
|
1638
1829
|
"topRisks": [
|
|
1639
|
-
"
|
|
1640
|
-
"
|
|
1830
|
+
"Unauthenticated enclave registration endpoints could allow impersonation (mitigated by network whitelisting)",
|
|
1831
|
+
"Hardcoded API keys and hash salts in Helm values committed to version control",
|
|
1832
|
+
"160 lines of Redis metrics tracking duplicated verbatim between streaming/non-streaming paths"
|
|
1641
1833
|
],
|
|
1642
1834
|
"positives": [
|
|
1643
|
-
"
|
|
1644
|
-
"
|
|
1835
|
+
"Zero-knowledge architecture — gateway never sees plaintext",
|
|
1836
|
+
"Atomic credit operations via Lua scripts prevent race conditions",
|
|
1837
|
+
"Post-quantum cryptography with XWing hybrid KEM"
|
|
1645
1838
|
],
|
|
1646
1839
|
"recommendedActions": [
|
|
1647
1840
|
{
|
|
1648
1841
|
"priority": 1,
|
|
1649
|
-
"action": "
|
|
1650
|
-
"owner": "
|
|
1651
|
-
"effort": "
|
|
1842
|
+
"action": "Remove hardcoded secrets from Helm values. Move to Secrets Manager. Rotate keys.",
|
|
1843
|
+
"owner": "devops",
|
|
1844
|
+
"effort": "2-4 hours"
|
|
1652
1845
|
}
|
|
1653
1846
|
],
|
|
1654
1847
|
"byOwner": {
|
|
@@ -1764,23 +1957,29 @@ The final report should ONLY contain findings that are:
|
|
|
1764
1957
|
"type": "delete",
|
|
1765
1958
|
"file": "src/utils/oldHelpers.ts",
|
|
1766
1959
|
"lines": 250,
|
|
1767
|
-
"
|
|
1768
|
-
"
|
|
1960
|
+
"title": "Dead utility functions — no callers in codebase",
|
|
1961
|
+
"description": "Entire file is dead code — functions never called. No imports found anywhere.",
|
|
1962
|
+
"reason": "No imports found in codebase",
|
|
1963
|
+
"roi": "~250 lines"
|
|
1769
1964
|
},
|
|
1770
1965
|
{
|
|
1771
1966
|
"type": "delete",
|
|
1772
1967
|
"file": "src/legacy/auth.js",
|
|
1773
1968
|
"lines": 180,
|
|
1774
|
-
"
|
|
1775
|
-
"
|
|
1969
|
+
"title": "Legacy auth replaced by Clerk integration",
|
|
1970
|
+
"description": "Legacy auth implementation replaced by Clerk. Migration completed 6 months ago.",
|
|
1971
|
+
"reason": "Migration completed 6 months ago",
|
|
1972
|
+
"roi": "~180 lines"
|
|
1776
1973
|
}
|
|
1777
1974
|
],
|
|
1778
1975
|
"mergeItems": [
|
|
1779
1976
|
{
|
|
1780
1977
|
"type": "merge",
|
|
1781
1978
|
"file": "src/utils/validate.ts, src/helpers/validation.ts",
|
|
1782
|
-
"
|
|
1783
|
-
"
|
|
1979
|
+
"title": "Duplicate validation modules",
|
|
1980
|
+
"description": "Two files with overlapping validation functions — same Zod schema patterns duplicated",
|
|
1981
|
+
"reason": "DRY violation — consolidate into single module",
|
|
1982
|
+
"roi": "~120 lines"
|
|
1784
1983
|
}
|
|
1785
1984
|
],
|
|
1786
1985
|
"simplifyItems": [
|
|
@@ -1788,8 +1987,10 @@ The final report should ONLY contain findings that are:
|
|
|
1788
1987
|
"type": "simplify",
|
|
1789
1988
|
"file": "src/services/payment.ts",
|
|
1790
1989
|
"lines": 450,
|
|
1791
|
-
"
|
|
1792
|
-
"
|
|
1990
|
+
"title": "Overly complex payment handler — 450 lines",
|
|
1991
|
+
"description": "Single function handles parsing, validation, processing, and error recovery with deeply nested try/catch blocks",
|
|
1992
|
+
"reason": "Split into paymentValidator, paymentProcessor, paymentErrorHandler — reduce to ~200 lines",
|
|
1993
|
+
"roi": "~250 lines reducible"
|
|
1793
1994
|
}
|
|
1794
1995
|
],
|
|
1795
1996
|
"totalLinesRemovable": 680,
|
|
@@ -1918,19 +2119,29 @@ The final report should ONLY contain findings that are:
|
|
|
1918
2119
|
"positiveObservations": [
|
|
1919
2120
|
{
|
|
1920
2121
|
"title": "Strong Authentication Implementation",
|
|
1921
|
-
"description": "Clerk integration with proper session management, MFA support, and secure cookie settings"
|
|
2122
|
+
"description": "Clerk integration with proper session management, MFA support, and secure cookie settings. All tokens kept server-side. httpOnly + secure cookies with SameSite=strict."
|
|
1922
2123
|
},
|
|
1923
2124
|
{
|
|
1924
2125
|
"title": "Comprehensive Input Validation",
|
|
1925
|
-
"description": "Zod schemas used consistently across API endpoints with proper error handling"
|
|
2126
|
+
"description": "Zod schemas used consistently across 15+ API endpoints with proper error handling. Schema-first validation prevents malformed input from reaching business logic."
|
|
1926
2127
|
},
|
|
1927
2128
|
{
|
|
1928
2129
|
"title": "Secure Database Access",
|
|
1929
|
-
"description": "Prisma ORM with parameterized queries
|
|
2130
|
+
"description": "Prisma ORM with parameterized queries throughout. Zero raw SQL queries found. Prevents SQL injection across all database operations."
|
|
1930
2131
|
},
|
|
1931
2132
|
{
|
|
1932
2133
|
"title": "Good Error Handling Patterns",
|
|
1933
|
-
"description": "
|
|
2134
|
+
"description": "Custom AppError class with error codes. Internal details logged server-side only. Generic messages returned to clients. Consistent format across routes."
|
|
2135
|
+
}
|
|
2136
|
+
],
|
|
2137
|
+
|
|
2138
|
+
"previouslyResolved": [
|
|
2139
|
+
{
|
|
2140
|
+
"id": "PREV-001",
|
|
2141
|
+
"title": "SQL Injection in search endpoint",
|
|
2142
|
+
"originalSeverity": "critical",
|
|
2143
|
+
"resolution": "Parameterized queries implemented using Prisma ORM. Verified no raw SQL remains.",
|
|
2144
|
+
"resolvedDate": "2026-01-15"
|
|
1934
2145
|
}
|
|
1935
2146
|
],
|
|
1936
2147
|
|