CVE 7.7 HIGH

Claude Code Has Sandbox Escape via Persistent Configuration Injection in settings.json_CVE-2026-25725

7.7 / 10
HIGH
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

Description

Claude Code is an agentic coding tool. Prior to version 2.1.2, Claude Code's bubblewrap sandboxing mechanism failed to properly protect the .claude/settings.json configuration file when it did not exist at startup. While the parent directory was mounted as writable and .claude/settings.local.json was explicitly protected with read-only constraints, settings.json was not protected if it was missing. This allowed malicious code running inside the sandbox to create this file and inject persistent hooks (such as SessionStart commands) that would execute with host privileges when Claude Code was restarted. This issue has been patched in version 2.1.2.

Basic Information

ID CVE-2026-25725
Source GitHub_M
Published Feb 6, 2026 at 17:53
Modified Feb 6, 2026 at 19:15

Affected Product

Vendor anthropics
Product claude-code
Version < 2.1.2
Affected Versions anthropics claude-code < 2.1.2

CWE Classification

References

💭 Join the Security Discussion

🔒 Your email address will not be published. Required fields are marked *

⚠️ Please be respectful and constructive in your comments. Security discussions should remain professional.