sinapse-ai 9.3.0 → 9.4.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.
Files changed (192) hide show
  1. package/.claude/CLAUDE.md +56 -343
  2. package/.claude/rules/agent-authority.md +6 -0
  3. package/.claude/rules/agent-handoff.md +5 -0
  4. package/.claude/rules/cross-squad-routing.md +5 -0
  5. package/.claude/rules/hook-governance.md +6 -0
  6. package/.claude/rules/mcp-usage.md +3 -1
  7. package/.claude/rules/safe-collaboration.md +10 -0
  8. package/.claude/rules/security-data-protection.md +9 -0
  9. package/.claude/rules/squad-awareness.md +3 -1
  10. package/.claude/rules/tool-examples.md +6 -0
  11. package/.claude/rules/workflow-execution.md +7 -0
  12. package/.codex/agents/analyst.md +253 -72
  13. package/.codex/agents/architect.md +455 -68
  14. package/.codex/agents/data-engineer.md +492 -106
  15. package/.codex/agents/developer.md +560 -0
  16. package/.codex/agents/devops.md +518 -69
  17. package/.codex/agents/product-lead.md +335 -0
  18. package/.codex/agents/project-lead.md +377 -0
  19. package/.codex/agents/quality-gate.md +449 -0
  20. package/.codex/agents/sinapse-orqx.md +9 -7
  21. package/.codex/agents/sprint-lead.md +287 -0
  22. package/.codex/agents/squad-creator.md +344 -0
  23. package/.codex/agents/ux-design-expert.md +495 -0
  24. package/.codex/delegation-matrix.json +756 -44
  25. package/.codex/handoff-packet.schema.json +30 -6
  26. package/.sinapse-ai/data/entity-registry.yaml +175 -363
  27. package/.sinapse-ai/data/registry-update-log.jsonl +16 -0
  28. package/.sinapse-ai/development/agents/analyst.md +90 -0
  29. package/.sinapse-ai/development/agents/architect.md +73 -0
  30. package/.sinapse-ai/development/agents/developer.md +69 -0
  31. package/.sinapse-ai/development/agents/devops.md +117 -0
  32. package/.sinapse-ai/development/agents/quality-gate.md +85 -0
  33. package/.sinapse-ai/development/checklists/agent-quality-gate.md +27 -0
  34. package/.sinapse-ai/development/checklists/brownfield-compatibility-checklist.md +20 -0
  35. package/.sinapse-ai/development/checklists/code-review-checklist.md +106 -0
  36. package/.sinapse-ai/development/checklists/issue-triage-checklist.md +9 -0
  37. package/.sinapse-ai/development/checklists/memory-audit-checklist.md +16 -0
  38. package/.sinapse-ai/development/checklists/pr-quality-checklist.md +72 -0
  39. package/.sinapse-ai/development/checklists/security-deployment-checklist.md +54 -0
  40. package/.sinapse-ai/development/checklists/self-critique-checklist.md +19 -1
  41. package/.sinapse-ai/development/skills/debug.md +57 -0
  42. package/.sinapse-ai/development/skills/fast-review.md +69 -0
  43. package/.sinapse-ai/development/skills/research-synthesis.md +77 -0
  44. package/.sinapse-ai/development/skills/security-scan.md +73 -0
  45. package/.sinapse-ai/development/skills/verify.md +53 -0
  46. package/.sinapse-ai/development/templates/squad/agent-template.md +17 -4
  47. package/.sinapse-ai/development/templates/squad/checklist-template.md +13 -5
  48. package/.sinapse-ai/development/templates/squad/task-template.md +7 -0
  49. package/.sinapse-ai/development/templates/squad/workflow-template.yaml +7 -0
  50. package/.sinapse-ai/development/workflows/fast-track.yaml +87 -0
  51. package/.sinapse-ai/infrastructure/scripts/validate-codex-delegation.js +3 -1
  52. package/.sinapse-ai/install-manifest.yaml +71 -35
  53. package/docs/codex-integration-process.md +22 -0
  54. package/docs/codex-parity-program.md +27 -0
  55. package/docs/ide-integration.md +36 -0
  56. package/package.json +1 -1
  57. package/squads/claude-code-mastery/knowledge-base/claude-code-internals-reference.md +927 -0
  58. package/squads/squad-brand/knowledge-base/archetype-brand-mapping.md +12 -1
  59. package/squads/squad-brand/knowledge-base/brand-activism-cultural-branding.md +216 -0
  60. package/squads/squad-brand/knowledge-base/brand-audit-criteria.md +58 -0
  61. package/squads/squad-brand/knowledge-base/brand-digital-strategy.md +188 -0
  62. package/squads/squad-brand/knowledge-base/brand-legal-ip.md +222 -0
  63. package/squads/squad-brand/knowledge-base/brand-naming-framework.md +163 -0
  64. package/squads/squad-brand/knowledge-base/branding-master-reference.md +1001 -0
  65. package/squads/squad-brand/knowledge-base/color-psychology.md +25 -12
  66. package/squads/squad-brand/knowledge-base/employer-personal-branding.md +206 -0
  67. package/squads/squad-brand/knowledge-base/routing-catalog.md +34 -0
  68. package/squads/squad-brand/knowledge-base/sonic-branding-principles.md +6 -1
  69. package/squads/squad-brand/knowledge-base/typography-personality.md +34 -0
  70. package/squads/squad-claude/knowledge-base/context-window-optimization.md +334 -0
  71. package/squads/squad-claude/knowledge-base/knowledge-architecture-reference.md +403 -0
  72. package/squads/squad-claude/knowledge-base/memory-systems-reference.md +412 -0
  73. package/squads/squad-claude/knowledge-base/obsidian-claude-integration.md +423 -0
  74. package/squads/squad-claude/knowledge-base/retrieval-augmented-generation.md +320 -0
  75. package/squads/squad-claude/knowledge-base/skill-creation-patterns.md +380 -0
  76. package/squads/squad-claude/knowledge-base/swarm-orchestration-patterns.md +411 -0
  77. package/squads/squad-cloning/knowledge-base/clone-quality-assurance.md +211 -0
  78. package/squads/squad-cloning/knowledge-base/confidence-scoring.md +51 -0
  79. package/squads/squad-cloning/knowledge-base/cross-squad-deployment.md +47 -0
  80. package/squads/squad-cloning/knowledge-base/ethical-guidelines.md +237 -0
  81. package/squads/squad-cloning/knowledge-base/knowledge-graph-for-clones.md +295 -0
  82. package/squads/squad-cloning/knowledge-base/memory-architecture-for-clones.md +229 -0
  83. package/squads/squad-cloning/knowledge-base/multi-agent-deployment-patterns.md +320 -0
  84. package/squads/squad-cloning/knowledge-base/skill-standard-for-clones.md +262 -0
  85. package/squads/squad-cloning/knowledge-base/sop-extraction-guide.md +243 -0
  86. package/squads/squad-commercial/knowledge-base/account-based-selling.md +206 -0
  87. package/squads/squad-commercial/knowledge-base/ai-as-competitive-infrastructure.md +14 -0
  88. package/squads/squad-commercial/knowledge-base/ai-in-sales.md +199 -0
  89. package/squads/squad-commercial/knowledge-base/brazilian-sales-context.md +195 -0
  90. package/squads/squad-commercial/knowledge-base/customer-success-operations.md +83 -2
  91. package/squads/squad-commercial/knowledge-base/prospecting-pipeline-generation.md +69 -0
  92. package/squads/squad-commercial/knowledge-base/sales-enablement-playbook.md +260 -0
  93. package/squads/squad-commercial/knowledge-base/sales-methodology-comparison.md +185 -0
  94. package/squads/squad-commercial/knowledge-base/sales-revenue-master-reference.md +1123 -0
  95. package/squads/squad-content/knowledge-base/brazilian-content-context.md +176 -0
  96. package/squads/squad-content/knowledge-base/competitor-analysis-methods.md +40 -1
  97. package/squads/squad-content/knowledge-base/content-architecture-taxonomy.md +206 -0
  98. package/squads/squad-content/knowledge-base/content-formats-encyclopedia.md +58 -1
  99. package/squads/squad-content/knowledge-base/content-references-bibliography.md +130 -0
  100. package/squads/squad-content/knowledge-base/content-strategy-master-reference.md +1097 -0
  101. package/squads/squad-content/knowledge-base/content-tech-stack.md +150 -0
  102. package/squads/squad-content/knowledge-base/copywriting-formulas-library.md +188 -0
  103. package/squads/squad-content/knowledge-base/email-newsletter-strategy.md +161 -0
  104. package/squads/squad-content/knowledge-base/platform-algorithm-intelligence.md +86 -1
  105. package/squads/squad-content/knowledge-base/social-algorithms-master-reference.md +1007 -0
  106. package/squads/squad-content/knowledge-base/video-audio-content-playbook.md +218 -0
  107. package/squads/squad-copy/knowledge-base/ai-copy-production.md +254 -0
  108. package/squads/squad-copy/knowledge-base/brazilian-copywriting-context.md +242 -0
  109. package/squads/squad-copy/knowledge-base/email-copywriting-system.md +299 -0
  110. package/squads/squad-copy/knowledge-base/landing-page-copy-architecture.md +267 -0
  111. package/squads/squad-copy/knowledge-base/power-words-catalog.md +205 -0
  112. package/squads/squad-copy/knowledge-base/seo-copywriting.md +255 -0
  113. package/squads/squad-copy/knowledge-base/video-script-copywriting.md +239 -0
  114. package/squads/squad-council/knowledge-base/brand-strategy-models.md +193 -0
  115. package/squads/squad-council/knowledge-base/growth-strategy-models.md +267 -0
  116. package/squads/squad-council/knowledge-base/innovation-disruption-frameworks.md +193 -0
  117. package/squads/squad-council/knowledge-base/market-analysis-frameworks.md +240 -0
  118. package/squads/squad-council/knowledge-base/organizational-leadership-models.md +212 -0
  119. package/squads/squad-council/knowledge-base/sales-strategy-models.md +215 -0
  120. package/squads/squad-courses/knowledge-base/course-launch-strategy.md +251 -0
  121. package/squads/squad-courses/knowledge-base/domain-advocacia-curriculum.md +385 -0
  122. package/squads/squad-courses/knowledge-base/domain-contabilidade-curriculum.md +266 -0
  123. package/squads/squad-courses/knowledge-base/platform-comparison.md +68 -0
  124. package/squads/squad-courses/knowledge-base/video-production-guide.md +70 -0
  125. package/squads/squad-cybersecurity/knowledge-base/cloud-security-reference.md +363 -0
  126. package/squads/squad-cybersecurity/knowledge-base/compliance-frameworks.md +273 -0
  127. package/squads/squad-cybersecurity/knowledge-base/database-security.md +438 -0
  128. package/squads/squad-cybersecurity/knowledge-base/incident-response-playbook.md +420 -0
  129. package/squads/squad-cybersecurity/knowledge-base/network-security-reference.md +477 -0
  130. package/squads/squad-cybersecurity/knowledge-base/penetration-testing-methodology.md +350 -0
  131. package/squads/squad-cybersecurity/knowledge-base/vulnerability-management.md +349 -0
  132. package/squads/squad-design/knowledge-base/brazilian-design-context.md +223 -0
  133. package/squads/squad-design/knowledge-base/component-api-patterns.md +208 -4
  134. package/squads/squad-design/knowledge-base/design-system-master-reference.md +1302 -0
  135. package/squads/squad-design/knowledge-base/design-systems-frameworks.md +91 -1
  136. package/squads/squad-design/knowledge-base/responsive-modern-css.md +96 -4
  137. package/squads/squad-design/knowledge-base/wcag-aria-reference.md +117 -5
  138. package/squads/squad-design/knowledge-base/web-performance-reference.md +127 -4
  139. package/squads/squad-finance/knowledge-base/brazilian-taxation.md +263 -0
  140. package/squads/squad-finance/knowledge-base/contabilidade-master-reference.md +998 -0
  141. package/squads/squad-finance/knowledge-base/finance-master-reference.md +946 -0
  142. package/squads/squad-finance/knowledge-base/financial-reporting-analysis.md +316 -0
  143. package/squads/squad-finance/knowledge-base/fintech-brazilian-context.md +242 -0
  144. package/squads/squad-finance/knowledge-base/fpa-planning-frameworks.md +286 -0
  145. package/squads/squad-finance/knowledge-base/ma-and-transactions.md +285 -0
  146. package/squads/squad-finance/knowledge-base/risk-management.md +233 -0
  147. package/squads/squad-finance/knowledge-base/startups-venture-capital.md +337 -0
  148. package/squads/squad-growth/knowledge-base/ai-growth-playbook.md +216 -0
  149. package/squads/squad-growth/knowledge-base/attribution-models.md +78 -0
  150. package/squads/squad-growth/knowledge-base/brazilian-growth-context.md +208 -0
  151. package/squads/squad-growth/knowledge-base/community-led-growth.md +175 -0
  152. package/squads/squad-growth/knowledge-base/content-marketing-flywheel.md +190 -0
  153. package/squads/squad-growth/knowledge-base/email-lifecycle-framework.md +192 -0
  154. package/squads/squad-growth/knowledge-base/growth-frameworks-catalog.md +82 -0
  155. package/squads/squad-growth/knowledge-base/growth-master-reference.md +1168 -0
  156. package/squads/squad-growth/knowledge-base/routing-catalog.md +53 -11
  157. package/squads/squad-paidmedia/knowledge-base/audiences-segmentation-deep.md +285 -0
  158. package/squads/squad-paidmedia/knowledge-base/creative-strategy-deep.md +294 -0
  159. package/squads/squad-paidmedia/knowledge-base/google-ads-account-architecture.md +87 -0
  160. package/squads/squad-paidmedia/knowledge-base/meta-ads-campaign-architecture.md +76 -0
  161. package/squads/squad-paidmedia/knowledge-base/paid-media-metrics-reference.md +117 -0
  162. package/squads/squad-paidmedia/knowledge-base/paid-traffic-master-reference.md +1308 -0
  163. package/squads/squad-paidmedia/knowledge-base/routing-catalog.md +95 -18
  164. package/squads/squad-paidmedia/knowledge-base/traffic-masters-frameworks.md +71 -0
  165. package/squads/squad-product/knowledge-base/brazilian-product-context.md +284 -0
  166. package/squads/squad-product/knowledge-base/discovery-methodology-playbook.md +141 -0
  167. package/squads/squad-product/knowledge-base/pm-frameworks-reference.md +125 -9
  168. package/squads/squad-product/knowledge-base/product-analytics-formulas.md +72 -0
  169. package/squads/squad-product/knowledge-base/product-led-growth-reference.md +155 -13
  170. package/squads/squad-product/knowledge-base/product-market-fit-framework.md +222 -0
  171. package/squads/squad-product/knowledge-base/routing-catalog.md +32 -0
  172. package/squads/squad-research/knowledge-base/agentic-second-brain-reference.md +591 -0
  173. package/squads/squad-research/knowledge-base/ai-augmented-research.md +212 -0
  174. package/squads/squad-research/knowledge-base/brazilian-market-research-sources.md +197 -0
  175. package/squads/squad-research/knowledge-base/community-platforms-reference.md +786 -0
  176. package/squads/squad-research/knowledge-base/community-research-methods.md +194 -0
  177. package/squads/squad-research/knowledge-base/mixed-methods-research-design.md +168 -0
  178. package/squads/squad-research/knowledge-base/network-effects-analysis.md +192 -0
  179. package/squads/squad-research/knowledge-base/qualitative-research-deep-methods.md +202 -0
  180. package/squads/squad-research/knowledge-base/quantitative-research-methods.md +208 -0
  181. package/squads/squad-research/knowledge-base/research-frameworks-encyclopedia.md +40 -0
  182. package/squads/squad-research/knowledge-base/research-synthesis-frameworks.md +223 -0
  183. package/squads/squad-storytelling/knowledge-base/brand-mythology-framework.md +236 -0
  184. package/squads/squad-storytelling/knowledge-base/brazilian-storytelling-context.md +237 -0
  185. package/squads/squad-storytelling/knowledge-base/data-storytelling.md +232 -0
  186. package/squads/squad-storytelling/knowledge-base/improv-storytelling.md +226 -0
  187. package/squads/squad-storytelling/knowledge-base/persuasion-narrative-techniques.md +269 -0
  188. package/squads/squad-storytelling/knowledge-base/social-movement-narratives.md +191 -0
  189. package/squads/squad-storytelling/knowledge-base/video-storytelling.md +252 -0
  190. package/squads/claude-code-mastery/data/swarm-orchestration-patterns.yaml +0 -378
  191. package/squads/squad-animations/knowledge-base/framer-motion-complete-reference.md +0 -710
  192. package/squads/squad-animations/knowledge-base/web-animations-api-view-transitions.md +0 -478
@@ -0,0 +1,350 @@
1
+ # Penetration Testing Methodology Reference
2
+
3
+ ## Purpose
4
+
5
+ Complete methodology reference for authorized penetration testing — PTES phases, OWASP Testing Guide, tool selection, and reporting standards. Used exclusively by Breach (penetration-tester). All operations require verified written authorization.
6
+
7
+ **ETHICAL GATE:** Every engagement starts with written authorization, defined scope, and rules of engagement. No exceptions.
8
+
9
+ ---
10
+
11
+ ## PTES: Penetration Testing Execution Standard
12
+
13
+ The PTES defines 7 phases for a complete penetration test engagement.
14
+
15
+ ### Phase 1: Pre-Engagement
16
+
17
+ Define the scope, rules, and legal authorization before any technical work begins.
18
+
19
+ **Required artifacts before proceeding:**
20
+ - Written authorization (signed scope of work or letter of authorization)
21
+ - Defined in-scope assets (IP ranges, domains, applications, APIs)
22
+ - Out-of-scope assets explicitly listed
23
+ - Rules of engagement (testing windows, contacts, escalation path)
24
+ - Emergency stop procedure (who to call if critical infrastructure affected)
25
+ - Data handling agreement (how findings are stored and transmitted)
26
+
27
+ **Authorization verification checklist:**
28
+ ```
29
+ [ ] Written authorization received and on file
30
+ [ ] Scope document signed by authorized representative
31
+ [ ] Out-of-scope assets documented
32
+ [ ] Testing windows agreed upon
33
+ [ ] Emergency contact available
34
+ [ ] Findings handling agreed (encryption, retention)
35
+ [ ] Legal jurisdiction confirmed
36
+ ```
37
+
38
+ ### Phase 2: Intelligence Gathering (Reconnaissance)
39
+
40
+ Collect information about the target using only authorized, passive techniques unless active recon is explicitly permitted.
41
+
42
+ **Passive recon (always allowed within scope):**
43
+ ```bash
44
+ # DNS enumeration
45
+ dig +short example.com any
46
+ dnsx -d example.com -a -aaaa -mx -ns -cname -txt
47
+
48
+ # Subdomain discovery (passive, no direct contact)
49
+ subfinder -d example.com -silent
50
+
51
+ # WHOIS and registration data
52
+ whois example.com
53
+
54
+ # Certificate transparency logs (public data)
55
+ curl "https://crt.sh/?q=%.example.com&output=json" | jq '.[].name_value'
56
+
57
+ # Google dorking — public info indexed by search engines
58
+ site:example.com filetype:pdf
59
+ site:example.com inurl:admin
60
+ ```
61
+
62
+ **Active recon (requires explicit authorization):**
63
+ ```bash
64
+ # Port scanning — only against authorized IPs
65
+ nmap -sV -sC -p 1-65535 --open -T4 target.example.com
66
+
67
+ # Service version detection
68
+ nmap -sV -p 80,443,8080,8443 target.example.com
69
+
70
+ # Web technology fingerprinting
71
+ whatweb target.example.com
72
+ ```
73
+
74
+ ### Phase 3: Threat Modeling
75
+
76
+ Map identified attack surface to threat scenarios:
77
+ - Document open ports and services
78
+ - Map application technologies (CMS, frameworks, libraries)
79
+ - Identify authentication mechanisms
80
+ - Note third-party integrations and external dependencies
81
+ - Cross-reference CVEs for identified versions
82
+
83
+ ### Phase 4: Vulnerability Analysis
84
+
85
+ Systematically identify vulnerabilities using automated tools and manual techniques.
86
+
87
+ **Automated scanning:**
88
+ ```bash
89
+ # Web application scanning (DAST)
90
+ # OWASP ZAP — automated scan
91
+ zap-cli --zap-url http://localhost:8080 quick-scan --self-contained --spider \
92
+ --ajax-spider -r --output-format json http://target.example.com
93
+
94
+ # Nuclei — template-based vulnerability scanner
95
+ nuclei -u https://target.example.com -t /opt/nuclei-templates/ -severity critical,high,medium
96
+
97
+ # SSL/TLS configuration
98
+ sslyze --regular target.example.com:443
99
+
100
+ # Directory and path discovery
101
+ feroxbuster -u https://target.example.com -w /usr/share/wordlists/dirb/common.txt
102
+ ```
103
+
104
+ **Manual techniques:**
105
+ - Review all input fields for injection opportunities
106
+ - Test authentication flows manually
107
+ - Examine session management (cookie attributes, token entropy)
108
+ - Check access control by testing role boundaries
109
+ - Review security headers in all responses
110
+
111
+ ### Phase 5: Exploitation
112
+
113
+ Attempt to confirm vulnerabilities by safely exploiting them within scope.
114
+
115
+ **Exploitation principles:**
116
+ - Confirm vulnerability, do not cause harm
117
+ - Avoid denial of service or data destruction
118
+ - Document every action with timestamps
119
+ - Stop immediately if you exceed scope or find unexpected sensitive data
120
+ - Escalate to client immediately if you find evidence of a pre-existing breach
121
+
122
+ **Burp Suite Professional workflow:**
123
+ ```
124
+ 1. Configure browser proxy → Burp Proxy (127.0.0.1:8080)
125
+ 2. Spider/crawl target to map attack surface
126
+ 3. Run active scanner against scope
127
+ 4. Review scanner findings in Burp Dashboard
128
+ 5. Manual exploitation via Burp Repeater
129
+ 6. Track all requests in Burp Project
130
+ ```
131
+
132
+ ### Phase 6: Post-Exploitation
133
+
134
+ Assess the real-world impact of confirmed vulnerabilities:
135
+ - What data is accessible?
136
+ - Can the compromise spread to other systems (lateral movement risk)?
137
+ - What is the business impact of the vulnerability?
138
+ - Can the attacker persist (would they establish persistence in a real attack)?
139
+
140
+ **Document for report:**
141
+ - Screenshot of successful exploitation
142
+ - Data accessed (record existence, not full contents)
143
+ - Privilege level achieved
144
+ - Potential blast radius
145
+
146
+ ### Phase 7: Reporting
147
+
148
+ Produce actionable, audience-appropriate findings.
149
+
150
+ ---
151
+
152
+ ## Reporting Standards
153
+
154
+ ### Finding Severity Classification
155
+
156
+ Use CVSS v3.1 for consistent scoring:
157
+
158
+ | Severity | CVSS Score | Remediation SLA | Definition |
159
+ |----------|-----------|----------------|------------|
160
+ | **Critical** | 9.0–10.0 | 24–48 hours | Remote code execution, unauthenticated data breach |
161
+ | **High** | 7.0–8.9 | 7 days | Auth bypass, significant data exposure |
162
+ | **Medium** | 4.0–6.9 | 30 days | Requires auth, limited impact |
163
+ | **Low** | 0.1–3.9 | 90 days | Defense-in-depth issues, information disclosure |
164
+ | **Informational** | 0.0 | Next cycle | Best practice improvements |
165
+
166
+ ### Finding Template
167
+
168
+ Every finding should contain:
169
+ ```
170
+ Title: [Concise description]
171
+ Severity: [Critical/High/Medium/Low/Informational]
172
+ CVSS Score: [X.X]
173
+ CVE Reference: [If applicable]
174
+
175
+ Description:
176
+ [What the vulnerability is and why it matters]
177
+
178
+ Affected Systems:
179
+ [Specific URLs, endpoints, or components]
180
+
181
+ Evidence:
182
+ [Screenshots, request/response, proof of concept]
183
+
184
+ Impact:
185
+ [Business impact if exploited by a real attacker]
186
+
187
+ Remediation:
188
+ [Specific, actionable fix instructions]
189
+
190
+ References:
191
+ [OWASP, CVE, vendor docs]
192
+ ```
193
+
194
+ ---
195
+
196
+ ## Tool Reference
197
+
198
+ ### Core Toolchain
199
+
200
+ | Tool | Category | License | Primary Use |
201
+ |------|----------|---------|-------------|
202
+ | **Burp Suite Pro** | DAST | Commercial | Web app testing, manual exploitation |
203
+ | **OWASP ZAP** | DAST | Free/Open Source | CI/CD automation, budget-constrained tests |
204
+ | **Nmap** | Network | Free/Open Source | Port scanning, service discovery |
205
+ | **Metasploit** | Exploitation | Free/Commercial | Exploit framework, post-exploitation |
206
+ | **Nuclei** | Scanner | Free/Open Source | Template-based vulnerability scanning |
207
+ | **Semgrep** | SAST | Free/Commercial | Static code analysis |
208
+ | **Snyk** | SCA | Free/Commercial | Dependency vulnerability scanning |
209
+ | **SQLmap** | Injection | Free/Open Source | Automated SQL injection |
210
+ | **Hydra / Medusa** | Auth | Free/Open Source | Brute force (authorized tests only) |
211
+ | **Gobuster / Feroxbuster** | Recon | Free/Open Source | Directory and file discovery |
212
+ | **SSLyze** | TLS | Free/Open Source | SSL/TLS configuration testing |
213
+
214
+ ### For Beginners — Progressive Stack
215
+
216
+ **Phase 1 (Learning):**
217
+ 1. OWASP ZAP in automatic mode — spider + active scan
218
+ 2. `npm audit` for dependency vulnerabilities
219
+ 3. Semgrep for SAST basics
220
+
221
+ **Phase 2 (Intermediate):**
222
+ 4. Burp Suite Community (learn the proxy)
223
+ 5. Nmap for infrastructure assessment
224
+ 6. Nuclei with community templates
225
+
226
+ **Phase 3 (Professional):**
227
+ 7. Burp Suite Professional (license)
228
+ 8. Custom Nuclei templates for client-specific checks
229
+ 9. Manual exploitation techniques
230
+
231
+ ---
232
+
233
+ ## OWASP Testing Guide Categories (v4.2)
234
+
235
+ The OWASP Testing Guide (OTG) provides the most comprehensive methodology for web application testing:
236
+
237
+ | Category | Key Tests |
238
+ |----------|----------|
239
+ | **OTG-INFO** Information Gathering | Fingerprinting, search engine discovery, web server analysis |
240
+ | **OTG-CONFIG** Configuration | Network/infrastructure config, application platform, HTTP methods |
241
+ | **OTG-IDENT** Identity Management | User registration, account provisioning, username policy |
242
+ | **OTG-AUTHN** Authentication | Credentials over encrypted channel, default credentials, brute force |
243
+ | **OTG-AUTHZ** Authorization | Directory traversal, privilege escalation, IDOR, OAuth testing |
244
+ | **OTG-SESS** Session Management | Cookie attributes, session fixation, CSRF, logout |
245
+ | **OTG-INPVAL** Input Validation | XSS, SQL injection, HTTP injection, XML injection, code injection |
246
+ | **OTG-ERR** Error Handling | Error codes, stack traces |
247
+ | **OTG-CRYPST** Cryptography | Weak SSL, padding oracle, sensitive data in transit |
248
+ | **OTG-BUSLOGIC** Business Logic | Data validation, process flow, file upload |
249
+ | **OTG-CLIENT** Client-Side Testing | DOM-based XSS, PostMessage, clickjacking |
250
+
251
+ ---
252
+
253
+ ## API Security Testing
254
+
255
+ ### REST API Test Checklist
256
+
257
+ ```
258
+ Authentication
259
+ [ ] Endpoints accessible without auth tokens
260
+ [ ] Auth tokens transmitted securely (HTTPS, not URL params)
261
+ [ ] Token expiration enforced
262
+ [ ] Token revocation works (logout invalidates token)
263
+
264
+ Authorization
265
+ [ ] BOLA: can user A access user B's resources by changing IDs?
266
+ [ ] BFLA: can user access admin functions without admin role?
267
+ [ ] Mass assignment: does API accept undocumented parameters that affect auth?
268
+
269
+ Input Validation
270
+ [ ] Injection in all string parameters (SQL, NoSQL, command)
271
+ [ ] Path traversal in file-related endpoints
272
+ [ ] XML/JSON deserialization risks
273
+
274
+ Business Logic
275
+ [ ] Rate limiting on resource-intensive endpoints
276
+ [ ] Can users exceed intended limits (purchase 0-price items, negative quantities)?
277
+ [ ] Workflow enforcement (can user skip required steps?)
278
+
279
+ Infrastructure
280
+ [ ] Security headers present
281
+ [ ] API version disclosure (avoid version in response if possible)
282
+ [ ] Error messages don't expose internal details
283
+ ```
284
+
285
+ ### GraphQL-Specific Tests
286
+
287
+ ```bash
288
+ # Introspection (should be disabled in production)
289
+ curl -X POST https://api.target.com/graphql \
290
+ -H "Content-Type: application/json" \
291
+ -d '{"query":"{__schema{types{name}}}"}'
292
+
293
+ # Batch query attack (no rate limiting on batches)
294
+ # [{"query":"query1"},{"query":"query2"},...] x100
295
+
296
+ # Field suggestion (typos reveal valid field names)
297
+ # GraphQL returns "Did you mean X?" — information disclosure
298
+ ```
299
+
300
+ ---
301
+
302
+ ## Cloud Environment Testing
303
+
304
+ ### AWS Security Assessment
305
+
306
+ Key areas to test with explicit authorization:
307
+
308
+ ```bash
309
+ # IAM privilege analysis (with legitimate credentials)
310
+ # Check for privilege escalation paths
311
+ python3 enumerate_iam.py
312
+
313
+ # S3 bucket exposure (requires authorization)
314
+ aws s3 ls s3://bucket-name --no-sign-request # Check for public access
315
+
316
+ # EC2 metadata service exposure
317
+ # Test if SSRF can reach: http://169.254.169.254/latest/meta-data/
318
+
319
+ # Lambda function permissions
320
+ aws lambda get-policy --function-name my-function
321
+
322
+ # Check for IMDSv1 (should be disabled — SSRF risk)
323
+ aws ec2 describe-instances --query "Reservations[].Instances[].MetadataOptions"
324
+ ```
325
+
326
+ ### Kubernetes Security Assessment
327
+
328
+ ```bash
329
+ # RBAC analysis
330
+ kubectl auth can-i --list --as=system:serviceaccount:default:myapp
331
+
332
+ # Check for privileged pods
333
+ kubectl get pods -A -o json | jq '.items[].spec.containers[].securityContext'
334
+
335
+ # Network policy coverage
336
+ kubectl get networkpolicies -A
337
+
338
+ # Check for secrets in env vars (common misconfiguration)
339
+ kubectl get pods -A -o json | jq '.items[].spec.containers[].env'
340
+ ```
341
+
342
+ ---
343
+
344
+ ## Sources
345
+
346
+ - PTES: http://www.pentest-standard.org/
347
+ - OWASP Testing Guide v4.2: https://owasp.org/www-project-web-security-testing-guide/
348
+ - OWASP API Security Testing Guide: https://owasp.org/www-project-api-security/
349
+ - OWASP Cheat Sheet Series: https://cheatsheetseries.owasp.org/
350
+ - HackTricks: https://book.hacktricks.xyz/ (for methodology reference — authorized tests only)
@@ -0,0 +1,349 @@
1
+ # Vulnerability Management Reference
2
+
3
+ ## Purpose
4
+
5
+ Reference for the full vulnerability management lifecycle — CVE process, scanning tools, patch management SLAs, and remediation prioritization. Used by Breach (penetration-tester), Sentinel (soc-analyst), and Govern (compliance-officer).
6
+
7
+ ---
8
+
9
+ ## Vulnerability Management Lifecycle
10
+
11
+ ```
12
+ Discovery → Assessment → Prioritization → Remediation → Verification → Reporting
13
+ ↑ |
14
+ └───────────────────── Continuous cycle ───────────────────────────────┘
15
+ ```
16
+
17
+ ---
18
+
19
+ ## CVE Process
20
+
21
+ ### The CVE System
22
+
23
+ **CVE (Common Vulnerabilities and Exposures):** A standardized identifier system for known security vulnerabilities. Managed by MITRE Corporation with support from CISA.
24
+
25
+ **CVE ID format:** CVE-[YEAR]-[NUMBER] (e.g., CVE-2021-44228 = Log4Shell)
26
+
27
+ **NVD (National Vulnerability Database):** NIST-maintained database that enriches CVEs with CVSS scores, affected products (CPE), and remediation guidance. Every CVE gets scored in NVD.
28
+
29
+ **CVSS (Common Vulnerability Scoring System) v3.1:**
30
+ | Score | Severity | Remediation SLA (Production) |
31
+ |-------|---------|------------------------------|
32
+ | 9.0–10.0 | Critical | 24–48 hours |
33
+ | 7.0–8.9 | High | 7 days |
34
+ | 4.0–6.9 | Medium | 30 days |
35
+ | 0.1–3.9 | Low | 90 days |
36
+ | 0.0 | None | Best effort |
37
+
38
+ **EPSS (Exploit Prediction Scoring System):** Complements CVSS — predicts the probability a vulnerability will be exploited in the wild within the next 30 days. A CVSS 7.0 vulnerability with EPSS > 50% should be treated as critical-urgency. Check at: https://api.first.org/data/v1/epss
39
+
40
+ ---
41
+
42
+ ## Vulnerability Scanning
43
+
44
+ ### Scanning Architecture
45
+
46
+ ```
47
+ Continuous scanning (daily/weekly):
48
+ SCA (dependencies) → SAST (code) → DAST (running app) → Infrastructure
49
+
50
+ Point-in-time (pre-deploy, quarterly):
51
+ Penetration test → Configuration audit → Red team exercise
52
+ ```
53
+
54
+ ### Dependency Scanning (SCA)
55
+
56
+ ```bash
57
+ # npm audit (built-in)
58
+ npm audit
59
+ npm audit --audit-level=high # Exit non-zero only for high+
60
+ npm audit fix # Auto-fix non-breaking changes
61
+
62
+ # Snyk (richer data, fixability scoring)
63
+ npx snyk test
64
+ npx snyk monitor # Track over time
65
+
66
+ # OWASP Dependency-Check (Java/.NET, also supports npm)
67
+ dependency-check --project "MyProject" --scan ./
68
+
69
+ # Trivy (containers + filesystems)
70
+ trivy fs --severity HIGH,CRITICAL .
71
+ trivy image --severity HIGH,CRITICAL myapp:latest
72
+ ```
73
+
74
+ ### Static Analysis (SAST)
75
+
76
+ ```bash
77
+ # Semgrep -- fast, rules-based
78
+ semgrep --config=auto .
79
+ semgrep --config=p/security-audit .
80
+ semgrep --config=p/owasp-top-ten .
81
+
82
+ # Custom rules example
83
+ # .semgrep/rules/no-hardcoded-secrets.yaml
84
+ rules:
85
+ - id: no-hardcoded-api-key
86
+ patterns:
87
+ - pattern: $KEY = "sk_live_..."
88
+ - pattern: $KEY = "AKIA..."
89
+ message: Potential hardcoded API key detected
90
+ severity: ERROR
91
+ languages: [javascript, typescript]
92
+
93
+ # CodeQL (GitHub Advanced Security)
94
+ # Enable in GitHub repository settings -- free for public repos
95
+ # Runs automatically on PRs
96
+
97
+ # SonarQube/SonarCloud
98
+ sonar-scanner \
99
+ -Dsonar.projectKey=my-project \
100
+ -Dsonar.sources=./src \
101
+ -Dsonar.host.url=https://sonarcloud.io \
102
+ -Dsonar.login=$SONAR_TOKEN
103
+ ```
104
+
105
+ ### Dynamic Scanning (DAST)
106
+
107
+ ```bash
108
+ # OWASP ZAP -- automated scan
109
+ # Full scan (comprehensive, use in QA/staging)
110
+ docker run -t owasp/zap2docker-stable zap-full-scan.py \
111
+ -t https://staging.myapp.com \
112
+ -r zap-report.html
113
+
114
+ # Baseline scan (passive, safe for production checks)
115
+ docker run -t owasp/zap2docker-stable zap-baseline.py \
116
+ -t https://myapp.com
117
+
118
+ # Nuclei -- template-based
119
+ nuclei -u https://staging.myapp.com \
120
+ -t /opt/nuclei-templates/ \
121
+ -severity critical,high,medium \
122
+ -o nuclei-results.json
123
+ ```
124
+
125
+ ### Infrastructure Scanning
126
+
127
+ ```bash
128
+ # Nmap -- port and service discovery
129
+ nmap -sV -sC --open -T4 -p 1-65535 target.example.com
130
+
131
+ # SSL/TLS configuration
132
+ sslyze --regular target.example.com:443
133
+ testssl.sh target.example.com
134
+
135
+ # Shodan (check what's exposed on the internet)
136
+ shodan host <your-ip> # Requires Shodan API key
137
+
138
+ # Check for exposed services using Shodan
139
+ shodan search "org:MyCompany" --fields "ip_str,port,product"
140
+ ```
141
+
142
+ ---
143
+
144
+ ## Prioritization Framework
145
+
146
+ ### Risk-Based Prioritization
147
+
148
+ Not all vulnerabilities are equal. Prioritize based on:
149
+
150
+ ```
151
+ Priority Score = Severity × Exploitability × Business Impact × Exposure
152
+
153
+ High Priority:
154
+ - CVSS 9.0+ AND EPSS > 20%
155
+ - Any CVE with known public exploit
156
+ - Vulnerability in public-facing system
157
+ - Vulnerability enabling RCE or data exfiltration
158
+
159
+ Medium Priority:
160
+ - CVSS 7.0–8.9, no public exploit
161
+ - CVSS 9.0+ in internal system only
162
+ - Information disclosure vulnerabilities
163
+
164
+ Lower Priority:
165
+ - CVSS < 7.0
166
+ - Requires physical access
167
+ - Requires authenticated access in already-trusted context
168
+ ```
169
+
170
+ ### Remediation SLA Matrix
171
+
172
+ | Severity | EPSS > 50% | EPSS < 50% | In Active Exploitation |
173
+ |----------|-----------|-----------|----------------------|
174
+ | Critical | 24 hours | 48 hours | IMMEDIATE — escalate now |
175
+ | High | 48 hours | 7 days | 24 hours |
176
+ | Medium | 7 days | 30 days | 7 days |
177
+ | Low | 30 days | 90 days | 30 days |
178
+
179
+ ### CISA Known Exploited Vulnerabilities (KEV) Catalog
180
+
181
+ CISA maintains a catalog of vulnerabilities known to be actively exploited. If a CVE appears on this list, treat it as critical regardless of CVSS score.
182
+
183
+ Check: https://www.cisa.gov/known-exploited-vulnerabilities-catalog
184
+
185
+ ```bash
186
+ # Check if your CVEs are in KEV catalog
187
+ curl -s https://www.cisa.gov/sites/default/files/feeds/known_exploited_vulnerabilities.json | \
188
+ jq '.vulnerabilities[] | select(.cveID == "CVE-2021-44228")'
189
+ ```
190
+
191
+ ---
192
+
193
+ ## Patch Management
194
+
195
+ ### Patching Process
196
+
197
+ ```
198
+ 1. Vulnerability Identified
199
+
200
+ 2. Asset impact analysis (which systems are affected?)
201
+
202
+ 3. Risk assessment (CVSS + EPSS + exposure)
203
+
204
+ 4. Patch availability check (vendor advisory, fix available?)
205
+
206
+ 5. Testing (test patch in non-production environment)
207
+
208
+ 6. Approval (change management process)
209
+
210
+ 7. Deployment (rolling update or maintenance window)
211
+
212
+ 8. Verification (rescan to confirm vulnerability closed)
213
+
214
+ 9. Documentation (update vulnerability records)
215
+ ```
216
+
217
+ ### Zero-Day Management (No Patch Available)
218
+
219
+ When a patch is not yet available, implement mitigations:
220
+
221
+ **Temporary mitigations:**
222
+ - WAF rules to block known exploit patterns
223
+ - Network segmentation to limit blast radius
224
+ - Disable vulnerable feature if not required
225
+ - Enhanced monitoring for exploitation indicators
226
+ - Rate limiting on affected endpoints
227
+
228
+ **Log4Shell example (December 2021):**
229
+ ```
230
+ Day 0 (no patch):
231
+ 1. Deployed WAF rules blocking JNDI lookup strings in request headers/body
232
+ 2. Disabled JNDI lookups via JVM flag: -Dlog4j2.formatMsgNoLookups=true
233
+ 3. Enhanced monitoring for outbound LDAP/DNS to unknown hosts
234
+ 4. Isolated affected systems from sensitive data stores
235
+
236
+ Day 3 (patch available):
237
+ 5. Updated to Log4j 2.16.0
238
+ 6. Verified across all applications via SBOM scan
239
+ 7. Removed temporary WAF rules
240
+ ```
241
+
242
+ ---
243
+
244
+ ## Continuous Scanning Pipeline
245
+
246
+ ### GitHub Actions Security Pipeline
247
+
248
+ ```yaml
249
+ name: Security Scanning
250
+
251
+ on:
252
+ push:
253
+ branches: [main, develop]
254
+ pull_request:
255
+ schedule:
256
+ - cron: '0 2 * * 1' # Weekly Monday 2 AM
257
+
258
+ jobs:
259
+ dependency-scan:
260
+ runs-on: ubuntu-latest
261
+ steps:
262
+ - uses: actions/checkout@v4
263
+
264
+ - name: npm audit
265
+ run: npm audit --audit-level=high
266
+
267
+ - name: Snyk SCA
268
+ uses: snyk/actions/node@master
269
+ env:
270
+ SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
271
+ with:
272
+ args: --severity-threshold=high
273
+
274
+ sast-scan:
275
+ runs-on: ubuntu-latest
276
+ steps:
277
+ - uses: actions/checkout@v4
278
+
279
+ - name: Semgrep SAST
280
+ uses: returntocorp/semgrep-action@v1
281
+ with:
282
+ config: >-
283
+ p/security-audit
284
+ p/owasp-top-ten
285
+
286
+ container-scan:
287
+ runs-on: ubuntu-latest
288
+ steps:
289
+ - name: Build image
290
+ run: docker build -t myapp:${{ github.sha }} .
291
+
292
+ - name: Trivy container scan
293
+ uses: aquasecurity/trivy-action@master
294
+ with:
295
+ image-ref: myapp:${{ github.sha }}
296
+ format: sarif
297
+ exit-code: 1
298
+ severity: HIGH,CRITICAL
299
+ output: trivy-results.sarif
300
+
301
+ - name: Upload to GitHub Security
302
+ uses: github/codeql-action/upload-sarif@v3
303
+ with:
304
+ sarif_file: trivy-results.sarif
305
+ ```
306
+
307
+ ---
308
+
309
+ ## Vulnerability Metrics and Reporting
310
+
311
+ ### Key Metrics to Track
312
+
313
+ | Metric | Definition | Target |
314
+ |--------|-----------|--------|
315
+ | MTTD | Mean Time to Detect (from introduction to discovery) | < 24 hours for critical |
316
+ | MTTR | Mean Time to Remediate (from discovery to fix) | Per SLA above |
317
+ | Vulnerability backlog | Open vulns by severity | Critical: 0, High: < 5 |
318
+ | Patch compliance rate | % of systems patched within SLA | > 95% |
319
+ | Vulnerability density | Vulns per 1000 lines of code | Trend down over time |
320
+
321
+ ### Vulnerability Tracking
322
+
323
+ Every vulnerability should be tracked in your issue tracking system with:
324
+
325
+ ```
326
+ Title: [CVE-ID] Vulnerability description in component X
327
+ Severity: [Critical/High/Medium/Low]
328
+ CVSS Score: X.X
329
+ EPSS Score: XX%
330
+ Affected systems: [list]
331
+ Discovered: [date]
332
+ Due date: [per SLA]
333
+ Owner: [person responsible]
334
+ Status: [Open/In Progress/Remediated/Accepted Risk]
335
+ Mitigation: [if patch not yet available]
336
+ Verification: [rescan result confirming fix]
337
+ ```
338
+
339
+ ---
340
+
341
+ ## Sources
342
+
343
+ - NVD (NIST): https://nvd.nist.gov/
344
+ - FIRST CVSS Calculator: https://www.first.org/cvss/calculator/3.1
345
+ - EPSS API: https://api.first.org/data/v1/epss
346
+ - CISA KEV Catalog: https://www.cisa.gov/known-exploited-vulnerabilities-catalog
347
+ - OWASP Dependency-Check: https://owasp.org/www-project-dependency-check/
348
+ - Trivy: https://aquasecurity.github.io/trivy/
349
+ - Semgrep: https://semgrep.dev/docs/