Skip to content
项目

关于

Security Scan orchestrator for AI Agents 🎯

安全与隐私

这些数字如何统计

实测星标增长

24小时
0
7天
0
15天
0
1个月
+1

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文
Parsentry Logo

Security Scan orchestrator for AI Agents.

Parsentry analyzes repository structure, enumerates attack surfaces, and generates per-surface analysis prompts. An agent runtime (Claude Code, Codex CLI, OpenCode, Crush) drives the scan loop for parallel security analysis.

Ask DeepWiki | 日本語

Agent Skill

npx skills add HikaruEgashira/parsentry

Once installed, just ask your agent to scan a repository — the skill dispatches the scan process automatically.

Usage

Ask your agent to scan a target (e.g. "scan owner/repo with parsentry"). The agent runtime runs parsentry scan owner/repo, dispatches the emitted prompts (one agent per surface, in parallel), and re-runs parsentry scan until it prints PARSENTRY_SCAN_COMPLETE.

scan is the only command you need. It inspects the cache and emits the prompt for the next phase (threat model → per-surface analysis → report).

Deprecated: pipe mode (parsentry scan owner/repo | claude -p) still works but prints a deprecation warning on stderr. Use the agent runtime (skill) instead. Add -o report.pdf to also render a PDF.

The scan mode is decided from state, not flags:

State Mode
No threat model Full scan
Threat model is current, some sources changed Incremental scan — only affected surfaces re-run
Repository structure changed since the model was built Model diff scan — the previous model and its findings are kept, a new model is built, and the report diffs the findings of both models

See HACKING.md for usage with other CLI agents.

How it works

parsentry scan  ─┬─ model phase    →  threat model prompt                →  model.json
                 ├─ surface phase  →  orchestrator + per-surface prompts →  SARIF files
                 └─ report phase   →  merged.sarif.json + report.md (+ PDF)
parsentry log   →  monitor scan progress in real-time
  1. Model — Collect repo metadata (languages, manifests, entry points), generate a threat model prompt. The agent enumerates attack surfaces into model.json.
  2. Surfaces — Read source code per surface, generate focused prompt.md files and an orchestrator prompt that launches parallel subagents — each writes SARIF results. Surfaces whose definition and sources are unchanged are skipped.
  3. Report — Merge SARIF of the current model's surfaces and write report.md (with a model diff section when a previous model exists).
  4. Log — Stream scan progress like docker compose logs -f.

Webhook server

parsentry serve [--host 127.0.0.1] [-p 8765] [--token TOKEN] serves GET /api/runs and GET /api/findings?run=&verdict=&level=&cwe= over cached scans. POST /api/scans with {"target": "owner/repo or path", "runtime"?, "output"?, "env"?} enqueues a scan and returns 202 {"id": N}; GET /api/events is a text/event-stream of job events (queued, started, log, finished, failed) as JSON. A non-loopback --host is refused unless --token (or PARSENTRY_API_TOKEN) is set, and with a token every /api/ request needs Authorization: Bearer TOKEN. It also listens on POST /webhooks/github and enqueues an incremental scan for push and pull_request (opened / synchronize / reopened) events. Set GITHUB_WEBHOOK_SECRET to verify X-Hub-Signature-256.

docker run -p 8080:8080 -e GITHUB_WEBHOOK_SECRET=... ghcr.io/hikaruegashira/parsentry

Install

# Via mise
mise use -g github:HikaruEgashira/parsentry

# Via cargo
cargo install parsentry

Example Reports

Repository Surfaces
langgenius/dify 25
OWASP/NodeGoat 19
HikaruEgashira/hikae-vulnerable-python 25

License

AGPL 3.0

探索相关项目

加载中…