/ Directory / Playground / repo-forensics
● Community alexgreensh ⚡ Instant

repo-forensics

by alexgreensh · alexgreensh/repo-forensics

18 defensive scanners that vet a repo, skill, MCP server, or plugin for prompt injection, secrets, lifecycle hooks, typosquats, and tamper traces before you install.

Repo-forensics is a defensive audit tool aimed at the 'nobody does it' problem: vetting third-party code before installing it with full system access. 18 parallel scanners cover runtime dynamism, manifest drift, prompt-injection in SKILL.md, MCP tool poisoning, DAST of hook scripts, secrets, SAST, AST analysis, dependency typosquats, lifecycle hooks, entropy payloads, IaC misconfigs, binary disguises, post-incident traces, and git-commit spoofing. Zero deps.

Why use it

Key features

Live Demo

What it looks like in practice

repo-forensics-skill.replay ▶ ready
0/0

Install

Author repository · Claude Skills documentation

Use Cases

Real-world ways to use repo-forensics

Audit a third-party skill before you clone it into ~/.claude/skills

👤 Anyone installing skills from strangers on GitHub ⏱ ~15 min beginner

When to use: Someone sent you a cool-looking skill link. Before clone, you want to know if it's safe.

Flow
  1. Point at the target repo URL
    Use repo-forensics. Scan https://github.com/<author>/<skill> with the skill_threats, secrets, dataflow, and lifecycle scanners. Report findings.✓ Copied
    → Per-scanner report with severity flags
  2. Read correlated findings
    Any correlations across scanners — e.g. a secret-leak path plus a lifecycle hook?✓ Copied
    → Correlation summary

Outcome: A go / no-go decision grounded in scanner output, not vibes.

Pitfalls
  • Trusting a green scan as full proof of safety — Scanners are strong floor, not a ceiling — still read SKILL.md
Combine with: github · filesystem

Audit an MCP server for tool poisoning and rug-pull patterns

👤 Teams onboarding a new MCP into a production agent stack ⏱ ~20 min intermediate

When to use: Before adding a new MCP server to an agent with real permissions.

Flow
  1. Run MCP-focused scanners
    Scan this MCP server repo with mcp_security, skill_threats, integrity, and dast.✓ Copied
    → Findings focused on tool descriptions and install scripts
  2. Check git history for identity spoofing
    Run git_forensics on the same repo — any spoofed commits?✓ Copied
    → Author / signing analysis

Outcome: An MCP security dossier before you wire it into your agent.

Run post-incident scanners after a suspicious install

👤 Anyone who just ran npm/pip install and feels uneasy ⏱ ~15 min intermediate

When to use: Install finished with unexpected behavior; you want to know if something landed.

Flow
  1. Run post_incident + entropy scans
    Run post_incident scanner on ~/.npm and the current project. Also entropy scan the installed packages.✓ Copied
    → Flags for suspicious cached artifacts or encoded payloads

Outcome: Evidence of whether to rotate secrets and rebuild.

Pitfalls
  • Running scans from the potentially-compromised shell — Run from a fresh shell or another machine when in doubt

Combinations

Pair with other MCPs for X10 leverage

repo-forensics-skill + github

Pull a PR's diff and scan only the added files

Fetch PR #123 and run repo-forensics just on the files it adds.✓ Copied
repo-forensics-skill + filesystem

Scan a locally cloned repo and save a JSON report

Scan ./suspicious-repo and write findings.json next to it.✓ Copied

Tools

What this MCP exposes

ToolInputsWhen to callCost
skill_threats repo path Any skill audit 0
mcp_security repo path MCP audits 0
secrets repo path Always 0
dataflow repo path Suspicious egress concerns 0
lifecycle repo path Pre-install 0
git_forensics repo path Checking maintainer identity 0
entropy repo path Obfuscation suspected 0
sast repo path General code risk 0

Cost & Limits

What this costs to run

API quota
None
Tokens per call
Moderate — scanner output summarization can grow
Monetary
Free
Tip
Run only the scanners relevant to the threat model (skills → skill_threats; MCP → mcp_security)

Security

Permissions, secrets, blast radius

Credential storage: None — scanner is read-only
Data egress: Local-only by default
Never grant: Write access to the repo under audit

Troubleshooting

Common errors and fixes

Scanner reports 0 findings on obviously sketchy repo

Ensure you ran against the full repo path, not a subset; check scanner selection

Verify: repo-forensics list-scanners
False positives flood the report

Filter by severity; focus on high/critical; use correlation to prioritize

Alternatives

repo-forensics vs others

AlternativeWhen to use it insteadTradeoff
claude-cybersecurityYour code needs OWASP-style app security review rather than supply-chain vettingDifferent focus — app logic vs install-time threats
gitleaks / trufflehogYou only need secret scanningSingle-scanner, not correlation

More

Resources

📖 Read the official README on GitHub

🐙 Browse open issues

🔍 Browse all 400+ MCP servers and Skills

Continue exploring

Related tools and workflows

Choose another guide for your workflow, or explore a collection.

Browse all topic collections → · See 29 new official additions →