Claude Code hook
Medusa
AI-first security scanner. NEW in v2026.7: Claude Code compromise detection — vet .claude/ hooks, permissions & skills before you clone — plus an always-on AI attack-signature scanner and native Rust & PHP rules. Also: medusa scan --git to vet any repo, medusa secrets scan for leaked API keys. 40,000+ patterns, zero setup.
Install
pip install medusa-securityFound in the project README. Check it for setup steps after installing.
git clone https://github.com/Pantheon-Security/medusa.gitFrom the README
🐍 MEDUSA - AI Security Scanner AI-first security scanner with 40,000+ detection patterns for AI/ML, agents, and LLM applications. 🤖 Works out of the box - no tool installation required. 🚨 200 CVEs: Log4Shell, Spring4Shell, XZ Utils, LangChain RCE, MCP-Remote RCE, React2Shell 🔥 medusa scan --git — Scan any repo for AI supply chain attacks (repo poisoning, prompt injection, MCP tool poisoning) 🔐 medusa secrets scan — Find leaked API keys in your Claude / Cursor / Copilot / shell history. 21 issuer types. Interactive in-place redaction. 🚀 v2026.7.0: Claude Code compromise detection, an always-on AI attack-signature scanner, native Rust & PHP security rules, and rule-level diagnostics — on top of 40,000+ detection patterns. 🎯 What is MEDUSA? MEDUSA is an AI-first security scanner with 40,000+ detection patterns that works out of the box. Simply install and scan - no external tool installation required. MEDUSA's built-in rules detect vulnerabilities in AI/ML applications, LLM agents, MCP servers, RAG pipelines, and traditional code. ✨ Key Features - 🔥 medusa scan --git - Scan any GitHub repo for AI supply chain attacks in seconds - 🔐 medusa secrets scan + purge - Find API keys / tokens / private keys leaked into Claude Code / Cursor / Copilot / Zed / Gemini chat histories *and* your bash / zsh / psql / mysql / python REPL history. 21 issuer types (Anthropic, OpenAI, PyPI, GitHub PATs, AWS, GCP, Stripe, Slack…). Interactive [y/n/s/a/q] purge with mandatory byte-identical backup and JSONL-safe redaction. Local-only, no telemetry. - 🤖 40,000+ AI Security Patterns - Industry-leading coverage for AI/ML, agents, and LLM applications - 🛡️ Repo Poisoning Detection - Detects weaponized AI editor configs across 28+ file types (Cursor, Cline, Copilot, Claude Code,…
How hooks work
- Hooks are shell commands Claude Code runs at fixed points: before or after a tool call, when you submit a prompt, when Claude stops, on notifications and at session start.
- They are set in the hooks section of ~/.claude/settings.json (or .claude/settings.json for a project), or come bundled in a plugin.
- A hook can block a tool call, add context, or run a formatter or test. Read the scripts before you install them: they run on your machine with your permissions.
Details
- Repository
- Pantheon-Security/medusa
- Type
- Hooks
- Website
- pantheonsecurity.io
- Language
- Python
- License
- AGPL-3.0
- Last updated
- 10 August 2026
- Topics
- agent-securityai-securitycode-analysiscve-detectiondevsecopsllm-securitymcpnextjsopen-sourcepythonreactsast
- Listed in
- jqueryscript/awesome-claude-code
FAQ
What is Medusa?
AI-first security scanner. NEW in v2026.7: Claude Code compromise detection — vet .claude/ hooks, permissions & skills before you clone — plus an always-on AI attack-signature scanner and native Rust & PHP rules. Also: medusa scan --git to vet any repo, medusa secrets scan for leaked API keys. 40,000+ patterns, zero setup. It is a hook for Claude Code, from Pantheon-Security/medusa on GitHub.
How do I install Medusa?
Run pip install medusa-security, then follow the setup in the README.
Is Medusa popular?
Pantheon-Security/medusa has 1,013 GitHub stars and 153 forks, and is included in 1 curated Claude Code list. It was last updated on 10 August 2026.
More hooks
Kubb
1.8kkubb-labs/kubb
Turn your API spec into type-safe code. Generate TypeScript types, API clients, hooks, validators and mocks from a spec such as OpenAPI.
Claude Code Voice Hooks
563shanraisshan/claude-code-hooks
Adds spoken voice feedback to each Claude Code hook event.
claude-code-hooks
572karanb192/claude-code-hooks
Collection of safety, cost, observability and productivity hooks, also installable as a plugin marketplace.
Claude Code Tamagotchi
435Ido-Levi/claude-code-tamagotchi
Virtual pet that watches Claude's actions through hooks and interrupts when it breaks your rules.
Everything Claude Code Zh
2kxu-xiang/everything-claude-code-zh
everything-claude-code 中文翻译项目:完整的 Claude Code 配置集合(agents, skills, hooks, commands, rules, MCPs)。源自 Anthropic 黑客松获胜者的实战配置,助力中文工程师高效理解与使用 Claude Code。
Claude Code Config
1.1kjarrodwatts/claude-code-config
My personal Claude Code configuration - rules, hooks, agents, skills, and commands
Browse the most popular Claude Code mods, all hooks, or the skills and MCP server directories.