@dzhechkov/keysarium 1.7.18 → 1.7.20

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.
Files changed (55) hide show
  1. package/.dz-manifest.json +172 -32
  2. package/README.md +3 -3
  3. package/package.json +1 -1
  4. package/sbom.json +391 -41
  5. package/src/commands/init.js +10 -0
  6. package/src/commands/update.js +30 -3
  7. package/src/utils.js +6 -0
  8. package/templates/.claude/agents/code-goal-planner.md +441 -3
  9. package/templates/.claude/skills/feature-adr/SKILL.md +9 -7
  10. package/templates/.claude/skills/feature-adr/modules/06-implementation-plan.md +1 -1
  11. package/templates/.claude/skills/feature-adr/modules/09-fleet-qe.md +1 -1
  12. package/templates/.claude/skills/feature-adr/references/agentic-qe/README.md +11 -9
  13. package/templates/.claude/skills/feature-adr/references/agentic-qe/UPSTREAM-MANIFEST.json +290 -70
  14. package/templates/.claude/skills/feature-adr/references/agentic-qe/{chaos-engineering-resilience.md → qe-ref-chaos-engineering-resilience/REFERENCE.md} +13 -0
  15. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-chaos-engineering-resilience/evals/chaos-engineering-resilience.yaml +761 -0
  16. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-chaos-engineering-resilience/schemas/output.json +1205 -0
  17. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-chaos-engineering-resilience/scripts/validate-config.json +47 -0
  18. package/templates/.claude/skills/feature-adr/references/agentic-qe/{mutation-testing.md → qe-ref-mutation-testing/REFERENCE.md} +39 -1
  19. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-mutation-testing/config.json +14 -0
  20. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-mutation-testing/evals/mutation-testing.yaml +651 -0
  21. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-mutation-testing/references/mutation-operators.md +38 -0
  22. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-mutation-testing/schemas/output.json +707 -0
  23. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-mutation-testing/scripts/validate-config.json +44 -0
  24. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-mutation-testing/test-data/sample-output.json +295 -0
  25. package/templates/.claude/skills/feature-adr/references/agentic-qe/{performance-testing.md → qe-ref-performance-testing/REFERENCE.md} +35 -1
  26. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-performance-testing/config.json +18 -0
  27. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-performance-testing/evals/performance-testing.yaml +771 -0
  28. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-performance-testing/references/k6-patterns.md +72 -0
  29. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-performance-testing/schemas/output.json +1184 -0
  30. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-performance-testing/scripts/validate-config.json +55 -0
  31. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/REFERENCE.md +222 -0
  32. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/evals/qcsd-production-swarm.yaml +246 -0
  33. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/schemas/output.json +505 -0
  34. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/scripts/validate-config.json +25 -0
  35. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/steps/01-flag-detection.md +202 -0
  36. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/steps/02-core-agents.md +428 -0
  37. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/steps/03-batch1-results.md +101 -0
  38. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/steps/04-conditional-agents.md +125 -0
  39. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/steps/05-decision-synthesis.md +136 -0
  40. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/steps/06-report-generation.md +181 -0
  41. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/steps/07-learning-persistence.md +157 -0
  42. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/steps/08-feedback-loop.md +122 -0
  43. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-qcsd-production-swarm/steps/09-final-output.md +140 -0
  44. package/templates/.claude/skills/feature-adr/references/agentic-qe/{security-testing.md → qe-ref-security-testing/REFERENCE.md} +44 -1
  45. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-security-testing/config.json +13 -0
  46. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-security-testing/evals/security-testing.yaml +789 -0
  47. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-security-testing/references/compliance-agent-commands.md +131 -0
  48. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-security-testing/references/owasp-top-10.md +66 -0
  49. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-security-testing/schemas/output.json +879 -0
  50. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-security-testing/scripts/validate-config.json +45 -0
  51. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-security-testing/templates/security-report.md +44 -0
  52. package/templates/.claude/skills/feature-adr/references/agentic-qe/{tdd-london-chicago.md → qe-ref-tdd-london-chicago/REFERENCE.md} +21 -1
  53. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-tdd-london-chicago/schemas/output.json +444 -0
  54. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-ref-tdd-london-chicago/scripts/validate-config.json +43 -0
  55. package/templates/.claude/skills/feature-adr/references/agentic-qe/qcsd-production-swarm.md +0 -108
@@ -0,0 +1,879 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://agentic-qe.dev/schemas/security-testing-output.json",
4
+ "title": "AQE Security Testing Skill Output Schema",
5
+ "description": "Schema for security-testing skill output validation. Extends the base skill-output template with OWASP Top 10 categories, CWE identifiers, and CVSS scoring.",
6
+ "type": "object",
7
+ "required": ["skillName", "version", "timestamp", "status", "trustTier", "output"],
8
+ "properties": {
9
+ "skillName": {
10
+ "type": "string",
11
+ "const": "security-testing",
12
+ "description": "Must be 'security-testing'"
13
+ },
14
+ "version": {
15
+ "type": "string",
16
+ "pattern": "^\\d+\\.\\d+\\.\\d+(-[a-zA-Z0-9]+)?$",
17
+ "description": "Semantic version of the skill"
18
+ },
19
+ "timestamp": {
20
+ "type": "string",
21
+ "format": "date-time",
22
+ "description": "ISO 8601 timestamp of output generation"
23
+ },
24
+ "status": {
25
+ "type": "string",
26
+ "enum": ["success", "partial", "failed", "skipped"],
27
+ "description": "Overall execution status"
28
+ },
29
+ "trustTier": {
30
+ "type": "integer",
31
+ "const": 3,
32
+ "description": "Trust tier 3 indicates full validation with eval suite"
33
+ },
34
+ "output": {
35
+ "type": "object",
36
+ "required": ["summary", "findings", "owaspCategories"],
37
+ "properties": {
38
+ "summary": {
39
+ "type": "string",
40
+ "minLength": 50,
41
+ "maxLength": 2000,
42
+ "description": "Human-readable summary of security findings"
43
+ },
44
+ "score": {
45
+ "$ref": "#/$defs/securityScore",
46
+ "description": "Overall security score"
47
+ },
48
+ "findings": {
49
+ "type": "array",
50
+ "items": {
51
+ "$ref": "#/$defs/securityFinding"
52
+ },
53
+ "maxItems": 500,
54
+ "description": "List of security vulnerabilities discovered"
55
+ },
56
+ "recommendations": {
57
+ "type": "array",
58
+ "items": {
59
+ "$ref": "#/$defs/securityRecommendation"
60
+ },
61
+ "maxItems": 100,
62
+ "description": "Prioritized remediation recommendations with code examples"
63
+ },
64
+ "metrics": {
65
+ "$ref": "#/$defs/securityMetrics",
66
+ "description": "Security scan metrics and statistics"
67
+ },
68
+ "owaspCategories": {
69
+ "$ref": "#/$defs/owaspCategoryBreakdown",
70
+ "description": "OWASP Top 10 2021 category breakdown"
71
+ },
72
+ "artifacts": {
73
+ "type": "array",
74
+ "items": {
75
+ "$ref": "#/$defs/artifact"
76
+ },
77
+ "maxItems": 50,
78
+ "description": "Generated security reports and scan artifacts"
79
+ },
80
+ "timeline": {
81
+ "type": "array",
82
+ "items": {
83
+ "$ref": "#/$defs/timelineEvent"
84
+ },
85
+ "description": "Scan execution timeline"
86
+ },
87
+ "scanConfiguration": {
88
+ "$ref": "#/$defs/scanConfiguration",
89
+ "description": "Configuration used for the security scan"
90
+ }
91
+ }
92
+ },
93
+ "metadata": {
94
+ "$ref": "#/$defs/metadata"
95
+ },
96
+ "validation": {
97
+ "$ref": "#/$defs/validationResult"
98
+ },
99
+ "learning": {
100
+ "$ref": "#/$defs/learningData"
101
+ }
102
+ },
103
+ "$defs": {
104
+ "securityScore": {
105
+ "type": "object",
106
+ "required": ["value", "max"],
107
+ "properties": {
108
+ "value": {
109
+ "type": "number",
110
+ "minimum": 0,
111
+ "maximum": 100,
112
+ "description": "Security score (0=critical issues, 100=no issues)"
113
+ },
114
+ "max": {
115
+ "type": "number",
116
+ "const": 100,
117
+ "description": "Maximum score is always 100"
118
+ },
119
+ "grade": {
120
+ "type": "string",
121
+ "pattern": "^[A-F][+-]?$",
122
+ "description": "Letter grade: A (90-100), B (80-89), C (70-79), D (60-69), F (<60)"
123
+ },
124
+ "trend": {
125
+ "type": "string",
126
+ "enum": ["improving", "stable", "declining", "unknown"],
127
+ "description": "Trend compared to previous scans"
128
+ },
129
+ "riskLevel": {
130
+ "type": "string",
131
+ "enum": ["critical", "high", "medium", "low", "minimal"],
132
+ "description": "Overall risk level assessment"
133
+ }
134
+ }
135
+ },
136
+ "securityFinding": {
137
+ "type": "object",
138
+ "required": ["id", "title", "severity", "owasp"],
139
+ "properties": {
140
+ "id": {
141
+ "type": "string",
142
+ "pattern": "^SEC-\\d{3,6}$",
143
+ "description": "Unique finding identifier (e.g., SEC-001)"
144
+ },
145
+ "title": {
146
+ "type": "string",
147
+ "minLength": 10,
148
+ "maxLength": 200,
149
+ "description": "Finding title describing the vulnerability"
150
+ },
151
+ "description": {
152
+ "type": "string",
153
+ "maxLength": 2000,
154
+ "description": "Detailed description of the vulnerability"
155
+ },
156
+ "severity": {
157
+ "type": "string",
158
+ "enum": ["critical", "high", "medium", "low", "info"],
159
+ "description": "Severity: critical (CVSS 9.0-10.0), high (7.0-8.9), medium (4.0-6.9), low (0.1-3.9), info (0)"
160
+ },
161
+ "owasp": {
162
+ "type": "string",
163
+ "pattern": "^A(0[1-9]|10):20(21|25)$",
164
+ "description": "OWASP Top 10 category (e.g., A01:2021, A03:2025)"
165
+ },
166
+ "owaspCategory": {
167
+ "type": "string",
168
+ "enum": [
169
+ "A01:2021-Broken-Access-Control",
170
+ "A02:2021-Cryptographic-Failures",
171
+ "A03:2021-Injection",
172
+ "A04:2021-Insecure-Design",
173
+ "A05:2021-Security-Misconfiguration",
174
+ "A06:2021-Vulnerable-Components",
175
+ "A07:2021-Identification-Authentication-Failures",
176
+ "A08:2021-Software-Data-Integrity-Failures",
177
+ "A09:2021-Security-Logging-Monitoring-Failures",
178
+ "A10:2021-Server-Side-Request-Forgery"
179
+ ],
180
+ "description": "Full OWASP category name"
181
+ },
182
+ "cwe": {
183
+ "type": "string",
184
+ "pattern": "^CWE-\\d{1,4}$",
185
+ "description": "CWE identifier (e.g., CWE-79 for XSS, CWE-89 for SQLi)"
186
+ },
187
+ "cvss": {
188
+ "type": "object",
189
+ "properties": {
190
+ "score": {
191
+ "type": "number",
192
+ "minimum": 0,
193
+ "maximum": 10,
194
+ "description": "CVSS v3.1 base score"
195
+ },
196
+ "vector": {
197
+ "type": "string",
198
+ "pattern": "^CVSS:3\\.1/AV:[NALP]/AC:[LH]/PR:[NLH]/UI:[NR]/S:[UC]/C:[NLH]/I:[NLH]/A:[NLH]$",
199
+ "description": "CVSS v3.1 vector string"
200
+ },
201
+ "severity": {
202
+ "type": "string",
203
+ "enum": ["None", "Low", "Medium", "High", "Critical"],
204
+ "description": "CVSS severity rating"
205
+ }
206
+ }
207
+ },
208
+ "location": {
209
+ "$ref": "#/$defs/location",
210
+ "description": "Location of the vulnerability"
211
+ },
212
+ "evidence": {
213
+ "type": "string",
214
+ "maxLength": 5000,
215
+ "description": "Evidence: code snippet, request/response, or PoC"
216
+ },
217
+ "remediation": {
218
+ "type": "string",
219
+ "maxLength": 2000,
220
+ "description": "Specific fix instructions for this finding"
221
+ },
222
+ "references": {
223
+ "type": "array",
224
+ "items": {
225
+ "type": "object",
226
+ "required": ["title", "url"],
227
+ "properties": {
228
+ "title": { "type": "string" },
229
+ "url": { "type": "string", "format": "uri" }
230
+ }
231
+ },
232
+ "maxItems": 10,
233
+ "description": "External references (OWASP, CWE, CVE, etc.)"
234
+ },
235
+ "falsePositive": {
236
+ "type": "boolean",
237
+ "default": false,
238
+ "description": "Potential false positive flag"
239
+ },
240
+ "confidence": {
241
+ "type": "number",
242
+ "minimum": 0,
243
+ "maximum": 1,
244
+ "description": "Confidence in finding accuracy (0.0-1.0)"
245
+ },
246
+ "exploitability": {
247
+ "type": "string",
248
+ "enum": ["trivial", "easy", "moderate", "difficult", "theoretical"],
249
+ "description": "How easy is it to exploit this vulnerability"
250
+ },
251
+ "affectedVersions": {
252
+ "type": "array",
253
+ "items": { "type": "string" },
254
+ "description": "Affected package/library versions for dependency vulnerabilities"
255
+ },
256
+ "cve": {
257
+ "type": "string",
258
+ "pattern": "^CVE-\\d{4}-\\d{4,}$",
259
+ "description": "CVE identifier if applicable"
260
+ }
261
+ }
262
+ },
263
+ "securityRecommendation": {
264
+ "type": "object",
265
+ "required": ["id", "title", "priority", "owaspCategories"],
266
+ "properties": {
267
+ "id": {
268
+ "type": "string",
269
+ "pattern": "^REC-\\d{3,6}$",
270
+ "description": "Unique recommendation identifier"
271
+ },
272
+ "title": {
273
+ "type": "string",
274
+ "minLength": 10,
275
+ "maxLength": 200,
276
+ "description": "Recommendation title"
277
+ },
278
+ "description": {
279
+ "type": "string",
280
+ "maxLength": 2000,
281
+ "description": "Detailed recommendation description"
282
+ },
283
+ "priority": {
284
+ "type": "string",
285
+ "enum": ["critical", "high", "medium", "low"],
286
+ "description": "Remediation priority"
287
+ },
288
+ "effort": {
289
+ "type": "string",
290
+ "enum": ["trivial", "low", "medium", "high", "major"],
291
+ "description": "Estimated effort: trivial(<1hr), low(1-4hr), medium(1-3d), high(1-2wk), major(>2wk)"
292
+ },
293
+ "impact": {
294
+ "type": "integer",
295
+ "minimum": 1,
296
+ "maximum": 10,
297
+ "description": "Security impact if implemented (1-10)"
298
+ },
299
+ "relatedFindings": {
300
+ "type": "array",
301
+ "items": {
302
+ "type": "string",
303
+ "pattern": "^SEC-\\d{3,6}$"
304
+ },
305
+ "description": "IDs of findings this addresses"
306
+ },
307
+ "owaspCategories": {
308
+ "type": "array",
309
+ "items": {
310
+ "type": "string",
311
+ "pattern": "^A(0[1-9]|10):20(21|25)$"
312
+ },
313
+ "description": "OWASP categories this recommendation addresses"
314
+ },
315
+ "codeExample": {
316
+ "type": "object",
317
+ "properties": {
318
+ "before": {
319
+ "type": "string",
320
+ "maxLength": 2000,
321
+ "description": "Vulnerable code example"
322
+ },
323
+ "after": {
324
+ "type": "string",
325
+ "maxLength": 2000,
326
+ "description": "Secure code example"
327
+ },
328
+ "language": {
329
+ "type": "string",
330
+ "description": "Programming language"
331
+ }
332
+ },
333
+ "description": "Before/after code examples for remediation"
334
+ },
335
+ "resources": {
336
+ "type": "array",
337
+ "items": {
338
+ "type": "object",
339
+ "required": ["title", "url"],
340
+ "properties": {
341
+ "title": { "type": "string" },
342
+ "url": { "type": "string", "format": "uri" }
343
+ }
344
+ },
345
+ "maxItems": 10,
346
+ "description": "External resources and documentation"
347
+ },
348
+ "automatable": {
349
+ "type": "boolean",
350
+ "description": "Can this fix be automated?"
351
+ },
352
+ "fixCommand": {
353
+ "type": "string",
354
+ "description": "CLI command to apply fix if automatable"
355
+ }
356
+ }
357
+ },
358
+ "owaspCategoryBreakdown": {
359
+ "type": "object",
360
+ "description": "OWASP Top 10 2021 category scores and findings",
361
+ "properties": {
362
+ "A01:2021": {
363
+ "$ref": "#/$defs/owaspCategoryScore",
364
+ "description": "A01:2021 - Broken Access Control"
365
+ },
366
+ "A02:2021": {
367
+ "$ref": "#/$defs/owaspCategoryScore",
368
+ "description": "A02:2021 - Cryptographic Failures"
369
+ },
370
+ "A03:2021": {
371
+ "$ref": "#/$defs/owaspCategoryScore",
372
+ "description": "A03:2021 - Injection"
373
+ },
374
+ "A04:2021": {
375
+ "$ref": "#/$defs/owaspCategoryScore",
376
+ "description": "A04:2021 - Insecure Design"
377
+ },
378
+ "A05:2021": {
379
+ "$ref": "#/$defs/owaspCategoryScore",
380
+ "description": "A05:2021 - Security Misconfiguration"
381
+ },
382
+ "A06:2021": {
383
+ "$ref": "#/$defs/owaspCategoryScore",
384
+ "description": "A06:2021 - Vulnerable and Outdated Components"
385
+ },
386
+ "A07:2021": {
387
+ "$ref": "#/$defs/owaspCategoryScore",
388
+ "description": "A07:2021 - Identification and Authentication Failures"
389
+ },
390
+ "A08:2021": {
391
+ "$ref": "#/$defs/owaspCategoryScore",
392
+ "description": "A08:2021 - Software and Data Integrity Failures"
393
+ },
394
+ "A09:2021": {
395
+ "$ref": "#/$defs/owaspCategoryScore",
396
+ "description": "A09:2021 - Security Logging and Monitoring Failures"
397
+ },
398
+ "A10:2021": {
399
+ "$ref": "#/$defs/owaspCategoryScore",
400
+ "description": "A10:2021 - Server-Side Request Forgery (SSRF)"
401
+ }
402
+ },
403
+ "additionalProperties": false
404
+ },
405
+ "owaspCategoryScore": {
406
+ "type": "object",
407
+ "required": ["tested", "score"],
408
+ "properties": {
409
+ "tested": {
410
+ "type": "boolean",
411
+ "description": "Whether this category was tested"
412
+ },
413
+ "score": {
414
+ "type": "number",
415
+ "minimum": 0,
416
+ "maximum": 100,
417
+ "description": "Category score (100 = no issues, 0 = critical)"
418
+ },
419
+ "grade": {
420
+ "type": "string",
421
+ "pattern": "^[A-F][+-]?$",
422
+ "description": "Letter grade for this category"
423
+ },
424
+ "findingCount": {
425
+ "type": "integer",
426
+ "minimum": 0,
427
+ "description": "Number of findings in this category"
428
+ },
429
+ "criticalCount": {
430
+ "type": "integer",
431
+ "minimum": 0,
432
+ "description": "Number of critical findings"
433
+ },
434
+ "highCount": {
435
+ "type": "integer",
436
+ "minimum": 0,
437
+ "description": "Number of high severity findings"
438
+ },
439
+ "status": {
440
+ "type": "string",
441
+ "enum": ["pass", "fail", "warn", "skip"],
442
+ "description": "Category status"
443
+ },
444
+ "description": {
445
+ "type": "string",
446
+ "description": "Category description and context"
447
+ },
448
+ "cwes": {
449
+ "type": "array",
450
+ "items": {
451
+ "type": "string",
452
+ "pattern": "^CWE-\\d{1,4}$"
453
+ },
454
+ "description": "CWEs found in this category"
455
+ }
456
+ }
457
+ },
458
+ "securityMetrics": {
459
+ "type": "object",
460
+ "properties": {
461
+ "totalFindings": {
462
+ "type": "integer",
463
+ "minimum": 0,
464
+ "description": "Total vulnerabilities found"
465
+ },
466
+ "criticalCount": {
467
+ "type": "integer",
468
+ "minimum": 0,
469
+ "description": "Critical severity findings"
470
+ },
471
+ "highCount": {
472
+ "type": "integer",
473
+ "minimum": 0,
474
+ "description": "High severity findings"
475
+ },
476
+ "mediumCount": {
477
+ "type": "integer",
478
+ "minimum": 0,
479
+ "description": "Medium severity findings"
480
+ },
481
+ "lowCount": {
482
+ "type": "integer",
483
+ "minimum": 0,
484
+ "description": "Low severity findings"
485
+ },
486
+ "infoCount": {
487
+ "type": "integer",
488
+ "minimum": 0,
489
+ "description": "Informational findings"
490
+ },
491
+ "filesScanned": {
492
+ "type": "integer",
493
+ "minimum": 0,
494
+ "description": "Number of files analyzed"
495
+ },
496
+ "linesOfCode": {
497
+ "type": "integer",
498
+ "minimum": 0,
499
+ "description": "Lines of code scanned"
500
+ },
501
+ "dependenciesChecked": {
502
+ "type": "integer",
503
+ "minimum": 0,
504
+ "description": "Number of dependencies checked"
505
+ },
506
+ "owaspCategoriesTested": {
507
+ "type": "integer",
508
+ "minimum": 0,
509
+ "maximum": 10,
510
+ "description": "OWASP Top 10 categories tested"
511
+ },
512
+ "owaspCategoriesPassed": {
513
+ "type": "integer",
514
+ "minimum": 0,
515
+ "maximum": 10,
516
+ "description": "OWASP Top 10 categories with no findings"
517
+ },
518
+ "uniqueCwes": {
519
+ "type": "integer",
520
+ "minimum": 0,
521
+ "description": "Unique CWE identifiers found"
522
+ },
523
+ "falsePositiveRate": {
524
+ "type": "number",
525
+ "minimum": 0,
526
+ "maximum": 1,
527
+ "description": "Estimated false positive rate"
528
+ },
529
+ "scanDurationMs": {
530
+ "type": "integer",
531
+ "minimum": 0,
532
+ "description": "Total scan duration in milliseconds"
533
+ },
534
+ "coverage": {
535
+ "type": "object",
536
+ "properties": {
537
+ "sast": {
538
+ "type": "boolean",
539
+ "description": "Static analysis performed"
540
+ },
541
+ "dast": {
542
+ "type": "boolean",
543
+ "description": "Dynamic analysis performed"
544
+ },
545
+ "dependencies": {
546
+ "type": "boolean",
547
+ "description": "Dependency scan performed"
548
+ },
549
+ "secrets": {
550
+ "type": "boolean",
551
+ "description": "Secret scanning performed"
552
+ },
553
+ "configuration": {
554
+ "type": "boolean",
555
+ "description": "Configuration review performed"
556
+ }
557
+ },
558
+ "description": "Scan coverage indicators"
559
+ }
560
+ }
561
+ },
562
+ "scanConfiguration": {
563
+ "type": "object",
564
+ "properties": {
565
+ "target": {
566
+ "type": "string",
567
+ "description": "Scan target (file path, URL, or package)"
568
+ },
569
+ "targetType": {
570
+ "type": "string",
571
+ "enum": ["source", "url", "package", "container", "infrastructure"],
572
+ "description": "Type of target being scanned"
573
+ },
574
+ "scanTypes": {
575
+ "type": "array",
576
+ "items": {
577
+ "type": "string",
578
+ "enum": ["sast", "dast", "dependency", "secret", "configuration", "container", "iac"]
579
+ },
580
+ "description": "Types of scans performed"
581
+ },
582
+ "severity": {
583
+ "type": "array",
584
+ "items": {
585
+ "type": "string",
586
+ "enum": ["critical", "high", "medium", "low", "info"]
587
+ },
588
+ "description": "Severity levels included in scan"
589
+ },
590
+ "owaspCategories": {
591
+ "type": "array",
592
+ "items": {
593
+ "type": "string",
594
+ "pattern": "^A(0[1-9]|10):20(21|25)$"
595
+ },
596
+ "description": "OWASP categories tested"
597
+ },
598
+ "tools": {
599
+ "type": "array",
600
+ "items": { "type": "string" },
601
+ "description": "Security tools used"
602
+ },
603
+ "excludePatterns": {
604
+ "type": "array",
605
+ "items": { "type": "string" },
606
+ "description": "File patterns excluded from scan"
607
+ },
608
+ "rulesets": {
609
+ "type": "array",
610
+ "items": { "type": "string" },
611
+ "description": "Security rulesets applied"
612
+ }
613
+ }
614
+ },
615
+ "location": {
616
+ "type": "object",
617
+ "properties": {
618
+ "file": {
619
+ "type": "string",
620
+ "maxLength": 500,
621
+ "description": "File path relative to project root"
622
+ },
623
+ "line": {
624
+ "type": "integer",
625
+ "minimum": 1,
626
+ "description": "Line number"
627
+ },
628
+ "column": {
629
+ "type": "integer",
630
+ "minimum": 1,
631
+ "description": "Column number"
632
+ },
633
+ "endLine": {
634
+ "type": "integer",
635
+ "minimum": 1,
636
+ "description": "End line for multi-line findings"
637
+ },
638
+ "endColumn": {
639
+ "type": "integer",
640
+ "minimum": 1,
641
+ "description": "End column"
642
+ },
643
+ "url": {
644
+ "type": "string",
645
+ "format": "uri",
646
+ "description": "URL for web-based findings"
647
+ },
648
+ "endpoint": {
649
+ "type": "string",
650
+ "description": "API endpoint path"
651
+ },
652
+ "method": {
653
+ "type": "string",
654
+ "enum": ["GET", "POST", "PUT", "DELETE", "PATCH", "HEAD", "OPTIONS"],
655
+ "description": "HTTP method for API findings"
656
+ },
657
+ "parameter": {
658
+ "type": "string",
659
+ "description": "Vulnerable parameter name"
660
+ },
661
+ "component": {
662
+ "type": "string",
663
+ "description": "Affected component or module"
664
+ }
665
+ }
666
+ },
667
+ "artifact": {
668
+ "type": "object",
669
+ "required": ["type", "path"],
670
+ "properties": {
671
+ "type": {
672
+ "type": "string",
673
+ "enum": ["report", "sarif", "data", "log", "evidence"],
674
+ "description": "Artifact type"
675
+ },
676
+ "path": {
677
+ "type": "string",
678
+ "maxLength": 500,
679
+ "description": "Path to artifact"
680
+ },
681
+ "format": {
682
+ "type": "string",
683
+ "enum": ["json", "sarif", "html", "md", "txt", "xml", "csv"],
684
+ "description": "Artifact format"
685
+ },
686
+ "description": {
687
+ "type": "string",
688
+ "maxLength": 500,
689
+ "description": "Artifact description"
690
+ },
691
+ "sizeBytes": {
692
+ "type": "integer",
693
+ "minimum": 0,
694
+ "description": "File size in bytes"
695
+ },
696
+ "checksum": {
697
+ "type": "string",
698
+ "pattern": "^sha256:[a-f0-9]{64}$",
699
+ "description": "SHA-256 checksum"
700
+ }
701
+ }
702
+ },
703
+ "timelineEvent": {
704
+ "type": "object",
705
+ "required": ["timestamp", "event"],
706
+ "properties": {
707
+ "timestamp": {
708
+ "type": "string",
709
+ "format": "date-time",
710
+ "description": "Event timestamp"
711
+ },
712
+ "event": {
713
+ "type": "string",
714
+ "maxLength": 200,
715
+ "description": "Event description"
716
+ },
717
+ "type": {
718
+ "type": "string",
719
+ "enum": ["start", "checkpoint", "warning", "error", "complete"],
720
+ "description": "Event type"
721
+ },
722
+ "durationMs": {
723
+ "type": "integer",
724
+ "minimum": 0,
725
+ "description": "Duration since previous event"
726
+ },
727
+ "phase": {
728
+ "type": "string",
729
+ "enum": ["initialization", "sast", "dast", "dependency", "secret", "reporting"],
730
+ "description": "Scan phase"
731
+ }
732
+ }
733
+ },
734
+ "metadata": {
735
+ "type": "object",
736
+ "properties": {
737
+ "executionTimeMs": {
738
+ "type": "integer",
739
+ "minimum": 0,
740
+ "maximum": 3600000,
741
+ "description": "Execution time in milliseconds"
742
+ },
743
+ "toolsUsed": {
744
+ "type": "array",
745
+ "items": {
746
+ "type": "string",
747
+ "enum": ["semgrep", "npm-audit", "trivy", "owasp-zap", "bandit", "gosec", "eslint-security", "snyk", "gitleaks", "trufflehog", "bearer"]
748
+ },
749
+ "uniqueItems": true,
750
+ "description": "Security tools used"
751
+ },
752
+ "agentId": {
753
+ "type": "string",
754
+ "pattern": "^qe-[a-z][a-z0-9-]*$",
755
+ "description": "Agent ID (e.g., qe-security-scanner)"
756
+ },
757
+ "modelUsed": {
758
+ "type": "string",
759
+ "description": "LLM model used for analysis"
760
+ },
761
+ "inputHash": {
762
+ "type": "string",
763
+ "pattern": "^[a-f0-9]{64}$",
764
+ "description": "SHA-256 hash of input"
765
+ },
766
+ "targetUrl": {
767
+ "type": "string",
768
+ "format": "uri",
769
+ "description": "Target URL if applicable"
770
+ },
771
+ "targetPath": {
772
+ "type": "string",
773
+ "description": "Target path if applicable"
774
+ },
775
+ "environment": {
776
+ "type": "string",
777
+ "enum": ["development", "staging", "production", "ci"],
778
+ "description": "Execution environment"
779
+ },
780
+ "retryCount": {
781
+ "type": "integer",
782
+ "minimum": 0,
783
+ "maximum": 10,
784
+ "description": "Number of retries"
785
+ }
786
+ }
787
+ },
788
+ "validationResult": {
789
+ "type": "object",
790
+ "properties": {
791
+ "schemaValid": {
792
+ "type": "boolean",
793
+ "description": "Passes JSON schema validation"
794
+ },
795
+ "contentValid": {
796
+ "type": "boolean",
797
+ "description": "Passes content validation"
798
+ },
799
+ "confidence": {
800
+ "type": "number",
801
+ "minimum": 0,
802
+ "maximum": 1,
803
+ "description": "Confidence score"
804
+ },
805
+ "warnings": {
806
+ "type": "array",
807
+ "items": {
808
+ "type": "string",
809
+ "maxLength": 500
810
+ },
811
+ "maxItems": 20,
812
+ "description": "Validation warnings"
813
+ },
814
+ "errors": {
815
+ "type": "array",
816
+ "items": {
817
+ "type": "string",
818
+ "maxLength": 500
819
+ },
820
+ "maxItems": 20,
821
+ "description": "Validation errors"
822
+ },
823
+ "validatorVersion": {
824
+ "type": "string",
825
+ "pattern": "^\\d+\\.\\d+\\.\\d+$",
826
+ "description": "Validator version"
827
+ }
828
+ }
829
+ },
830
+ "learningData": {
831
+ "type": "object",
832
+ "properties": {
833
+ "patternsDetected": {
834
+ "type": "array",
835
+ "items": {
836
+ "type": "string",
837
+ "maxLength": 200
838
+ },
839
+ "maxItems": 20,
840
+ "description": "Security patterns detected (e.g., sql-injection-string-concat)"
841
+ },
842
+ "reward": {
843
+ "type": "number",
844
+ "minimum": 0,
845
+ "maximum": 1,
846
+ "description": "Reward signal for learning (0.0-1.0)"
847
+ },
848
+ "feedbackLoop": {
849
+ "type": "object",
850
+ "properties": {
851
+ "previousRunId": {
852
+ "type": "string",
853
+ "format": "uuid",
854
+ "description": "Previous run ID for comparison"
855
+ },
856
+ "improvement": {
857
+ "type": "number",
858
+ "minimum": -1,
859
+ "maximum": 1,
860
+ "description": "Improvement over previous run"
861
+ }
862
+ }
863
+ },
864
+ "newVulnerabilityPatterns": {
865
+ "type": "array",
866
+ "items": {
867
+ "type": "object",
868
+ "properties": {
869
+ "pattern": { "type": "string" },
870
+ "cwe": { "type": "string" },
871
+ "confidence": { "type": "number" }
872
+ }
873
+ },
874
+ "description": "New vulnerability patterns learned"
875
+ }
876
+ }
877
+ }
878
+ }
879
+ }