@yagyeshvyas/vibeguard 0.1.0 → 1.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/CHANGELOG.md ADDED
@@ -0,0 +1,63 @@
1
+ # Changelog
2
+
3
+ All notable changes to VibeGuard are documented here.
4
+ Format based on [Keep a Changelog](https://keepachangelog.com/).
5
+
6
+ ## [Unreleased]
7
+
8
+ ### Added
9
+ - `vibeguard auto` — one-command full autonomous protection. Activates
10
+ daemon (file watcher), pre-commit hook, post-edit hook, and shell guard.
11
+ Idempotent. `--stop` reverses everything and restores backups. `--status`
12
+ shows what's active. `--ci` for pipeline mode. `--fix` for safe auto-fixes.
13
+ `--no-shell` to skip shell hook. `--strict` to block on HIGH too.
14
+ - `src/auto.js` orchestrator composing existing modules (scanner, daemon,
15
+ hook, shell-guard). All state under `.vibeguard/auto.json`.
16
+ - Shell hook FP fix: default-allow policy. Unknown commands are allowed.
17
+ Only block on known dangerous patterns. Fail-open on module load errors.
18
+ Both `shell-hook.sh` and `shell-hook.ps1` now try multiple module paths
19
+ and never block when VibeGuard can't load.
20
+
21
+ ### Changed
22
+ - Taint analysis upgraded from regex-only to scope-aware, AST-based dataflow
23
+ (`taint-ast.js`). Sources/sinks matched on AST nodes (MemberExpression /
24
+ CallExpression), not text. Respects block/function scope with shadowing,
25
+ clears taint on clean reassignment, recognizes sanitizers (parseInt,
26
+ path.basename, DOMPurify.sanitize, etc. — configurable array). Tracks
27
+ cross-function taint within a file via intra-function fixpoint. All
28
+ AST-confirmed findings carry `confidence: "high"` and `dataflow: true`.
29
+ Regex taint retained as fallback for unparseable files. Finding object
30
+ shape unchanged (ruleId/severity/title/message/fix preserved).
31
+
32
+ ### Added
33
+ - Cross-file taint analysis via import/export graph (`crosstaint.js`)
34
+ - Optional AST mode with acorn + acorn-typescript (`ast.js`)
35
+ - `vibeguard doctor` — AI host security audit (hook injection, base URL hijack, MCP config)
36
+ - `vibeguard history` — git history secret scan
37
+ - `vibeguard watch` — re-scan on file change
38
+ - `vibeguard rules` / `vibeguard explain` — rule listing and documentation
39
+ - Live key verification (`--verify-keys`) for OpenAI + Stripe
40
+ - Inline suppressions (`vibeguard-ignore-line` / `vibeguard-ignore-next-line`)
41
+ - Project config (`.vibeguardrc.json`) with ignoreRules, ignorePaths, severityOverrides
42
+ - .gitignore-aware secret scanning
43
+ - Stable finding fingerprints for SARIF + baseline diffing
44
+ - External scanner support: semgrep, gitleaks, bandit
45
+ - 15 secret types (GitHub, Slack, GitLab, Twilio, SendGrid, Mailgun, Telegram, npm, Resend, connection strings, public-LLM-key)
46
+ - AI security rules (browser-api-key, disabled-sandbox, eval-llm-output, prompt-injection-marker)
47
+ - Injection rules (prototype pollution, ReDoS, XXE, CRLF)
48
+ - Framework rules (Prisma raw, React dangerous HTML, reflected XSS)
49
+ - IaC rules (Dockerfile, GitHub Actions, Terraform)
50
+ - Package hygiene (unpinned deps, dangerous scripts, no lockfile)
51
+ - 63 tests, all passing
52
+
53
+ ## [0.1.0] - Initial release
54
+ - Core scanner with secrets, injection, auth, config, PII rules
55
+ - Fix → verify loop with baseline + rollback
56
+ - MCP server (5 tools)
57
+ - Live URL scan
58
+ - Badge generation
59
+ - One-command multi-client installer
60
+ - Pre-commit hook
61
+ - GitHub Actions CI template
62
+ - SARIF 2.1.0 output
63
+ - Zero runtime dependencies (scanner)
package/README.md CHANGED
@@ -1,23 +1,43 @@
1
1
  <div align="center">
2
2
 
3
- <!-- Animated Banner -->
4
- <img src="https://readme-typing-svg.herokuapp.com?font=Fira+Code&weight=600&size=28&pause=1000&color=2E75B6&center=true&vCenter=true&random=false&width=600&lines=VibeGuard;Security+%26+Privacy+for+AI-Coded+Apps;699+Rules+%7C+76+MCP+Tools;13+Defense+Layers;Zero+Telemetry+%7C+%240+Cost" alt="VibeGuard Animated Banner" />
3
+ <!-- Animated Logo Banner -->
4
+ <img src="https://readme-typing-svg.herokuapp.com?font=Fira+Code&weight=700&size=32&duration=1500&pause=500&color=2E75B6&center=true&vCenter=true&random=false&width=600&lines=VibeGuard;693+Rules+%7C+75+MCP+Tools;13+Defense+Layers;86%25+Precision+%7C+96%25+Recall;329+Tests+%7C+0+Failures;$0+Cost+%7C+Zero+Telemetry;One+Command+%3A+vibeguard+auto" alt="VibeGuard" />
5
5
 
6
6
  <br/>
7
7
 
8
- <!-- Badges -->
9
- ![GitHub stars](https://img.shields.io/github/stars/yagyeshVyas/VibeGuard?style=for-the-badge&color=2E75B6)
10
- ![GitHub forks](https://img.shields.io/github/forks/yagyeshVyas/VibeGuard?style=for-the-badge&color=2E75B6)
11
- ![GitHub license](https://img.shields.io/github/license/yagyeshVyas/VibeGuard?style=for-the-badge&color=22C55E)
12
- ![GitHub issues](https://img.shields.io/github/issues/yagyeshVyas/VibeGuard?style=for-the-badge&color=F59E0B)
13
- ![GitHub last commit](https://img.shields.io/github/last-commit/yagyeshVyas/VibeGuard?style=for-the-badge&color=2E75B6)
14
- ![npm](https://img.shields.io/badge/npm-vibeguard-blue?style=for-the-badge&color=CB3837)
15
- ![rules](https://img.shields.io/badge/rules-699-blue?style=for-the-badge&color=2E75B6)
16
- ![MCP tools](https://img.shields.io/badge/MCP%20tools-76-blue?style=for-the-badge&color=8B5CF6)
17
- ![cost](https://img.shields.io/badge/cost-%240-green?style=for-the-badge&color=22C55E)
18
- ![privacy](https://img.shields.io/badge/privacy-100%25%20local-green?style=for-the-badge&color=22C55E)
19
- ![telemetry](https://img.shields.io/badge/telemetry-NONE-green?style=for-the-badge&color=22C55E)
8
+ <!-- Status Badges -->
9
+ <img src="https://img.shields.io/badge/status-active-success?style=flat-square&color=22C55E" />
10
+ <img src="https://img.shields.io/badge/version-0.1.0-blue?style=flat-square" />
11
+ <img src="https://img.shields.io/badge/license-MIT-green?style=flat-square&color=22C55E" />
12
+ <img src="https://img.shields.io/badge/cost-$0-green?style=flat-square&color=22C55E" />
13
+ <img src="https://img.shields.io/badge/telemetry-none-green?style=flat-square&color=22C55E" />
14
+ <img src="https://img.shields.io/badge/privacy-100%25%20local-green?style=flat-square&color=22C55E" />
20
15
 
16
+ <br/>
17
+ <br/>
18
+
19
+ <!-- Stats Cards -->
20
+ <img src="https://img.shields.io/badge/rules-693-blue?style=for-the-badge&color=2E75B6" />
21
+ <img src="https://img.shields.io/badge/MCP_tools-75-purple?style=for-the-badge&color=8B5CF6" />
22
+ <img src="https://img.shields.io/badge/CLI_commands-58-blue?style=for-the-badge&color=3B82F6" />
23
+ <img src="https://img.shields.io/badge/auto_fixes-43-green?style=for-the-badge&color=22C55E" />
24
+ <img src="https://img.shields.io/badge/defense_layers-13-red?style=for-the-badge&color=EF4444" />
25
+ <img src="https://img.shields.io/badge/AI_clients-12-cyan?style=for-the-badge&color=06B6D4" />
26
+ <img src="https://img.shields.io/badge/languages-14-blue?style=for-the-badge&color=3B82F6" />
27
+ <img src="https://img.shields.io/badge/frameworks-20%2B-orange?style=for-the-badge&color=F59E0B" />
28
+ <img src="https://img.shields.io/badge/tests-329-brightgreen?style=for-the-badge&color=22C55E" />
29
+ <img src="https://img.shields.io/badge/errors-0-brightgreen?style=for-the-badge&color=22C55E" />
30
+
31
+ <br/>
32
+ <br/>
33
+
34
+ <!-- Shield-style shields -->
35
+ <a href="https://github.com/yagyeshVyas/VibeGuard/stargazers"><img src="https://img.shields.io/github/stars/yagyeshVyas/VibeGuard?style=social" alt="Stars"></a>
36
+ <a href="https://github.com/yagyeshVyas/VibeGuard/network/members"><img src="https://img.shields.io/github/forks/yagyeshVyas/VibeGuard?style=social" alt="Forks"></a>
37
+ <a href="https://www.npmjs.com/package/vibeguard"><img src="https://img.shields.io/badge/npm-vibeguard-red?style=social&logo=npm" alt="npm"></a>
38
+ <a href="https://www.linkedin.com/in/yagyeshvyas/"><img src="https://img.shields.io/badge/LinkedIn-Yagyesh_Vyas-blue?style=social&logo=linkedin" alt="LinkedIn"></a>
39
+
40
+ <br/>
21
41
  <br/>
22
42
 
23
43
  <!-- Tagline -->
@@ -25,16 +45,27 @@
25
45
 
26
46
  <p>AI coding tools (Claude Code, Cursor, Windsurf, Lovable, Bolt) ship fast — and often ship hardcoded secrets, open databases, injection holes, and privacy violations. <b>VibeGuard catches all of it.</b></p>
27
47
 
28
- <p><b>699 rules</b> · <b>76 MCP tools</b> · <b>58 CLI commands</b> · <b>13 defense layers</b> · <b>43 auto-fixes</b> · <b>12 AI clients</b> · <b>14 languages</b> · <b>20+ frameworks</b> · <b>$0 cost</b> · <b>zero telemetry</b></p>
48
+ <table>
49
+ <tr>
50
+ <td align="center"><h4>693</h4><sub>Rules</sub></td>
51
+ <td align="center"><h4>75</h4><sub>MCP Tools</sub></td>
52
+ <td align="center"><h4>58</h4><sub>CLI Commands</sub></td>
53
+ <td align="center"><h4>13</h4><sub>Defense Layers</sub></td>
54
+ <td align="center"><h4>43</h4><sub>Auto-Fixes</sub></td>
55
+ <td align="center"><h4>$0</h4><sub>Cost</sub></td>
56
+ </tr>
57
+ </table>
29
58
 
30
- <br/>
59
+ </div>
60
+
61
+ ---
31
62
 
32
63
  <!-- Install -->
33
64
  ## 📦 Install
34
65
 
35
66
  ### Option 1: From npm (when published)
36
67
  ```bash
37
- npx @yagyeshvyas/vibeguard install
68
+ npx vibeguard install
38
69
  ```
39
70
 
40
71
  ### Option 2: From GitHub (works now!)
@@ -48,6 +79,40 @@ npm link # makes 'vibeguard' available globally
48
79
 
49
80
  Then use it:
50
81
  ```bash
82
+ vibeguard auto # one command — full protection on
83
+ vibeguard auto --status # see what's active
84
+ vibeguard auto --stop # turn it all off, restore backups
85
+ ```
86
+
87
+ <div align="center">
88
+
89
+ ### `vibeguard auto` activates everything in one command
90
+
91
+ ```
92
+ [VibeGuard] Activating full protection...
93
+
94
+ OK scan Grade: A Critical: 0 High: 0
95
+ OK daemon done
96
+ OK pre-commit-hook done
97
+ OK post-edit-hook done
98
+ OK shell-guard done
99
+
100
+ [VibeGuard] Fully active:
101
+
102
+ 1. Daemon — auto-scans every file change
103
+ 2. Pre-commit hook — blocks commits on critical
104
+ 3. Post-edit hook — scans AI agent edits
105
+ 4. Shell guard — blocks dangerous commands
106
+
107
+ Status: vibeguard auto --status
108
+ Stop: vibeguard auto --stop
109
+ Override: VG_OVERRIDE=1 <command>
110
+ ```
111
+
112
+ </div>
113
+
114
+ Or individual commands:
115
+ ```bash
51
116
  vibeguard scan # scan your project
52
117
  vibeguard dashboard # beautiful terminal dashboard
53
118
  vibeguard fix # auto-fix 43 rule types
@@ -141,7 +206,7 @@ vibeguard pre-deploy # 13-gate deployment check
141
206
  <h2>📖 What is VibeGuard?</h2>
142
207
  </div>
143
208
 
144
- VibeGuard is a **free, zero-dependency security and privacy scanner** that runs entirely on your machine. It reads your code files locally, checks them against 699 security rules, and tells you exactly what's wrong and how to fix it — all without sending a single byte to any server.
209
+ VibeGuard is a **free, zero-dependency security and privacy scanner** that runs entirely on your machine. It reads your code files locally, checks them against 693 security rules, and tells you exactly what's wrong and how to fix it — all without sending a single byte to any server.
145
210
 
146
211
  It's built specifically for the problems AI coding tools create:
147
212
  - Hardcoded API keys visible in browser dev tools
@@ -174,7 +239,7 @@ Even if an AI is **fully jailbroken**, it cannot leak data. Each layer runs auto
174
239
  <td align="center">1</td>
175
240
  <td><b>Static Scanner</b></td>
176
241
  <td><code>scanner.js</code></td>
177
- <td>699 security rules across 14 languages</td>
242
+ <td>693 security rules across 14 languages</td>
178
243
  <td>Before deploy</td>
179
244
  </tr>
180
245
  <tr>
@@ -422,7 +487,7 @@ vibeguard pre-deploy --json # JSON output for CI/CD
422
487
 
423
488
  | # | Gate | What It Checks |
424
489
  |---|------|------|
425
- | 1 | Static Scan | 699 rules — any critical? |
490
+ | 1 | Static Scan | 693 rules — any critical? |
426
491
  | 2 | Secret Scan | Secrets exposed in code? |
427
492
  | 3 | Git History | .env tracked in git? |
428
493
  | 4 | Dependency Audit | Slopsquat/typosquat? |
@@ -438,14 +503,56 @@ vibeguard pre-deploy --json # JSON output for CI/CD
438
503
 
439
504
  ---
440
505
 
506
+ <div align="center">
507
+ <h2>🔬 AST Taint Analysis & Confidence</h2>
508
+ </div>
509
+
510
+ VibeGuard uses **scope-aware AST dataflow analysis** (not just regex) to track user input from source to sink:
511
+
512
+ ```js
513
+ const name = req.body.name; // source — tainted
514
+ const cmd = `ls ${name}`; // taint propagates through template literal
515
+ exec(cmd); // sink — command injection confirmed
516
+ ```
517
+
518
+ **Confidence levels** on every finding reduce alert fatigue:
519
+
520
+ | Confidence | Meaning | How it's set |
521
+ |------------|---------|-------------|
522
+ | `high` | Dataflow-confirmed — input traced to sink | AST taint, AST analysis |
523
+ | `medium` | Multi-signal regex with `filter()` | Rules with validation logic |
524
+ | `low` | Bare regex match — heuristic hint | Single-pattern rules |
525
+
526
+ ```bash
527
+ vibeguard scan --min-confidence medium # hide low-confidence hints
528
+ vibeguard scan --show-suppressed # show inline-suppressed findings
529
+ ```
530
+
531
+ **Inline suppression** with reasons:
532
+
533
+ ```js
534
+ const key = "sk_live_..."; // vibeguard-ignore[secret.stripe-live-key]: test fixture
535
+ // vibeguard-ignore-next[code.eval]: intentional eval in REPL
536
+ eval(userInput);
537
+ ```
538
+
539
+ SARIF output maps confidence to `result.properties.confidence` for CI integrations.
540
+
541
+ ---
542
+
441
543
  <div align="center">
442
544
  <h2>📊 Numbers</h2>
443
545
  </div>
444
546
 
547
+ <!-- COUNTS:START -->
548
+ <!-- Auto-generated by scripts/counts.js — do not edit manually -->
549
+ <!-- Rules: 693 | MCP Tools: 75 | Defense Layers: 13 -->
550
+ <!-- COUNTS:END -->
551
+
445
552
  <table>
446
553
  <tr><th>Metric</th><th>Value</th><th></th></tr>
447
- <tr><td>Rules</td><td><b>699</b></td><td>🔒</td></tr>
448
- <tr><td>MCP tools</td><td><b>76</b></td><td>🤖</td></tr>
554
+ <tr><td>Rules</td><td><b>693</b></td><td>🔒</td></tr>
555
+ <tr><td>MCP tools</td><td><b>75</b></td><td>🤖</td></tr>
449
556
  <tr><td>CLI commands</td><td><b>58</b></td><td>💻</td></tr>
450
557
  <tr><td>Auto-fixable rules</td><td><b>43</b></td><td>🔧</td></tr>
451
558
  <tr><td>Defense layers</td><td><b>13</b></td><td>🛡️</td></tr>
@@ -459,7 +566,7 @@ vibeguard pre-deploy --json # JSON output for CI/CD
459
566
  <tr><td>AI Firewall threats</td><td><b>20+</b></td><td>🧱</td></tr>
460
567
  <tr><td>PII types detected</td><td><b>10+</b></td><td>👁️</td></tr>
461
568
  <tr><td>Source modules</td><td><b>43</b></td><td>📦</td></tr>
462
- <tr><td>Tests</td><td><b>236</b></td><td>✅</td></tr>
569
+ <tr><td>Tests</td><td><b>329</b></td><td>✅</td></tr>
463
570
  <tr><td>Lint errors</td><td><b>0</b></td><td>✨</td></tr>
464
571
  <tr><td>Dependencies</td><td><b>1</b> (MCP SDK)</td><td>📦</td></tr>
465
572
  <tr><td>Cost</td><td><b>$0</b></td><td>💚</td></tr>
@@ -469,6 +576,164 @@ vibeguard pre-deploy --json # JSON output for CI/CD
469
576
 
470
577
  ---
471
578
 
579
+ <div align="center">
580
+ <h2>📏 Benchmark (Precision / Recall / F1)</h2>
581
+ </div>
582
+
583
+ We measure VibeGuard against a curated JS vuln corpus — not a fake rule count.
584
+
585
+ <!-- BENCHMARK:START -->
586
+ <!-- Auto-generated by `npm run benchmark` — do not edit manually -->
587
+
588
+ ## Summary
589
+
590
+ | Category | TP | FP | FN | Precision | Recall | F1 |
591
+ |----------|----|----|----|-----------|--------|----|
592
+ | injection | 43 | 10 | 3 | 81.1% | 93.5% | 86.9% |
593
+ | secrets | 17 | 0 | 0 | 100.0% | 100.0% | 100.0% |
594
+ | xss | 4 | 0 | 0 | 100.0% | 100.0% | 100.0% |
595
+ | path-traversal | 9 | 1 | 0 | 90.0% | 100.0% | 94.7% |
596
+ | ai-safety | 7 | 2 | 0 | 77.8% | 100.0% | 87.5% |
597
+ | **OVERALL** | **80** | **13** | **3** | **86.0%** | **96.4%** | **90.9%** |
598
+
599
+ ## Per-Category Details
600
+
601
+ ### injection
602
+
603
+ | File | Rule ID | Verdict |
604
+ |------|---------|---------|
605
+ | cmd-concat.js | `taint.command-injection` | TP |
606
+ | cmd-concat.js | `ast.command-injection` | TP |
607
+ | cmd-concat2.js | `taint.command-injection` | TP |
608
+ | cmd-concat2.js | `ast.command-injection` | TP |
609
+ | cmd-go.go | `go.command-injection` | TP |
610
+ | cmd-py.py | `py.os-system` | TP |
611
+ | cmd-py2.py | `py.subprocess-shell-true` | TP |
612
+ | cmd-py3.py | `py.os-system` | TP |
613
+ | cmd-spawn.js | `taint.command-injection` | TP |
614
+ | cmd-template.js | `taint.command-injection` | TP |
615
+ | cmd-template.js | `ast.command-injection` | TP |
616
+ | eval-input.js | `ast.eval-dynamic` | TP |
617
+ | eval-new-function.js | `ast.function-constructor` | TP |
618
+ | eval-new-function.js | `ast.mass-assignment` | FP |
619
+ | eval-template.js | `ast.eval-dynamic` | TP |
620
+ | eval-template.js | `taint.code-injection` | FP |
621
+ | nosql-where.js | `ast.nosql-injection` | TP |
622
+ | nosql.js | `ast.nosql-injection` | TP |
623
+ | nosql2.js | `ast.nosql-injection` | TP |
624
+ | nosql3.js | `ast.nosql-injection` | TP |
625
+ | open-redirect.js | `web.open-redirect` | TP |
626
+ | open-redirect2.js | `taint.open-redirect` | TP |
627
+ | proto-poll.js | `injection.prototype-pollution` | TP |
628
+ | proto-poll.js | `ast.mass-assignment` | TP |
629
+ | proto-poll2.js | `injection.prototype-pollution` | TP |
630
+ | proto-poll3.js | `injection.prototype-pollution` | TP |
631
+ | sql-concat.js | `code.sql-injection` | TP |
632
+ | sql-concat.js | `taint.sql-injection` | TP |
633
+ | sql-concat2.js | `code.sql-injection` | TP |
634
+ | sql-concat2.js | `taint.sql-injection` | TP |
635
+ | sql-concat3.js | `code.sql-injection` | TP |
636
+ | sql-csharp.cs | `csharp.sql-injection` | TP |
637
+ | sql-csharp.cs | `code.sql-injection` | FP |
638
+ | sql-fstring.py | `py.sql-injection` | TP |
639
+ | sql-fstring2.py | `py.sql-injection` | TP |
640
+ | sql-knex.js | `code.sql-injection` | TP |
641
+ | sql-knex.js | `mikroorm.identifier-from-request` | FP |
642
+ | sql-kotlin.kt | `kotlin.sql-injection` | TP |
643
+ | sql-py-concat.py | `py.sql-injection` | FN |
644
+ | sql-py-concat.py | `code.sql-injection` | FP |
645
+ | sql-raw-rb.js | `code.sql-injection` | TP |
646
+ | sql-raw2.js | `db.sql-template-literal` | TP |
647
+ | sql-sequelize.js | `code.sql-injection` | TP |
648
+ | sql-sprintf.go | `go.sql-fmt-sprintf` | TP |
649
+ | sql-sprintf.go | `go.sql-injection` | FP |
650
+ | sql-sprintf2.go | `go.sql-fmt-sprintf` | TP |
651
+ | sql-sprintf2.go | `go.sql-injection` | FP |
652
+ | sql-template.js | `db.sql-template-literal` | TP |
653
+ | sql-template2.js | `db.sql-template-literal` | FN |
654
+ | sql-template2.js | `injection.orm-raw-user` | FN |
655
+ | sql-template2.js | `taint.sql-injection` | FP |
656
+ | sql-template3.js | `db.sql-template-literal` | TP |
657
+ | ssrf.js | `ast.ssrf` | TP |
658
+ | ssrf2.js | `taint.ssrf` | TP |
659
+ | cmd-array.js | `taint.command-injection` | FP |
660
+ | sql-parameterized.js | `taint.sql-injection` | FP |
661
+
662
+ ### secrets
663
+
664
+ | File | Rule ID | Verdict |
665
+ |------|---------|---------|
666
+ | conn-string.js | `secret.connection-string` | TP |
667
+ | docker-build-arg.js | `ai.key-in-url` | TP |
668
+ | env-secret.js | `secret.high-entropy` | TP |
669
+ | generic-secret.js | `secret.generic-credential` | TP |
670
+ | github-token.js | `secret.github-token` | TP |
671
+ | github-token2.js | `secret.github-token` | TP |
672
+ | github-token2.js | `secret.high-entropy` | TP |
673
+ | gitlab-token.js | `secret.gitlab-token` | TP |
674
+ | mailgun-key.js | `secret.mailgun-key` | TP |
675
+ | mailgun-key.js | `secret.high-entropy` | TP |
676
+ | npm-token.js | `secret.npm-token` | TP |
677
+ | npm-token.js | `secret.high-entropy` | TP |
678
+ | resend-key.js | `secret.resend-key` | TP |
679
+ | sendgrid-key.js | `secret.sendgrid-key` | TP |
680
+ | slack-token.js | `secret.slack-token` | TP |
681
+ | stripe-key.js | `secret.generic-credential` | TP |
682
+ | stripe-key.js | `stripe.key-in-client` | TP |
683
+
684
+ ### xss
685
+
686
+ | File | Rule ID | Verdict |
687
+ |------|---------|---------|
688
+ | dangerously-html.jsx | `react.dangerous-html` | TP |
689
+ | dangerously-html2.jsx | `react.dangerous-html` | TP |
690
+ | dangerously-html2.jsx | `ai.llm-output-dom` | TP |
691
+ | eval-llm-output.js | `ai.llm-output-dom` | TP |
692
+
693
+ ### path-traversal
694
+
695
+ | File | Rule ID | Verdict |
696
+ |------|---------|---------|
697
+ | append-file.js | `taint.path-traversal` | TP |
698
+ | create-read-stream.js | `taint.path-traversal` | TP |
699
+ | path-join-template.js | `upload.filename-path-traversal` | TP |
700
+ | read-concat.js | `taint.path-traversal` | TP |
701
+ | read-template.js | `ai.tool-broad-file-access` | TP |
702
+ | read-template.js | `taint.path-traversal` | TP |
703
+ | sendfile.js | `taint.path-traversal` | TP |
704
+ | unlink-concat.js | `taint.path-traversal` | TP |
705
+ | write-concat.js | `taint.path-traversal` | TP |
706
+ | allowlist.js | `taint.path-traversal` | FP |
707
+
708
+ ### ai-safety
709
+
710
+ | File | Rule ID | Verdict |
711
+ |------|---------|---------|
712
+ | agent-deploy.js | `ai.agent-can-deploy` | TP |
713
+ | agent-secrets.js | `ai.agent-can-access-secrets` | TP |
714
+ | llm-output-dom.js | `ai.llm-output-dom` | TP |
715
+ | llm-output-exec.js | `ai.llm-output-shell` | TP |
716
+ | llm-output-exec.js | `taint.command-injection` | TP |
717
+ | llm-output-exec.js | `ast.command-injection` | TP |
718
+ | tool-poisoning.js | `ai.mcp-description-injection-deep` | TP |
719
+ | agent-safe-config.js | `ai.agent-can-deploy` | FP |
720
+ | agent-safe-config.js | `ai.agent-can-access-secrets` | FP |
721
+
722
+ ## Methodology
723
+
724
+ - **True Positive (TP)**: Expected rule fires on a vuln file.
725
+ - **False Positive (FP)**: Any finding on a clean file, or an unexpected rule on a vuln file.
726
+ - **False Negative (FN)**: Expected rule that did not fire on a vuln file.
727
+ - **Precision** = TP / (TP + FP)
728
+ - **Recall** = TP / (TP + FN)
729
+ - **F1** = 2 * (Precision * Recall) / (Precision + Recall)
730
+
731
+ Generated: 2026-07-12T03:43:25.339Z
732
+
733
+ <!-- BENCHMARK:END -->
734
+
735
+ ---
736
+
472
737
  <div align="center">
473
738
  <h2>🔒 Privacy Guarantee</h2>
474
739
  </div>
@@ -541,7 +806,9 @@ Templates included for: **GitLab CI**, **Jenkins**, **CircleCI**, **Azure Pipeli
541
806
 
542
807
  ```bash
543
808
  npm install
544
- npm test # 236 tests
809
+ npm test # 329 tests
810
+ npm run benchmark # precision/recall/F1 benchmark
811
+ npm run counts # self-generating rule/tool counts
545
812
  npm run lint # 0 errors
546
813
  npm run coverage # coverage report
547
814
  ```
@@ -573,16 +840,21 @@ MIT — Free forever. No ads. No tracking. No data collection.
573
840
 
574
841
  <div align="center">
575
842
 
576
- <!-- Author Section -->
577
- <img src="https://readme-typing-svg.herokuapp.com?font=Fira+Code&weight=600&size=22&pause=1000&color=2E75B6&center=true&vCenter=true&random=false&width=400&lines=Made+with+%E2%9D%A4%EF%B8%8F+by;Yagyesh+Vyas" alt="Made by Yagyesh Vyas" />
843
+ <!-- Author Section with Animation -->
844
+ <img src="https://readme-typing-svg.herokuapp.com?font=Fira+Code&weight=600&size=22&duration=2000&pause=300&color=2E75B6&center=true&vCenter=true&random=false&width=400&lines=Made+with+%E2%9D%A4%EF%B8%8F+by+Yagyesh+Vyas;Star+%E2%AD%90+if+VibeGuard+helped+you;Open+source+%7C+MIT+License;Zero+telemetry+%7C+100%25+local" alt="Made by Yagyesh Vyas" />
578
845
 
579
846
  <br/>
580
847
 
581
848
  <a href="https://www.linkedin.com/in/yagyeshvyas/">
582
- <img src="https://img.shields.io/badge/LinkedIn-0077B5?style=for-the-badge&logo=linkedin&logoColor=white" alt="LinkedIn" />
849
+ <img src="https://img.shields.io/badge/LinkedIn-%230077B5.svg?style=for-the-badge&logo=linkedin&logoColor=white" alt="LinkedIn" />
583
850
  </a>
851
+ &nbsp;
584
852
  <a href="https://github.com/yagyeshVyas">
585
- <img src="https://img.shields.io/badge/GitHub-100000?style=for-the-badge&logo=github&logoColor=white" alt="GitHub" />
853
+ <img src="https://img.shields.io/badge/GitHub-%23121011.svg?style=for-the-badge&logo=github&logoColor=white" alt="GitHub" />
854
+ </a>
855
+ &nbsp;
856
+ <a href="https://www.npmjs.com/package/vibeguard">
857
+ <img src="https://img.shields.io/badge/npm-%23CB3837.svg?style=for-the-badge&logo=npm&logoColor=white" alt="npm" />
586
858
  </a>
587
859
 
588
860
  <br/>
@@ -590,11 +862,10 @@ MIT — Free forever. No ads. No tracking. No data collection.
590
862
 
591
863
  <p><b>⭐ If VibeGuard helped you, star the repo!</b></p>
592
864
 
593
- <p>Found a bug? <a href="https://github.com/yagyeshVyas/VibeGuard/issues">Open an issue</a></p>
594
- <p>Want to contribute? <a href="https://github.com/yagyeshVyas/VibeGuard/pulls">Submit a PR</a></p>
865
+ <p>Found a bug? <a href="https://github.com/yagyeshVyas/VibeGuard/issues">Open an issue</a> · Want to contribute? <a href="https://github.com/yagyeshVyas/VibeGuard/pulls">Submit a PR</a></p>
595
866
 
596
867
  <br/>
597
868
 
598
- <p><sub>VibeGuard v0.1.0 · MIT License · 699 rules · 76 MCP tools · 13 defense layers · $0 cost · zero telemetry</sub></p>
869
+ <p><sub>VibeGuard v0.1.0 · MIT License · 693 rules · 75 MCP tools · 13 defense layers · $0 cost · zero telemetry</sub></p>
599
870
 
600
871
  </div>