---
id: "CVE-2026-103435"
page: "https://infrastack.ai/live/CVE-2026-103435"
kind: "vulnerability"
aliases: ["CVE-2026-103435", "GHSA-5j29-h97v-84ch"]
title: "Arbitrary File Write via Write-Time Symlink Following (TOCTOU) in Claude Code"
severity: "high"
cvss: 7.7
epss: null
exploited: false
status: "open"
category: "ai-tooling"
products: [{"name": "@anthropic-ai/claude-code", "fixed": ["2.1.129"], "affected": "< 2.1.129", "ecosystem": "npm"}]
ecosystems: ["npm"]
tags: ["ai-tooling", "claude-code", "cwe-22", "cwe-367", "cwe-61", "linux", "macos", "npm", "shared-workspace", "windows"]
not_affected_if: ["auto-update", "single-user-workspace", "version-2.1.129-or-later"]
published_at: "2026-10-05T12:45:33+00:00"
first_seen_at: "2026-11-09T22:53:24+00:00"
updated_at: "2026-11-09T22:59:17+00:00"
sources: [{"source": "ghsa-repo", "url": "https://github.com/anthropics/claude-code/security/advisories/GHSA-5j29-h97v-84ch", "first_seen_at": "2026-11-09T22:53:24+00:00"}, {"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-103435", "first_seen_at": "2026-11-09T23:10:12+00:00"}]
exploit_sources: []
---

# Arbitrary File Write via Write-Time Symlink Following (TOCTOU) in Claude Code

Link for people: https://infrastack.ai/live/CVE-2026-103435 (this .md is for agents)

Claude Code checked that a file path stayed inside the project folder, then resolved the path again at write time without rechecking. An attacker with write access to the shared workspace can swap a project file for a symlink and redirect Claude Code's writes to files outside the project, such as shell configuration files.

_Summary, check and fix written by a model from the sources; labelled as such._

## Affected

- npm:@anthropic-ai/claude-code affected < 2.1.129 fixed 2.1.129

## How to check

- Check the installed version with `claude --version`; versions below `2.1.129` are affected.
- Check the npm package with `npm ls @anthropic-ai/claude-code`.

## Fix

- `@anthropic-ai/claude-code` `2.1.129`
- Update to the latest version, per the advisory.

## Timeline

- 2026-11-09T22:53:24+00:00 ghsa-repo https://github.com/anthropics/claude-code/security/advisories/GHSA-5j29-h97v-84ch
- 2026-11-09T23:10:12+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-103435

## Documents

- [advisory] Maintainer's advisory: github.com https://github.com/anthropics/claude-code/security/advisories/GHSA-5j29-h97v-84ch

## From the sources

Claude Code validated that a target file path resided within the project working directory at permission-check time, but re-resolved the path at write time without repeating that validation. This time-of-check to time-of-use (TOCTOU) gap allowed an attacker who could write to the workspace to atomically replace a project file with a symlink, causing Claude Code to follow the symlink and write its output to an arbitrary file outside the project sandbox. Exploitation required the ability to win a race condition against the write operation and write access to the shared workspace, enabling a lower-privileged attacker to redirect benign edits to sensitive files (e.g., shell configuration) in a higher-privileged session.

Users on standard Claude Code auto-update have received this fix already. Users performing manual updates are advised to update to the latest version.

Thank you to hackerone.com/c_h4ck_0 for reporting this issue.

---

_Free to read, with fair use of about 60 pages a minute. For higher limits or API access: sales@infrastack.ai_
