Anthropics claude-code
Claude Code Vulnerable to Command Injection via Piped sed Command Bypasses File Write Restrictions
Claude Code is an agentic coding tool. Prior to version 2.0.55, Claude Code failed to properly validate commands using piped sed operations with the echo command, allowing attackers to bypass file write restrictions. This vulnerability enabled writing to sensitive directories like the .claude folder and paths outside the project scope. Exploiting this required the ability to execute commands through Claude Code with the "accept edits" feature enabled. This issue has been patched in version 2.0.55.
First public PoC
None yetno public PoC found
Public PoCs00 on GitHub
CVSS7.7high · scored by CNA · CWE-20
CISA KEV
Not listednot known exploited
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
anthropics claude-code
- < 2.0.55
Fixed in 2.0.55
Mitigation
Upgrade claude-code to 2.0.55 or later.
References
- Vendor advisory github.com/anthropics/claude-code/security/adv…
Timeline
Days relative to CVE publicationNo public PoC found yet; not in CISA KEV.
PoC repositories
Found on GitHub.No PoC repositories found yet.