{"id":"CVE-2026-25722","state":"PUBLISHED","title":"Claude Code Vulnerable to Command Injection via Directory Change Bypasses Write Protection","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.","publishedAt":"2026-02-06T17:52:42.069Z","updatedAt":"2026-02-06T18:42:01.040Z","severity":{"score":7.7,"label":"High","version":"4.0","vector":"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","source":"GitHub_M"},"assigner":"GitHub_M","products":["anthropics claude-code"],"affected":[{"vendor":"anthropics","product":"claude-code","versions":[{"version":"< 2.0.57","status":"affected"}]}],"references":["https://github.com/anthropics/claude-code/security/advisories/GHSA-66q4-vfjg-2qhh"],"weaknesses":["CWE-20","CWE-78"],"ingestedAt":"2026-10-29T20:11:21.040Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/25xxx/CVE-2026-25722.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-25722","state":"PUBLISHED","datePublished":"2026-02-06T17:52:42.069Z","dateUpdated":"2026-02-06T18:42:01.040Z","assignerShortName":"GitHub_M","assignerOrgId":"a0819718-46f1-4df5-94e2-005712e83aaa","dateReserved":"2026-02-05T16:48:00.425Z"},"containers":{"cna":{"title":"Claude Code Vulnerable to Command Injection via Directory Change Bypasses Write Protection","descriptions":[{"lang":"en","value":"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."}],"affected":[{"vendor":"anthropics","product":"claude-code","versions":[{"version":"< 2.0.57","status":"affected"}]}],"references":[{"url":"https://github.com/anthropics/claude-code/security/advisories/GHSA-66q4-vfjg-2qhh","name":"https://github.com/anthropics/claude-code/security/advisories/GHSA-66q4-vfjg-2qhh","tags":["x_refsource_CONFIRM"]}],"metrics":[{"cvssV4_0":{"attackVector":"NETWORK","attackComplexity":"LOW","attackRequirements":"PRESENT","privilegesRequired":"NONE","userInteraction":"PASSIVE","vulnConfidentialityImpact":"HIGH","vulnIntegrityImpact":"HIGH","vulnAvailabilityImpact":"HIGH","subConfidentialityImpact":"NONE","subIntegrityImpact":"NONE","subAvailabilityImpact":"NONE","baseScore":7.7,"baseSeverity":"HIGH","vectorString":"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","version":"4.0"}}],"problemTypes":[{"descriptions":[{"cweId":"CWE-20","lang":"en","description":"CWE-20: Improper Input Validation","type":"CWE"}]},{"descriptions":[{"cweId":"CWE-78","lang":"en","description":"CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')","type":"CWE"}]}],"providerMetadata":{"shortName":"GitHub_M","orgId":"a0819718-46f1-4df5-94e2-005712e83aaa","dateUpdated":"2026-02-06T17:52:42.069Z"},"source":{"advisory":"GHSA-66q4-vfjg-2qhh","discovery":"UNKNOWN"}},"adp":[{"title":"CISA ADP Vulnrichment","metrics":[{"other":{"type":"ssvc","content":{"timestamp":"2026-02-06T18:41:50.485891Z","id":"CVE-2026-25722","options":[{"Exploitation":"none"},{"Automatable":"no"},{"Technical Impact":"total"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2026-02-06T18:42:01.040Z"}}]}}}