Disclosed vulnerability
Caught in the Hook: RCE and API token exfiltration through Claude Code project files
AIR-2026-0051 AIR record · 2026-02-checkpoint-claude-code-project-files
From the supporting source
An attacker could place this configuration in a malicious repository: When a victim clones the repository and runs claude, their API key would be sent directly to the attacker's server - before the victim decides to trust the directory.research.checkpoint.com
The record
Disclosed
2026-02-25
Vendor
Anthropic
Product
Claude Code
Risk domain
Tool misuse › Supply chain vulnerabilities
Also touches
Credential theft, Privilege escalation
System type
Generative model
Who acted
Agent acted — repo-controlled hooks made Claude Code execute and exfiltrate tokens
Attack surface
Coding agent
Autonomy level
Semi-autonomous
Initial vector
Malicious repository workspace config
Impact type
Remote code execution, Credential theft
Confidence
High
Submitted by
EAI Internal
Crosswalk
- OWASP Agentic Top 10 (2026)
- ASI04 – Agentic Supply Chain Vulnerabilities
- MITRE ATLAS
- AML.T0040 – AI Supply Chain Compromise
- NIST AI RMF
- MAP 4.1
- EU AI Act
- Annex III §2
- ISO/IEC
- TR 24028; 42001; 23894
- AIUC-1
- B. Security
- Scope
- tool failure
- Mitigation
- Scan dependencies and container images for vulnerabilities; Use trusted sources.
- Taxonomy
- Enkrypt AI agent risk taxonomy · Black-Box Red Teaming of Agentic AI: A Taxonomy-Driven Framework for Automated Risk Discovery
Blast radius
Developers cloning and opening untrusted repositories with Claude Code
Capability abused
Defense & remediation
Recorded defense
Claude Code startup trust dialog
Guardrail kinds
Unknown
Guardrail outcome
Silent
Fix shipped
Fixed across releases from August 2025; hooks issue fixed in 1.0.111 (October 2025); final CVE published January 2026
Taxonomy & references
Curator notes
Authors Aviv Donenfeld and Oded Vanunu. Three mechanisms: repo-controlled .claude/settings.json hooks executing before the trust dialog completes, enableAllProjectMcpServers auto-initializing malicious MCP servers, and a malicious ANTHROPIC_BASE_URL intercepting API keys. CVSS 8.7. All patched before publication.
Supporting sources
Cite as
Enkrypt AI. "Caught in the Hook: RCE and API token exfiltration through Claude Code project files". AIR, AIR-2026-0051. https://agentincident.vercel.app/i/AIR-2026-0051/ (accessed 2026-10-19).