@thierrynakoa/fire-flow 10.0.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/.claude-plugin/plugin.json +64 -0
- package/ARCHITECTURE-DIAGRAM.md +440 -0
- package/COMMAND-REFERENCE.md +172 -0
- package/DOMINION-FLOW-OVERVIEW.md +421 -0
- package/LICENSE +21 -0
- package/QUICK-START.md +351 -0
- package/README.md +398 -0
- package/TROUBLESHOOTING.md +264 -0
- package/agents/fire-codebase-mapper.md +484 -0
- package/agents/fire-debugger.md +535 -0
- package/agents/fire-executor.md +949 -0
- package/agents/fire-fact-checker.md +276 -0
- package/agents/fire-learncoding-explainer.md +237 -0
- package/agents/fire-learncoding-walker.md +147 -0
- package/agents/fire-planner.md +675 -0
- package/agents/fire-project-researcher.md +155 -0
- package/agents/fire-research-synthesizer.md +166 -0
- package/agents/fire-researcher.md +723 -0
- package/agents/fire-reviewer.md +499 -0
- package/agents/fire-roadmapper.md +203 -0
- package/agents/fire-verifier.md +880 -0
- package/bin/cli.js +208 -0
- package/commands/fire-0-orient.md +476 -0
- package/commands/fire-1-new.md +281 -0
- package/commands/fire-1a-discuss.md +455 -0
- package/commands/fire-2-plan.md +527 -0
- package/commands/fire-3-execute.md +1303 -0
- package/commands/fire-4-verify.md +845 -0
- package/commands/fire-5-handoff.md +515 -0
- package/commands/fire-6-resume.md +501 -0
- package/commands/fire-7-review.md +409 -0
- package/commands/fire-add-new-skill.md +598 -0
- package/commands/fire-analytics.md +499 -0
- package/commands/fire-assumptions.md +78 -0
- package/commands/fire-autonomous.md +528 -0
- package/commands/fire-brainstorm.md +413 -0
- package/commands/fire-complete-milestone.md +270 -0
- package/commands/fire-dashboard.md +375 -0
- package/commands/fire-debug.md +663 -0
- package/commands/fire-discover.md +616 -0
- package/commands/fire-double-check.md +460 -0
- package/commands/fire-execute-plan.md +182 -0
- package/commands/fire-learncoding.md +242 -0
- package/commands/fire-loop-resume.md +272 -0
- package/commands/fire-loop-stop.md +198 -0
- package/commands/fire-loop.md +1168 -0
- package/commands/fire-map-codebase.md +313 -0
- package/commands/fire-new-milestone.md +356 -0
- package/commands/fire-reflect.md +235 -0
- package/commands/fire-research.md +246 -0
- package/commands/fire-search.md +330 -0
- package/commands/fire-security-audit-repo.md +293 -0
- package/commands/fire-security-scan.md +484 -0
- package/commands/fire-session-summary.md +252 -0
- package/commands/fire-skills-diff.md +506 -0
- package/commands/fire-skills-history.md +388 -0
- package/commands/fire-skills-rollback.md +408 -0
- package/commands/fire-skills-sync.md +470 -0
- package/commands/fire-test.md +520 -0
- package/commands/fire-todos.md +335 -0
- package/commands/fire-transition.md +186 -0
- package/commands/fire-update.md +312 -0
- package/commands/fire-verify-uat.md +146 -0
- package/commands/fire-vuln-scan.md +493 -0
- package/hooks/hooks.json +16 -0
- package/hooks/run-hook.cmd +69 -0
- package/hooks/run-hook.sh +8 -0
- package/hooks/run-session-end.cmd +49 -0
- package/hooks/run-session-end.sh +7 -0
- package/hooks/session-end.sh +90 -0
- package/hooks/session-start.sh +111 -0
- package/package.json +52 -0
- package/plugin.json +7 -0
- package/references/auto-skill-extraction.md +136 -0
- package/references/behavioral-directives.md +365 -0
- package/references/blocker-tracking.md +155 -0
- package/references/checkpoints.md +165 -0
- package/references/circuit-breaker.md +410 -0
- package/references/context-engineering.md +587 -0
- package/references/decision-time-guidance.md +289 -0
- package/references/error-classification.md +326 -0
- package/references/execution-mode-intelligence.md +242 -0
- package/references/git-integration.md +217 -0
- package/references/honesty-protocols.md +304 -0
- package/references/integration-architecture.md +470 -0
- package/references/issue-to-pr-pipeline.md +150 -0
- package/references/metrics-and-trends.md +234 -0
- package/references/playwright-e2e-testing.md +326 -0
- package/references/questioning.md +125 -0
- package/references/research-improvements.md +110 -0
- package/references/skills-usage-guide.md +429 -0
- package/references/tdd.md +131 -0
- package/references/testing-enforcement.md +192 -0
- package/references/ui-brand.md +383 -0
- package/references/validation-checklist.md +456 -0
- package/references/verification-patterns.md +187 -0
- package/references/warrior-principles.md +173 -0
- package/skills-library/SKILLS-INDEX.md +588 -0
- package/skills-library/_general/frontend/html-visual-reports.md +292 -0
- package/skills-library/_general/methodology/debug-swarm-researcher-escape-hatch.md +240 -0
- package/skills-library/_general/methodology/learncoding-agentic-pattern.md +114 -0
- package/skills-library/_general/methodology/shell-autonomous-loop-fixplan.md +238 -0
- package/skills-library/basics/api-rest-basics.md +162 -0
- package/skills-library/basics/env-variables.md +96 -0
- package/skills-library/basics/error-handling-basics.md +125 -0
- package/skills-library/basics/git-commit-conventions.md +106 -0
- package/skills-library/basics/readme-template.md +108 -0
- package/skills-library/common-tasks/async-await-patterns.md +157 -0
- package/skills-library/common-tasks/auth-jwt-basics.md +164 -0
- package/skills-library/common-tasks/database-schema-design.md +166 -0
- package/skills-library/common-tasks/file-upload-basics.md +166 -0
- package/skills-library/common-tasks/form-validation.md +159 -0
- package/skills-library/debugging/FAILURE_TAXONOMY_CLASSIFICATION.md +117 -0
- package/skills-library/debugging/THREE_AGENT_HYPOTHESIS_DEBUGGING.md +86 -0
- package/skills-library/methodology/BREATH_BASED_PARALLEL_EXECUTION.md +678 -0
- package/skills-library/methodology/CONFIDENCE_GATED_EXECUTION.md +243 -0
- package/skills-library/methodology/EVIDENCE_BASED_VALIDATION.md +308 -0
- package/skills-library/methodology/MULTI_PERSPECTIVE_CODE_REVIEW.md +330 -0
- package/skills-library/methodology/PATH_VERIFICATION_GATE.md +211 -0
- package/skills-library/methodology/REFLEXION_MEMORY_PATTERN.md +183 -0
- package/skills-library/methodology/RESEARCH_BACKED_WORKFLOW_UPGRADE.md +263 -0
- package/skills-library/methodology/SABBATH_REST_PATTERN.md +267 -0
- package/skills-library/methodology/STONE_AND_SCAFFOLD.md +220 -0
- package/skills-library/performance/cache-augmented-generation.md +172 -0
- package/skills-library/quality-safety/debugging-steps.md +147 -0
- package/skills-library/quality-safety/deployment-checklist.md +155 -0
- package/skills-library/quality-safety/security-checklist.md +204 -0
- package/skills-library/quality-safety/testing-basics.md +180 -0
- package/skills-library/security/agent-security-scanner.md +445 -0
- package/skills-library/specialists/api-architecture/api-designer.md +49 -0
- package/skills-library/specialists/api-architecture/graphql-architect.md +49 -0
- package/skills-library/specialists/api-architecture/mcp-developer.md +51 -0
- package/skills-library/specialists/api-architecture/microservices-architect.md +50 -0
- package/skills-library/specialists/api-architecture/websocket-engineer.md +48 -0
- package/skills-library/specialists/backend/django-expert.md +52 -0
- package/skills-library/specialists/backend/fastapi-expert.md +52 -0
- package/skills-library/specialists/backend/laravel-specialist.md +52 -0
- package/skills-library/specialists/backend/nestjs-expert.md +51 -0
- package/skills-library/specialists/backend/rails-expert.md +53 -0
- package/skills-library/specialists/backend/spring-boot-engineer.md +56 -0
- package/skills-library/specialists/data-ml/fine-tuning-expert.md +48 -0
- package/skills-library/specialists/data-ml/ml-pipeline.md +47 -0
- package/skills-library/specialists/data-ml/pandas-pro.md +47 -0
- package/skills-library/specialists/data-ml/rag-architect.md +51 -0
- package/skills-library/specialists/data-ml/spark-engineer.md +47 -0
- package/skills-library/specialists/frontend/angular-architect.md +52 -0
- package/skills-library/specialists/frontend/flutter-expert.md +51 -0
- package/skills-library/specialists/frontend/nextjs-developer.md +54 -0
- package/skills-library/specialists/frontend/react-native-expert.md +50 -0
- package/skills-library/specialists/frontend/vue-expert.md +51 -0
- package/skills-library/specialists/infrastructure/chaos-engineer.md +74 -0
- package/skills-library/specialists/infrastructure/cloud-architect.md +70 -0
- package/skills-library/specialists/infrastructure/database-optimizer.md +64 -0
- package/skills-library/specialists/infrastructure/devops-engineer.md +70 -0
- package/skills-library/specialists/infrastructure/kubernetes-specialist.md +52 -0
- package/skills-library/specialists/infrastructure/monitoring-expert.md +70 -0
- package/skills-library/specialists/infrastructure/sre-engineer.md +70 -0
- package/skills-library/specialists/infrastructure/terraform-engineer.md +51 -0
- package/skills-library/specialists/languages/cpp-pro.md +74 -0
- package/skills-library/specialists/languages/csharp-developer.md +69 -0
- package/skills-library/specialists/languages/dotnet-core-expert.md +54 -0
- package/skills-library/specialists/languages/golang-pro.md +51 -0
- package/skills-library/specialists/languages/java-architect.md +49 -0
- package/skills-library/specialists/languages/javascript-pro.md +68 -0
- package/skills-library/specialists/languages/kotlin-specialist.md +68 -0
- package/skills-library/specialists/languages/php-pro.md +49 -0
- package/skills-library/specialists/languages/python-pro.md +52 -0
- package/skills-library/specialists/languages/react-expert.md +51 -0
- package/skills-library/specialists/languages/rust-engineer.md +50 -0
- package/skills-library/specialists/languages/sql-pro.md +56 -0
- package/skills-library/specialists/languages/swift-expert.md +69 -0
- package/skills-library/specialists/languages/typescript-pro.md +51 -0
- package/skills-library/specialists/platform/atlassian-mcp.md +52 -0
- package/skills-library/specialists/platform/embedded-systems.md +53 -0
- package/skills-library/specialists/platform/game-developer.md +53 -0
- package/skills-library/specialists/platform/salesforce-developer.md +53 -0
- package/skills-library/specialists/platform/shopify-expert.md +49 -0
- package/skills-library/specialists/platform/wordpress-pro.md +49 -0
- package/skills-library/specialists/quality/code-documenter.md +51 -0
- package/skills-library/specialists/quality/code-reviewer.md +67 -0
- package/skills-library/specialists/quality/debugging-wizard.md +51 -0
- package/skills-library/specialists/quality/fullstack-guardian.md +51 -0
- package/skills-library/specialists/quality/legacy-modernizer.md +50 -0
- package/skills-library/specialists/quality/playwright-expert.md +65 -0
- package/skills-library/specialists/quality/spec-miner.md +56 -0
- package/skills-library/specialists/quality/test-master.md +65 -0
- package/skills-library/specialists/security/secure-code-guardian.md +55 -0
- package/skills-library/specialists/security/security-reviewer.md +53 -0
- package/skills-library/specialists/workflow/architecture-designer.md +53 -0
- package/skills-library/specialists/workflow/cli-developer.md +70 -0
- package/skills-library/specialists/workflow/feature-forge.md +65 -0
- package/skills-library/specialists/workflow/prompt-engineer.md +54 -0
- package/skills-library/specialists/workflow/the-fool.md +62 -0
- package/templates/ASSUMPTIONS.md +125 -0
- package/templates/BLOCKERS.md +73 -0
- package/templates/DECISION_LOG.md +116 -0
- package/templates/UAT.md +96 -0
- package/templates/blueprint.md +94 -0
- package/templates/brainstorm.md +185 -0
- package/templates/conscience.md +92 -0
- package/templates/fire-handoff.md +159 -0
- package/templates/metrics.md +67 -0
- package/templates/phase-prompt.md +142 -0
- package/templates/record.md +131 -0
- package/templates/review-report.md +117 -0
- package/templates/skills-index.md +157 -0
- package/templates/verification.md +149 -0
- package/templates/vision.md +79 -0
- package/validation-config.yml +793 -0
- package/version.json +7 -0
- package/workflows/execute-phase.md +732 -0
- package/workflows/handoff-session.md +678 -0
- package/workflows/new-project.md +578 -0
- package/workflows/plan-phase.md +592 -0
- package/workflows/verify-phase.md +874 -0
|
@@ -0,0 +1,493 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: AI-powered application vulnerability scanner using OWASP Top 10 — find what regex-based tools miss
|
|
3
|
+
argument-hint: "[path] [--deep] [--category injection|auth|data|config|mern|all] [--fix-preview] [--report] [--server-only] [--client-only] [--critical-only]"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# /fire-vuln-scan
|
|
7
|
+
|
|
8
|
+
> AI-powered application vulnerability scanner — find what regex-based tools miss
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## Purpose
|
|
13
|
+
|
|
14
|
+
Scan application codebases for OWASP Top 10 vulnerabilities using Claude's code reasoning — not pattern matching. Inspired by Anthropic's Claude Code Security (launched 2026-02-20), which found 500+ bugs that humans missed for decades.
|
|
15
|
+
|
|
16
|
+
**What this is:** Application security scanner (finds SQL injection, XSS, broken auth in YOUR code)
|
|
17
|
+
**What this is NOT:** Agent security scanner (that's `/fire-security-scan` — protects Claude from prompt injection)
|
|
18
|
+
|
|
19
|
+
**Research basis:** Claude Code Security (Anthropic 2026), OWASP Top 10 2021, OWASP Agentic Top 10 2026, Agent-as-Judge self-verification (95% error recovery)
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
## Arguments
|
|
24
|
+
|
|
25
|
+
```yaml
|
|
26
|
+
arguments:
|
|
27
|
+
target_path:
|
|
28
|
+
required: false
|
|
29
|
+
type: string
|
|
30
|
+
description: "Directory or file to scan. Defaults to current project root."
|
|
31
|
+
example: "/fire-vuln-scan c:\\path\\repos\\MY-PROJECT"
|
|
32
|
+
|
|
33
|
+
optional_flags:
|
|
34
|
+
--deep: "AI-powered reasoning trace per finding (slower, fewer false positives)"
|
|
35
|
+
--category: "Focus on one category: injection | auth | data | config | mern | all (default: all)"
|
|
36
|
+
--fix-preview: "Show suggested fix code for each finding"
|
|
37
|
+
--report: "Save full report to .planning/security/ AND Claude Reports folder"
|
|
38
|
+
--server-only: "Scan only server-side code (skip client/frontend)"
|
|
39
|
+
--client-only: "Scan only client-side code (skip server/backend)"
|
|
40
|
+
--critical-only: "Only report CRITICAL and HIGH severity findings"
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## Process
|
|
46
|
+
|
|
47
|
+
### Step 1: Enumerate Target Files
|
|
48
|
+
|
|
49
|
+
```
|
|
50
|
+
+------------------------------------------------------------------------------+
|
|
51
|
+
| POWER VULN SCAN |
|
|
52
|
+
+------------------------------------------------------------------------------+
|
|
53
|
+
| |
|
|
54
|
+
| Target: {path} |
|
|
55
|
+
| Mode: {quick | deep} |
|
|
56
|
+
| Category: {all | injection | auth | data | config | mern} |
|
|
57
|
+
| Agents: {3-4 parallel scanners} |
|
|
58
|
+
| |
|
|
59
|
+
+------------------------------------------------------------------------------+
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
**File discovery:**
|
|
63
|
+
```
|
|
64
|
+
Scan target directory for security-relevant files:
|
|
65
|
+
|
|
66
|
+
Priority 1 (ALWAYS scan):
|
|
67
|
+
- server.js / app.js / index.js (entry points)
|
|
68
|
+
- routes/**/*.js (API endpoints)
|
|
69
|
+
- controllers/**/*.js (request handlers)
|
|
70
|
+
- middleware/**/*.js (auth, validation, error handling)
|
|
71
|
+
- models/**/*.js (database schemas)
|
|
72
|
+
- config/**/*.js (configuration files)
|
|
73
|
+
- .env* files (environment variables — check for secrets)
|
|
74
|
+
|
|
75
|
+
Priority 2 (scan if --deep or relevant category):
|
|
76
|
+
- services/**/*.js (business logic)
|
|
77
|
+
- utils/**/*.js (utility functions)
|
|
78
|
+
- client/src/**/*.jsx (React components — XSS checks)
|
|
79
|
+
- package.json (dependency vulnerabilities)
|
|
80
|
+
- docker-compose.yml (container config)
|
|
81
|
+
- nginx.conf (proxy config)
|
|
82
|
+
|
|
83
|
+
Skip:
|
|
84
|
+
- node_modules/
|
|
85
|
+
- .git/
|
|
86
|
+
- dist/ / build/
|
|
87
|
+
- test/ / __tests__/ (unless checking for hardcoded test credentials)
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
**Report file count and estimated scan time.**
|
|
91
|
+
|
|
92
|
+
### Step 2: Spawn Parallel Scan Agents
|
|
93
|
+
|
|
94
|
+
Launch 3-4 agents simultaneously, each scanning different OWASP categories.
|
|
95
|
+
|
|
96
|
+
**Agent A: Injection + XSS Scanner**
|
|
97
|
+
|
|
98
|
+
```markdown
|
|
99
|
+
<objective>
|
|
100
|
+
Scan for injection vulnerabilities (OWASP A03) and XSS (OWASP A07) in this codebase.
|
|
101
|
+
</objective>
|
|
102
|
+
|
|
103
|
+
<target>
|
|
104
|
+
{list of route, controller, service, and model files}
|
|
105
|
+
</target>
|
|
106
|
+
|
|
107
|
+
<scan_checklist>
|
|
108
|
+
INJECTION (A03):
|
|
109
|
+
- [ ] NoSQL injection: User input directly in MongoDB queries without type coercion
|
|
110
|
+
Pattern: db.collection.find({ field: req.body.field }) without String() or sanitize
|
|
111
|
+
- [ ] Command injection: User input in child_process.exec/spawn/execFile
|
|
112
|
+
Pattern: exec(`command ${userInput}`)
|
|
113
|
+
- [ ] Template injection: User input in template literals sent to eval or template engines
|
|
114
|
+
- [ ] SSRF: User-controlled URLs in fetch/axios/http.get without allowlist
|
|
115
|
+
Pattern: fetch(req.body.url) or axios.get(req.query.callback)
|
|
116
|
+
- [ ] SQL injection: If any SQL database used, raw query with string concatenation
|
|
117
|
+
- [ ] LDAP injection: User input in LDAP queries
|
|
118
|
+
- [ ] XML injection: User input in XML parsing without entity protection
|
|
119
|
+
- [ ] Path traversal: User input in file paths without sanitization
|
|
120
|
+
Pattern: fs.readFile(path.join(uploadDir, req.params.filename))
|
|
121
|
+
|
|
122
|
+
XSS (A07):
|
|
123
|
+
- [ ] React dangerouslySetInnerHTML with unsanitized user content
|
|
124
|
+
- [ ] Server-side HTML rendering with unescaped user input
|
|
125
|
+
- [ ] URL-based XSS via unvalidated redirect targets
|
|
126
|
+
- [ ] DOM XSS via document.write, innerHTML, or eval with user input
|
|
127
|
+
- [ ] Stored XSS: User content saved to DB and rendered without escaping
|
|
128
|
+
</scan_checklist>
|
|
129
|
+
|
|
130
|
+
<output_format>
|
|
131
|
+
For each finding, provide:
|
|
132
|
+
- VULN-A{NNN}: {title}
|
|
133
|
+
- File: {path}:{line_number}
|
|
134
|
+
- Severity: CRITICAL | HIGH | MEDIUM | LOW
|
|
135
|
+
- Confidence: HIGH (traced exploitable path) | MEDIUM (pattern match) | LOW (theoretical)
|
|
136
|
+
- Code: {the vulnerable code snippet, 3-5 lines}
|
|
137
|
+
- Exploit: {how an attacker would exploit this}
|
|
138
|
+
- Fix: {suggested fix with code}
|
|
139
|
+
- OWASP: {category code}
|
|
140
|
+
</output_format>
|
|
141
|
+
|
|
142
|
+
<rules>
|
|
143
|
+
- READ the actual code. Do not guess or assume.
|
|
144
|
+
- Trace data flow from user input (req.body, req.params, req.query) to dangerous sinks.
|
|
145
|
+
- Check if framework protections exist (Mongoose parameterizes by default for simple queries).
|
|
146
|
+
- Check if validation middleware exists upstream before flagging.
|
|
147
|
+
- If uncertain, mark confidence as LOW rather than inflating severity.
|
|
148
|
+
- Reference: @skills-library/security/application-vuln-patterns.md
|
|
149
|
+
</rules>
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
**Agent B: Auth + Access Control Scanner**
|
|
153
|
+
|
|
154
|
+
```markdown
|
|
155
|
+
<objective>
|
|
156
|
+
Scan for broken access control (OWASP A01) and authentication failures (OWASP A07) in this codebase.
|
|
157
|
+
</objective>
|
|
158
|
+
|
|
159
|
+
<target>
|
|
160
|
+
{list of route files, middleware files, auth-related files}
|
|
161
|
+
</target>
|
|
162
|
+
|
|
163
|
+
<scan_checklist>
|
|
164
|
+
BROKEN ACCESS CONTROL (A01):
|
|
165
|
+
- [ ] Routes without auth middleware (especially admin/sensitive endpoints)
|
|
166
|
+
Pattern: router.get('/api/admin/...', controller.method) — no protect/auth middleware
|
|
167
|
+
- [ ] Missing role-based access control on privileged operations
|
|
168
|
+
- [ ] IDOR: User can access other users' resources by changing ID in URL
|
|
169
|
+
Pattern: User.findById(req.params.id) without checking req.user._id === req.params.id
|
|
170
|
+
- [ ] Privilege escalation: User can set their own role
|
|
171
|
+
Pattern: User.findByIdAndUpdate(id, req.body) where req.body includes { role: 'admin' }
|
|
172
|
+
- [ ] Missing CORS restrictions or overly permissive CORS
|
|
173
|
+
Pattern: cors({ origin: '*' }) or cors() with no config
|
|
174
|
+
- [ ] CSRF: State-changing operations without CSRF tokens
|
|
175
|
+
- [ ] JWT stored in localStorage (XSS-accessible)
|
|
176
|
+
- [ ] JWT without expiration or with very long expiration
|
|
177
|
+
- [ ] Password reset without proper token validation
|
|
178
|
+
|
|
179
|
+
AUTHENTICATION FAILURES (A07):
|
|
180
|
+
- [ ] Passwords stored in plaintext or weak hashing (MD5, SHA1)
|
|
181
|
+
- [ ] No rate limiting on login endpoints
|
|
182
|
+
- [ ] No account lockout after failed attempts
|
|
183
|
+
- [ ] Session tokens not invalidated on logout
|
|
184
|
+
- [ ] Default credentials in code or config
|
|
185
|
+
- [ ] Password requirements too weak or not enforced
|
|
186
|
+
</scan_checklist>
|
|
187
|
+
|
|
188
|
+
<output_format>
|
|
189
|
+
Same as Agent A but with VULN-B{NNN} prefix.
|
|
190
|
+
</output_format>
|
|
191
|
+
```
|
|
192
|
+
|
|
193
|
+
**Agent C: Data Exposure + Config Scanner**
|
|
194
|
+
|
|
195
|
+
```markdown
|
|
196
|
+
<objective>
|
|
197
|
+
Scan for cryptographic failures (OWASP A02), security misconfiguration (OWASP A05),
|
|
198
|
+
and insecure design (OWASP A04).
|
|
199
|
+
</objective>
|
|
200
|
+
|
|
201
|
+
<target>
|
|
202
|
+
{config files, .env files, server entry point, middleware, package.json}
|
|
203
|
+
</target>
|
|
204
|
+
|
|
205
|
+
<scan_checklist>
|
|
206
|
+
CRYPTOGRAPHIC FAILURES (A02):
|
|
207
|
+
- [ ] Hardcoded secrets (API keys, passwords, JWT secrets in source code)
|
|
208
|
+
Pattern: const JWT_SECRET = "mysecret" or apiKey: "sk-..."
|
|
209
|
+
- [ ] Weak cryptographic algorithms (MD5, SHA1 for passwords)
|
|
210
|
+
- [ ] Missing HTTPS enforcement
|
|
211
|
+
- [ ] Sensitive data in logs (passwords, tokens, PII)
|
|
212
|
+
- [ ] Missing encryption for sensitive data at rest
|
|
213
|
+
|
|
214
|
+
SECURITY MISCONFIGURATION (A05):
|
|
215
|
+
- [ ] Debug mode enabled in production config
|
|
216
|
+
- [ ] Verbose error messages exposing stack traces to clients
|
|
217
|
+
Pattern: res.status(500).json({ error: err.stack })
|
|
218
|
+
- [ ] Missing security headers (Helmet.js not used)
|
|
219
|
+
Check: X-Content-Type-Options, X-Frame-Options, CSP, HSTS
|
|
220
|
+
- [ ] Directory listing enabled
|
|
221
|
+
- [ ] Default or sample configurations in production
|
|
222
|
+
- [ ] Unnecessary features enabled (TRACE, DEBUG endpoints)
|
|
223
|
+
- [ ] Missing rate limiting on API endpoints
|
|
224
|
+
|
|
225
|
+
INSECURE DESIGN (A04):
|
|
226
|
+
- [ ] No input validation on critical operations (payments, account changes)
|
|
227
|
+
- [ ] Business logic flaws (e.g., price manipulation in cart)
|
|
228
|
+
- [ ] Missing anti-automation on sensitive flows (registration, password reset)
|
|
229
|
+
- [ ] Insufficient logging for security events
|
|
230
|
+
</scan_checklist>
|
|
231
|
+
|
|
232
|
+
<output_format>
|
|
233
|
+
Same format with VULN-C{NNN} prefix.
|
|
234
|
+
</output_format>
|
|
235
|
+
```
|
|
236
|
+
|
|
237
|
+
**Agent D: MERN-Specific Scanner**
|
|
238
|
+
|
|
239
|
+
```markdown
|
|
240
|
+
<objective>
|
|
241
|
+
Scan for vulnerabilities specific to the MERN stack (MongoDB, Express, React, Node.js).
|
|
242
|
+
</objective>
|
|
243
|
+
|
|
244
|
+
<target>
|
|
245
|
+
{all files — cross-cutting concerns}
|
|
246
|
+
</target>
|
|
247
|
+
|
|
248
|
+
<scan_checklist>
|
|
249
|
+
MONGODB:
|
|
250
|
+
- [ ] $where operator with user input (JavaScript injection)
|
|
251
|
+
- [ ] $regex with user input (ReDoS)
|
|
252
|
+
- [ ] Mongoose populate() without field selection (data leakage)
|
|
253
|
+
- [ ] Missing schema validation (schemaless collections accepting anything)
|
|
254
|
+
|
|
255
|
+
EXPRESS:
|
|
256
|
+
- [ ] Missing express-rate-limit on all routes
|
|
257
|
+
- [ ] Missing helmet() middleware
|
|
258
|
+
- [ ] Missing express-mongo-sanitize or similar input sanitizer
|
|
259
|
+
- [ ] bodyParser with high limit allowing DoS
|
|
260
|
+
- [ ] Missing request size limits on file uploads
|
|
261
|
+
- [ ] Error handler exposing internal details
|
|
262
|
+
|
|
263
|
+
REACT:
|
|
264
|
+
- [ ] dangerouslySetInnerHTML with user content
|
|
265
|
+
- [ ] eval() or Function() with dynamic input
|
|
266
|
+
- [ ] Sensitive data in client-side state/localStorage
|
|
267
|
+
- [ ] API keys or secrets in client-side code
|
|
268
|
+
- [ ] Missing Content-Security-Policy
|
|
269
|
+
|
|
270
|
+
NODE.JS:
|
|
271
|
+
- [ ] Prototype pollution via Object.assign or spread with user input
|
|
272
|
+
- [ ] Buffer.allocUnsafe() without clearing
|
|
273
|
+
- [ ] Unhandled promise rejections crashing the server
|
|
274
|
+
- [ ] Missing process-level error handlers
|
|
275
|
+
- [ ] child_process with unsanitized input
|
|
276
|
+
- [ ] Insecure dependencies (known CVEs in package.json)
|
|
277
|
+
|
|
278
|
+
PLUGIN ARCHITECTURE (if applicable):
|
|
279
|
+
- [ ] Plugin code execution without sandboxing
|
|
280
|
+
- [ ] Plugin file access without path restrictions
|
|
281
|
+
- [ ] Plugin database access without scoping
|
|
282
|
+
</scan_checklist>
|
|
283
|
+
|
|
284
|
+
<output_format>
|
|
285
|
+
Same format with VULN-D{NNN} prefix.
|
|
286
|
+
</output_format>
|
|
287
|
+
```
|
|
288
|
+
|
|
289
|
+
### Step 3: Self-Verification (Agent-as-Judge)
|
|
290
|
+
|
|
291
|
+
After all scan agents return, spawn a verification agent:
|
|
292
|
+
|
|
293
|
+
```markdown
|
|
294
|
+
<objective>
|
|
295
|
+
You are a security review judge. Re-examine each vulnerability finding and filter false positives.
|
|
296
|
+
</objective>
|
|
297
|
+
|
|
298
|
+
<findings>
|
|
299
|
+
{merged findings from all scan agents}
|
|
300
|
+
</findings>
|
|
301
|
+
|
|
302
|
+
<verification_checklist>
|
|
303
|
+
For EACH finding, answer:
|
|
304
|
+
|
|
305
|
+
1. EXPLOITABLE? Is there a real attack path, or does a guard elsewhere prevent exploitation?
|
|
306
|
+
- Check if input validation middleware exists upstream
|
|
307
|
+
- Check if the framework provides built-in protection
|
|
308
|
+
- Check if there's a WAF or reverse proxy that would block this
|
|
309
|
+
|
|
310
|
+
2. SEVERITY CORRECT? Is the severity rating appropriate?
|
|
311
|
+
- CRITICAL: Remote code execution, auth bypass, data breach possible
|
|
312
|
+
- HIGH: Significant data exposure or access control violation
|
|
313
|
+
- MEDIUM: Information disclosure, missing best practice with some risk
|
|
314
|
+
- LOW: Best practice violation with minimal real-world risk
|
|
315
|
+
|
|
316
|
+
3. CONFIDENCE? How certain are we?
|
|
317
|
+
- HIGH: Traced full exploit path from input to dangerous sink
|
|
318
|
+
- MEDIUM: Pattern matches but didn't trace full path
|
|
319
|
+
- LOW: Theoretical risk, may be mitigated by unseen code
|
|
320
|
+
|
|
321
|
+
4. DUPLICATE? Is this the same issue reported by multiple agents?
|
|
322
|
+
|
|
323
|
+
5. FALSE POSITIVE? Mark as FALSE_POSITIVE if:
|
|
324
|
+
- Framework provides automatic protection (e.g., Mongoose sanitizes simple queries)
|
|
325
|
+
- Guard exists elsewhere that was missed by the scan agent
|
|
326
|
+
- The pattern match is a false alarm (e.g., "password" in a UI label, not actual password)
|
|
327
|
+
</verification_checklist>
|
|
328
|
+
|
|
329
|
+
<output>
|
|
330
|
+
Return the VERIFIED findings list with:
|
|
331
|
+
- Removed false positives
|
|
332
|
+
- Deduplicated entries
|
|
333
|
+
- Corrected severity/confidence where needed
|
|
334
|
+
- Added verification notes
|
|
335
|
+
</output>
|
|
336
|
+
```
|
|
337
|
+
|
|
338
|
+
### Step 4: Merge + Deduplicate
|
|
339
|
+
|
|
340
|
+
Combine verified findings into a single sorted list:
|
|
341
|
+
1. CRITICAL findings first (sorted by confidence HIGH → LOW)
|
|
342
|
+
2. HIGH findings
|
|
343
|
+
3. MEDIUM findings
|
|
344
|
+
4. LOW findings
|
|
345
|
+
|
|
346
|
+
Deduplicate by file:line (keep the most detailed finding).
|
|
347
|
+
|
|
348
|
+
### Step 5: Generate Report
|
|
349
|
+
|
|
350
|
+
```
|
|
351
|
+
+==============================================================================+
|
|
352
|
+
| APPLICATION VULNERABILITY SCAN REPORT |
|
|
353
|
+
+==============================================================================+
|
|
354
|
+
| |
|
|
355
|
+
| Target: {path} |
|
|
356
|
+
| Date: {timestamp} |
|
|
357
|
+
| Scanner: Dominion Flow /fire-vuln-scan (Claude Opus 4.6) |
|
|
358
|
+
| Mode: {quick | deep} |
|
|
359
|
+
| |
|
|
360
|
+
| Files Scanned: {count} |
|
|
361
|
+
| Findings: {total} ({critical} critical, {high} high, {medium} medium) |
|
|
362
|
+
| False Positives Filtered: {count} |
|
|
363
|
+
| |
|
|
364
|
+
+==============================================================================+
|
|
365
|
+
| VERDICT: {SECURE | NEEDS ATTENTION | AT RISK} |
|
|
366
|
+
+------------------------------------------------------------------------------+
|
|
367
|
+
| |
|
|
368
|
+
| CRITICAL: {count} |
|
|
369
|
+
| HIGH: {count} |
|
|
370
|
+
| MEDIUM: {count} |
|
|
371
|
+
| LOW: {count} |
|
|
372
|
+
| |
|
|
373
|
+
+------------------------------------------------------------------------------+
|
|
374
|
+
| TOP FINDINGS |
|
|
375
|
+
+------------------------------------------------------------------------------+
|
|
376
|
+
| |
|
|
377
|
+
| 1. [{severity}] {title} |
|
|
378
|
+
| File: {path}:{line} |
|
|
379
|
+
| OWASP: {category} |
|
|
380
|
+
| Confidence: {level} |
|
|
381
|
+
| |
|
|
382
|
+
| 2. [{severity}] {title} |
|
|
383
|
+
| ... |
|
|
384
|
+
| |
|
|
385
|
+
+==============================================================================+
|
|
386
|
+
```
|
|
387
|
+
|
|
388
|
+
Display top 10 findings in terminal. Full report saved if `--report` flag.
|
|
389
|
+
|
|
390
|
+
### Step 6: Save Report
|
|
391
|
+
|
|
392
|
+
**If `--report` flag:**
|
|
393
|
+
|
|
394
|
+
Save to two locations:
|
|
395
|
+
1. `.planning/security/vuln-scan-{date}.md` — project-local
|
|
396
|
+
2. `C:\Users\FirstName\Documents\Claude Reports\{project}-vuln-scan-{date}.md` — global
|
|
397
|
+
|
|
398
|
+
**Report format:** Full markdown with all findings, severity, confidence, code snippets, suggested fixes, and OWASP mapping.
|
|
399
|
+
|
|
400
|
+
**Offer next steps:**
|
|
401
|
+
```
|
|
402
|
+
+------------------------------------------------------------------------------+
|
|
403
|
+
| NEXT STEPS |
|
|
404
|
+
+------------------------------------------------------------------------------+
|
|
405
|
+
| |
|
|
406
|
+
| Fix critical findings: |
|
|
407
|
+
| /fire-debug {VULN-ID} — investigate and fix a specific vulnerability |
|
|
408
|
+
| |
|
|
409
|
+
| Re-scan after fixes: |
|
|
410
|
+
| /fire-vuln-scan {path} --category {category} |
|
|
411
|
+
| |
|
|
412
|
+
| Full project verification: |
|
|
413
|
+
| /fire-4-verify — includes security as verification dimension |
|
|
414
|
+
| |
|
|
415
|
+
+------------------------------------------------------------------------------+
|
|
416
|
+
```
|
|
417
|
+
|
|
418
|
+
---
|
|
419
|
+
|
|
420
|
+
## Integration Points
|
|
421
|
+
|
|
422
|
+
| Command | Integration |
|
|
423
|
+
|---------|------------|
|
|
424
|
+
| `/fire-4-verify` | Add security check dimension: "Run vuln scan if not done this phase" |
|
|
425
|
+
| `/fire-debug` | Can target specific VULN-IDs for investigation |
|
|
426
|
+
| `/fire-3-execute` | Optional pre-commit security check on changed files |
|
|
427
|
+
| `/fire-dashboard` | Show last scan date and finding count |
|
|
428
|
+
| `/fire-loop` | Include vuln-scan in verification stage |
|
|
429
|
+
|
|
430
|
+
---
|
|
431
|
+
|
|
432
|
+
## Severity Definitions
|
|
433
|
+
|
|
434
|
+
| Level | Meaning | Examples |
|
|
435
|
+
|-------|---------|---------|
|
|
436
|
+
| CRITICAL | Exploitable remotely, leads to data breach or RCE | NoSQL injection with traced exploit path, auth bypass, hardcoded production secrets |
|
|
437
|
+
| HIGH | Significant security weakness, likely exploitable | Missing auth on admin routes, IDOR, XSS with user content |
|
|
438
|
+
| MEDIUM | Security weakness, requires specific conditions | Missing security headers, verbose errors, weak password policy |
|
|
439
|
+
| LOW | Best practice violation, minimal real-world risk | Missing rate limiting on non-sensitive endpoint, deprecated crypto function |
|
|
440
|
+
|
|
441
|
+
---
|
|
442
|
+
|
|
443
|
+
## Examples
|
|
444
|
+
|
|
445
|
+
```bash
|
|
446
|
+
# Quick scan of entire project
|
|
447
|
+
/fire-vuln-scan C:\path\to\your-project
|
|
448
|
+
|
|
449
|
+
# Deep scan with full reasoning per finding
|
|
450
|
+
/fire-vuln-scan C:\path\to\your-project --deep
|
|
451
|
+
|
|
452
|
+
# Scan only injection vulnerabilities
|
|
453
|
+
/fire-vuln-scan --category injection
|
|
454
|
+
|
|
455
|
+
# Scan server-side only, save report
|
|
456
|
+
/fire-vuln-scan --server-only --report
|
|
457
|
+
|
|
458
|
+
# Critical findings only
|
|
459
|
+
/fire-vuln-scan --critical-only --report
|
|
460
|
+
|
|
461
|
+
# Scan after fixing, compare to previous
|
|
462
|
+
/fire-vuln-scan --report
|
|
463
|
+
```
|
|
464
|
+
|
|
465
|
+
---
|
|
466
|
+
|
|
467
|
+
## Success Criteria
|
|
468
|
+
|
|
469
|
+
- [ ] Target files enumerated (routes, controllers, middleware, models, config)
|
|
470
|
+
- [ ] 3-4 parallel scan agents spawned with OWASP-mapped checklists
|
|
471
|
+
- [ ] All agents returned findings
|
|
472
|
+
- [ ] Self-verification judge filtered false positives
|
|
473
|
+
- [ ] Findings merged and deduplicated
|
|
474
|
+
- [ ] Report generated with severity, confidence, file:line, suggested fixes
|
|
475
|
+
- [ ] Report saved (if --report)
|
|
476
|
+
- [ ] Next steps offered to user
|
|
477
|
+
|
|
478
|
+
---
|
|
479
|
+
|
|
480
|
+
## References
|
|
481
|
+
|
|
482
|
+
- Claude Code Security (Anthropic 2026): https://www.anthropic.com/news/claude-code-security
|
|
483
|
+
- OWASP Top 10 2021: https://owasp.org/Top10/
|
|
484
|
+
- OWASP Agentic Top 10 2026: https://genai.owasp.org/resource/owasp-top-10-for-agentic-applications-for-2026/
|
|
485
|
+
- Agent-as-Judge Self-Verification: https://arxiv.org/abs/2401.10020
|
|
486
|
+
- Express Security Best Practices: https://expressjs.com/en/advanced/best-practice-security.html
|
|
487
|
+
- Mongoose Security: https://mongoosejs.com/docs/security.html
|
|
488
|
+
|
|
489
|
+
## Related Skills
|
|
490
|
+
|
|
491
|
+
- `security/application-vuln-patterns.md` — MERN vulnerability patterns with code examples
|
|
492
|
+
- `security/agent-security-scanner.md` — Agent security (prompt injection, MCP poisoning)
|
|
493
|
+
- `deployment-security/SECURITY.md` — Deployment security patterns
|
package/hooks/hooks.json
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"hooks": [
|
|
3
|
+
{
|
|
4
|
+
"event": "SessionStart",
|
|
5
|
+
"triggers": ["startup", "resume", "clear", "compact"],
|
|
6
|
+
"type": "command",
|
|
7
|
+
"command": ["bash", "${CLAUDE_PLUGIN_ROOT}/hooks/run-hook.sh"]
|
|
8
|
+
},
|
|
9
|
+
{
|
|
10
|
+
"event": "SessionEnd",
|
|
11
|
+
"triggers": ["logout", "prompt_input_exit", "other"],
|
|
12
|
+
"type": "command",
|
|
13
|
+
"command": ["bash", "${CLAUDE_PLUGIN_ROOT}/hooks/run-session-end.sh"]
|
|
14
|
+
}
|
|
15
|
+
]
|
|
16
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
@echo off
|
|
2
|
+
REM Dominion Flow Plugin - Windows Hook Launcher
|
|
3
|
+
REM Calls Git Bash to run session-start.sh with proper path handling
|
|
4
|
+
|
|
5
|
+
setlocal enabledelayedexpansion
|
|
6
|
+
|
|
7
|
+
REM Get the directory where this script is located
|
|
8
|
+
set "HOOK_DIR=%~dp0"
|
|
9
|
+
REM Remove trailing backslash
|
|
10
|
+
set "HOOK_DIR=%HOOK_DIR:~0,-1%"
|
|
11
|
+
|
|
12
|
+
REM Convert Windows path to Unix-style for Git Bash
|
|
13
|
+
set "UNIX_HOOK_DIR=%HOOK_DIR:\=/%"
|
|
14
|
+
set "UNIX_HOOK_DIR=%UNIX_HOOK_DIR:C:=/c%"
|
|
15
|
+
|
|
16
|
+
REM Define the script to run
|
|
17
|
+
set "SCRIPT_PATH=%UNIX_HOOK_DIR%/session-start.sh"
|
|
18
|
+
|
|
19
|
+
REM Try common Git Bash locations
|
|
20
|
+
set "GIT_BASH="
|
|
21
|
+
|
|
22
|
+
REM Check Program Files
|
|
23
|
+
if exist "C:\Program Files\Git\bin\bash.exe" (
|
|
24
|
+
set "GIT_BASH=C:\Program Files\Git\bin\bash.exe"
|
|
25
|
+
goto :found_bash
|
|
26
|
+
)
|
|
27
|
+
|
|
28
|
+
REM Check Program Files (x86)
|
|
29
|
+
if exist "C:\Program Files (x86)\Git\bin\bash.exe" (
|
|
30
|
+
set "GIT_BASH=C:\Program Files (x86)\Git\bin\bash.exe"
|
|
31
|
+
goto :found_bash
|
|
32
|
+
)
|
|
33
|
+
|
|
34
|
+
REM Check user's AppData
|
|
35
|
+
if exist "%LOCALAPPDATA%\Programs\Git\bin\bash.exe" (
|
|
36
|
+
set "GIT_BASH=%LOCALAPPDATA%\Programs\Git\bin\bash.exe"
|
|
37
|
+
goto :found_bash
|
|
38
|
+
)
|
|
39
|
+
|
|
40
|
+
REM Check if bash is in PATH
|
|
41
|
+
where bash >nul 2>&1
|
|
42
|
+
if %ERRORLEVEL% equ 0 (
|
|
43
|
+
set "GIT_BASH=bash"
|
|
44
|
+
goto :found_bash
|
|
45
|
+
)
|
|
46
|
+
|
|
47
|
+
REM Fallback: No Git Bash found
|
|
48
|
+
echo [Dominion Flow Hook] Warning: Git Bash not found
|
|
49
|
+
echo.
|
|
50
|
+
echo ============================================
|
|
51
|
+
echo DOMINION FLOW - Session Context (Fallback)
|
|
52
|
+
echo ============================================
|
|
53
|
+
echo.
|
|
54
|
+
echo [INFO] Git Bash is required for full context injection.
|
|
55
|
+
echo [INFO] Install Git for Windows: https://git-scm.com/download/win
|
|
56
|
+
echo.
|
|
57
|
+
echo Quick Actions:
|
|
58
|
+
echo - Check .planning/CONSCIENCE.md for project state
|
|
59
|
+
echo - Check ~/.claude/warrior-handoffs/ for latest handoff
|
|
60
|
+
echo - Use /fire-dashboard for project status
|
|
61
|
+
echo.
|
|
62
|
+
goto :end
|
|
63
|
+
|
|
64
|
+
:found_bash
|
|
65
|
+
REM Run the bash script
|
|
66
|
+
"%GIT_BASH%" "%SCRIPT_PATH%"
|
|
67
|
+
|
|
68
|
+
:end
|
|
69
|
+
endlocal
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
# MIT License - Copyright (c) 2026 ThierryN - https://github.com/ThierryN/dominion-flow
|
|
3
|
+
#
|
|
4
|
+
# Universal hook launcher — works on macOS, Linux, and Windows (Git Bash / WSL)
|
|
5
|
+
# Resolves the actual session-start.sh relative to this script's location.
|
|
6
|
+
|
|
7
|
+
HOOK_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|
8
|
+
exec bash "$HOOK_DIR/session-start.sh"
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
@echo off
|
|
2
|
+
REM Dominion Flow Plugin - Windows Session End Hook Launcher
|
|
3
|
+
REM Calls Git Bash to run session-end.sh
|
|
4
|
+
|
|
5
|
+
setlocal enabledelayedexpansion
|
|
6
|
+
|
|
7
|
+
REM Get the directory where this script is located
|
|
8
|
+
set "HOOK_DIR=%~dp0"
|
|
9
|
+
set "HOOK_DIR=%HOOK_DIR:~0,-1%"
|
|
10
|
+
|
|
11
|
+
REM Convert Windows path to Unix-style for Git Bash
|
|
12
|
+
set "UNIX_HOOK_DIR=%HOOK_DIR:\=/%"
|
|
13
|
+
set "UNIX_HOOK_DIR=%UNIX_HOOK_DIR:C:=/c%"
|
|
14
|
+
|
|
15
|
+
REM Define the script to run
|
|
16
|
+
set "SCRIPT_PATH=%UNIX_HOOK_DIR%/session-end.sh"
|
|
17
|
+
|
|
18
|
+
REM Try common Git Bash locations
|
|
19
|
+
set "GIT_BASH="
|
|
20
|
+
|
|
21
|
+
if exist "C:\Program Files\Git\bin\bash.exe" (
|
|
22
|
+
set "GIT_BASH=C:\Program Files\Git\bin\bash.exe"
|
|
23
|
+
goto :found_bash
|
|
24
|
+
)
|
|
25
|
+
|
|
26
|
+
if exist "C:\Program Files (x86)\Git\bin\bash.exe" (
|
|
27
|
+
set "GIT_BASH=C:\Program Files (x86)\Git\bin\bash.exe"
|
|
28
|
+
goto :found_bash
|
|
29
|
+
)
|
|
30
|
+
|
|
31
|
+
if exist "%LOCALAPPDATA%\Programs\Git\bin\bash.exe" (
|
|
32
|
+
set "GIT_BASH=%LOCALAPPDATA%\Programs\Git\bin\bash.exe"
|
|
33
|
+
goto :found_bash
|
|
34
|
+
)
|
|
35
|
+
|
|
36
|
+
where bash >nul 2>&1
|
|
37
|
+
if %ERRORLEVEL% equ 0 (
|
|
38
|
+
set "GIT_BASH=bash"
|
|
39
|
+
goto :found_bash
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
REM Fallback: No Git Bash found — skip silently
|
|
43
|
+
goto :end
|
|
44
|
+
|
|
45
|
+
:found_bash
|
|
46
|
+
"%GIT_BASH%" "%SCRIPT_PATH%"
|
|
47
|
+
|
|
48
|
+
:end
|
|
49
|
+
endlocal
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
# MIT License - Copyright (c) 2026 ThierryN - https://github.com/ThierryN/dominion-flow
|
|
3
|
+
#
|
|
4
|
+
# Universal hook launcher — works on macOS, Linux, and Windows (Git Bash / WSL)
|
|
5
|
+
|
|
6
|
+
HOOK_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|
7
|
+
exec bash "$HOOK_DIR/session-end.sh"
|