OS Command Injection Vulnerability in Anthropic Claude Code CLI and Claude Agent SDK
CVE-2026-35021
8.4HIGH
What is CVE-2026-35021?
The Anthropic Claude Code CLI and Claude Agent SDK expose a significant vulnerability that enables OS command injection through the prompt editor utility. By manipulating file paths with malicious input, attackers can exploit shell metacharacters like $() or backticks. These crafted file paths, despite being quoted, can still lead to command substitution and arbitrary command execution with the permissions of the invoking user. This vulnerability highlights the importance of proper input validation and sanitization to prevent unauthorized command execution.
Affected Version(s)
Claude Agent SDK for Python 0 <= 0.1.55
Claude Code 0 <= 2.1.91
References
CVSS V4
Score:
8.4
Severity:
HIGH
Confidentiality:
High
Integrity:
High
Availability:
High
Attack Vector:
Local
Attack Complexity:
Low
Attack Required:
None
Privileges Required:
Undefined
User Interaction:
Unknown
Timeline
- ๐ก
Public PoC available
- ๐พ
Exploit known to exist
Vulnerability published
Vulnerability Reserved
Credit
Francesco Cipollone
