Skip to content
AnthropicGHSA-mhg7-666j-cqg4

Command Injection via Piped sed Command Bypasses File Write Restrictions

High7.7CVE-2026-25723 · Published Feb 6, 2026

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. Users on standard Claude Code auto-update received this fix automatically. Users performing manual updates are advised to update to the latest version. Thank you to hackerone.com/nil221 for reporting this issue!

GitHub advisory

Affected versions

PackageAffectedFixed in
@anthropic-ai/claude-code
npm
< v2.0.55v2.0.55
Details and references
CVSS 4.0
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Severity from
GitHub (reviewed advisory)
Weakness
CWE-20, CWE-78

More Anthropic advisories

All Anthropic

Critical advisories by email

Wednesdays: the week’s critical and high advisories in the AI and data stack, with the fixed versions. Only in weeks that have some.

Double opt-in. Unsubscribe any time.