Be careful opening untrusted repos in Claude Code
Claude Code project files could run commands and leak API keys · Security incident · Web · _CPResearch_ · Feb 2026
Check Point disclosed two CVEs where malicious Claude Code project settings (hooks, MCP config, base URL) could run commands or send the API key elsewhere. Anthropic patched both before disclosure.
Lesson
Review .claude and MCP config files in cloned repos before trusting them, and keep agents updated.
Fix prompt
Copy this into your own AI tool (Cursor, Lovable, Claude Code, Bolt…). It's general guidance written by us. Review what the AI suggests before applying it.
I use Claude Code, which can read web pages, files, emails or tool output. Help me reduce the risk of prompt injection (hidden instructions in content the AI reads). 1) List what my setup can access (files, terminal, browser, MCP servers, email, databases) and what it can do without asking me. 2) Point out the riskiest combinations, e.g. reading untrusted content while also having access to secrets or the ability to send data out. 3) Suggest concrete settings: require approval for commands and network calls, remove MCP servers I don't need, use read-only tokens, and keep the tool updated. 4) Give me a short checklist to follow before opening untrusted repos or documents. Don't change anything until I've approved your plan. Never ask me to paste API keys, passwords or .env contents; tell me where to check them myself.
Source: Web ↗