npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

sentinel-ai-cli

v1.0.8

Published

AI-powered CLI that scans repositories and reports security vulnerabilities.

Readme


⚡ Why Sentinel?

Traditional security tools rely solely on superficial regex pattern matching or unguided text prompts that trigger high false-positive rates and corrupt source files when attempting fixes.

Sentinel compiles your codebase into Sentinel IR, builds a Knowledge Graph, synthesizes multi-hop Attack Graphs, extracts deep multi-file codebase context (interfaces, exports, dependencies), performs CISO-grade reasoning powered by Gemini 2.5 Flash, and applies autonomous fixes backed by zero-breakage verification and snapshot rollback.

Polyglot Source Code ──► Sentinel IR ──► Security Knowledge Graph ──► Attack Graph ──► Deep Multi-File Context ──► Gemini 2.5 Flash Reasoning ──► Autonomous Patching & Zero-Breakage Verification

🚀 Quick Start & Installation

Option 1: Global npm Installation

npm install -g sentinel-ai-cli

Option 2: Run directly via npx

npx sentinel-ai-cli attack .

Option 3: Local Clone & Development

git clone https://github.com/Drix10/sentinal.git
cd sentinal
npm install
npm run build
npm run start -- attack .

🔑 Configuration & API Key Setup

Sentinel uses Gemini 3.5 Flash for deep security analysis. Get a free API key from Google AI Studio.

Configure your API key:

sentinel set-key

Sentinel validates the key and securely saves it locally to ~/.sentinel/config.json.


💻 CLI Commands & Workflow

1. Execute Security Scan & Attack Graph Synthesis (sentinel attack)

Analyze current directory:

sentinel attack .

Export GitHub-compatible SARIF 2.1.0 report for GitHub Code Scanning / Security Tab:

sentinel attack . --format sarif --output sentinel-report.sarif

Export JSON format report:

sentinel attack . --format json --output sentinel-report.json

2. System Diagnostic Check (sentinel doctor)

Run environment, Node.js version, TSConfig, and Gemini API key diagnostics:

sentinel doctor

3. Deep Finding Explanation (sentinel explain)

View forensic root-cause analysis, exploit mechanics, CIA triad impact, OWASP details, and step-by-step developer remediation:

sentinel explain FINDING-100

4. Autonomous AI Patching & Verification (sentinel fix)

Synthesize a drop-in secure code patch with deep codebase awareness and run automated zero-breakage verification (AST diagnostics, tsc compilation, test runner execution, and detector re-scans) before finalizing the fix:

sentinel fix FINDING-100

Preview Diff Without Modifying Disk (--dry-run):

sentinel fix FINDING-100 --dry-run

Skip Compiler/Test Verification (--no-verify):

sentinel fix FINDING-100 --no-verify

🛡️ Zero-Breakage Guarantee: If a patch introduces compilation or test regressions, Sentinel automatically invokes AI self-correction retry, and restores the pre-patch snapshot from .sentinel/backups/ if verification fails.

5. Ignore Finding (sentinel ignore)

Mark a finding as ignored with an optional developer justification reason:

sentinel ignore FINDING-100 --reason "Mitigated by upstream Cloudflare WAF rule"

📊 Example Terminal Output

 ╔══════════════════════════════════════════════════════════════════════╗
 ║      S E N T I N E L   A I   S E C U R I T Y   P L A T F O R M       ║
 ║      Deterministic Program Analysis • Attack Graph • AI Reasoning    ║
 ╚══════════════════════════════════════════════════════════════════════╝

 Target: /path/to/target-repo

✔ Project Detected & Topology Analyzed

┌────────────────────────┬───────────────────────────────────────────────────┐
│ PROPERTY               │ VALUE / METADATA                                  │
├────────────────────────┼───────────────────────────────────────────────────┤
│ Project Name           │ my-app-backend                                    │
│ Framework              │ Express                                           │
│ Language               │ TypeScript                                        │
│ Package Manager        │ npm                                               │
│ Source Directory       │ src                                               │
│ Docker Configured      │ No                                                │
│ Env Configured         │ Yes                                               │
└────────────────────────┴───────────────────────────────────────────────────┘

┌── [+] SENTINEL IR COMPILER METRICS (@sentinel/plugin-typescript) ──────────┐
│ IR Project Compilation: Successful                                         │
│ AST Source Files Parsed: 32                                                │
│ Extracted API Routes: 32                                                   │
│ AST Node Processing: TypeScript Morph Plugin Active                        │
└────────────────────────────────────────────────────────────────────────────┘

✔ Discovered 44 HTTP API routes
┌────────┬──────────────────────────────────────┬────────────────────────────┐
│ METHOD │ ROUTE PATH                           │ SOURCE FILE                │
├────────┼──────────────────────────────────────┼────────────────────────────┤
│ GET    │ /health                              │ src/index.ts               │
│ POST   │ /analyze                             │ src/routes/ai-mrv.routes.ts│
│ POST   │ /login                               │ src/routes/auth.routes.ts  │
└────────┴──────────────────────────────────────┴────────────────────────────┘

✔ Found 43 package dependencies
┌──────────────────────────────────────┬──────────────────┬──────────────────┐
│ PACKAGE NAME                         │ VERSION          │ SCOPE            │
├──────────────────────────────────────┼──────────────────┼──────────────────┤
│ @google/generative-ai                │ 0.21.0           │ dependency       │
│ express                              │ 4.18.2           │ dependency       │
└──────────────────────────────────────┴──────────────────┴──────────────────┘

✔ Found 0 secret patterns
┌── [+] KNOWLEDGE GRAPH & ATTACK GRAPH ENGINE MATRIX ────────────────────────┐
│ Knowledge Graph Nodes: 112 (Routes, Secrets, Dependencies)                 │
│ Topology Edges: 2992 (USES_DEPENDENCY, READS_SECRET)                       │
│ Synthesized Exploit Paths: 0 Attack Graph Vectors                          │
└────────────────────────────────────────────────────────────────────────────┘

✔ Security Report Synthesized Successfully!

 ┌──────────────────────────────────────────────────────────────────────────┐
 │  SECURITY RISK SCORE: 95/100   [█████████████████████████████░]          │
 │  STATUS: GOOD SECURITY POSTURE                                           │
 └──────────────────────────────────────────────────────────────────────────┘

┌── [+] EXECUTIVE SUMMARY ───────────────────────────────────────────────────┐
│ The security assessment of the target project reveals a robust baseline    │
│ posture. Sentinel's engines detected zero active multi-hop attack graph    │
│ exploit vectors and no exposed hardcoded secrets.                          │
└────────────────────────────────────────────────────────────────────────────┘

┌── [+] ATTACK SURFACE DISCOVERED ───────────────────────────────────────────┐
│ 1. 44 HTTP API endpoints                                                   │
│ 2. 43 runtime dependencies                                                 │
└────────────────────────────────────────────────────────────────────────────┘

 [+] FINDING LIFECYCLE STORE SUMMARY
┌───────────────┬────────────┬─────────────────────────┬────────────┬────────┐
│ ID            │ SEVERITY   │ VULNERABILITY TITLE     │ LOCATION   │ CONF.  │
├───────────────┼────────────┼─────────────────────────┼────────────┼────────┤
│ FINDING-100   │ LOW        │ Outdated AWS SDK Maj... │ Depende... │ 90%    │
└───────────────┴────────────┴─────────────────────────┴────────────┴────────┘

┌── [+] NEXT STEPS & ACTION PLAN ────────────────────────────────────────────┐
│ DEVELOPER REMEDIATION WORKFLOW & NEXT STEPS:                               │
│                                                                            │
│  1. Examine OWASP Details & Source Evidence:                               │
│     sentinel explain FINDING-100                                           │
│                                                                            │
│  2. Synthesize Autonomous AI Security Patch:                               │
│     sentinel fix FINDING-100                                               │
│                                                                            │
│  3. Triage False Positives or Accept Risk:                                 │
│     sentinel ignore FINDING-100 --reason "Reviewed by AppSec team"         │
│                                                                            │
│  4. Re-verify Code Base After Remediation:                                 │
│     sentinel attack .                                                      │
│                                                                            │
│  Findings persisted to: .sentinel/findings.json                            │
└────────────────────────────────────────────────────────────────────────────┘

🛠️ Technology Stack

  • Core Runtime: TypeScript 5.x, Node.js (ES2022)
  • AST Compiler & IR: ts-morph, fast-glob
  • AI Reasoning Engine: @google/generative-ai (gemini-3.5-flash with gemini-3.0-flash fallback)
  • CLI Framework & UI: commander, chalk, ora

📄 License

MIT License


Made with ❤️ to help developers hack themselves first.