Claude Code Vulnerable to Command Injection via Directory Change Bypasses Write Protection
Default status is the baseline for the product, each version can override it (e.g. patched versions marked unaffected).
| Vendor | Product | Default status | Versions | ||||||
|---|---|---|---|---|---|---|---|---|---|
| anthropics | claude-code | affected |
|
No data.
| Vendor | Product | Versions |
|---|---|---|
| Anthropics | Claude Code | — |
| Source | ID | Title |
|---|---|---|
Github GHSA |
GHSA-66q4-vfjg-2qhh | Claude Code Vulnerable to Command Injection via Directory Change Bypasses Write Protection |
No CVSS v3.0
No CVSS v2
This CVE is not in the KEV list.
Exploit prediction score: < 1% (0.509% probability within 30 days)
| Type | Values Removed | Values Added |
|---|---|---|
| First Time appeared |
Anthropic
Anthropic claude Code |
|
| CPEs | cpe:2.3:a:anthropic:claude_code:*:*:*:*:*:node.js:*:* | |
| Vendors & Products |
Anthropic
Anthropic claude Code |
|
| Metrics |
cvssV3_1
|
| Type | Values Removed | Values Added |
|---|---|---|
| First Time appeared |
Anthropics
Anthropics claude Code |
|
| Vendors & Products |
Anthropics
Anthropics claude Code |
| Type | Values Removed | Values Added |
|---|---|---|
| Metrics |
ssvc
|
| Type | Values Removed | Values Added |
|---|---|---|
| Description | Claude Code is an agentic coding tool. Prior to version 2.0.57, Claude Code failed to properly validate directory changes when combined with write operations to protected folders. By using the cd command to navigate into sensitive directories like .claude, it was possible to bypass write protection and create or modify files without user confirmation. Reliably exploiting this required the ability to add untrusted content into a Claude Code context window. This issue has been patched in version 2.0.57. | |
| Title | Claude Code Vulnerable to Command Injection via Directory Change Bypasses Write Protection | |
| Weaknesses | CWE-20 CWE-78 |
|
| References |
| |
| Metrics |
cvssV4_0
|