Claude Code has a growing stack of GitHub security advisories affecting the npm CLI, Desktop, plugins, and CI actions—not because the product is uniquely unsafe, but because it runs shell commands, writes files, and loads MCP servers on developer machines. If you searched “claude code vulnerabilities”, you probably need three answers: whether your installed build is in a vulnerable range, which semver fixes it, and what attack path the advisory actually describes.
This guide maps verified advisories in Beam’s Claude Code CVE tool page to check commands and patch habits. It is not a replacement for Anthropic’s advisory feed.
TL;DR
| Question | Answer |
|---|---|
| Am I affected? | Compare claude --version to each advisory’s vulnerable range; auto-update users are often already patched. |
| Is there a fix? | Yes for listed CVEs—bump @anthropic-ai/claude-code to the patched semver in the advisory or GitHub release tag. |
| Does data leave my machine? | Unrelated to most CVEs—but MCP and plugin bugs can exfiltrate if you enable attacker-controlled configs. |
| Where is the canonical list? | /cve/tool/claude-code and GitHub Security tab for anthropics/claude-code. |
| Does every flaw need a skill? | No—patch semver first; optional scanners catch patterns, not Anthropic code bugs. |
How to check your Claude Code build
Anthropic ships the CLI as @anthropic-ai/claude-code on npm. Start every triage with:
claude --version
npm ls -g @anthropic-ai/claude-code
If you install locally in a project:
npm ls @anthropic-ai/claude-code
Match the reported semver against the vulnerable and patched fields on each GHSA record. Beam mirrors them at /cve/<slug>—for example and .
Auto-update is the default path Anthropic cites in several advisories: if you use standard auto-update, you may already have fixes without noticing a version bump. CI pins, Docker images, and npm install -g @anthropic-ai/claude-code@<old> are where stale builds linger.
High-signal advisories coding-agent users should know
The table below is not exhaustive—the tool page lists more—but these are the issues operators ask about when they worry about agent shell access.
| ID | Severity | Mechanism (short) | Patched npm (per advisory) |
|---|---|---|---|
| High | TOCTOU in Edit tool: macOS sandbox race writes outside workspace | 2.1.251 | |
| High | Plugin hash-pin bypass via git branch named like a SHA | 2.1.179 | |
| High | git config user.email injected into startup shell command before trust dialog | 1.0.105 | |
| Medium | claude-code-action enabled attacker .mcp.json on PR heads → runner RCE | action 1.0.74 |
CVE-2026-88968: sandbox escape through Edit timing
GHSA-5xjx-9qx6-jcrv describes a time-of-check time-of-use gap: code inside the Bash sandbox can swap a workspace directory for a symlink after validation, so the unsandboxed Edit path overwrites an attacker-chosen file outside the project. The reporter is credited in the advisory; CVSS 4.0 7.7 on the record Beam syncs.
Who is affected: @anthropic-ai/claude-code < 2.1.251 on setups where the Edit tool is used on macOS (per advisory text). Fix: upgrade to 2.1.251 or later—see release v2.1.251. Deep dive: our TOCTOU write-up.
CVE-2026-86063: plugin “pinned hash” that was not
GHSA-pq7j-f95f-qfcv covers git checkout <sha> resolving to an attacker branch with a SHA-shaped name, so “pinned” marketplace plugins can install unreviewed tips. That matters when agents pull skills and plugins from git hosts you do not control. Patched at 2.1.179. See plugin hash-pin bypass post.
CVE-2025-59041: trust dialog too late for git email
GHSA-j4h9-wv2m-wrf7 shows untrusted .git/config could execute commands before the user accepts workspace trust—a reminder that opening a repo is code execution. NVIDIA AI Red Team is credited in the advisory text. Patch: 1.0.105.
CVE-2026-47751: MCP in GitHub Actions on PR heads
Although filed under claude-code-action, this path is how many teams run Claude on PRs. GHSA-8q5r-mmjf-575q chains PR head checkout, default .mcp.json loading, and enableAllProjectMcpServers to runner compromise and secret theft. Pin the action to a patched release or a commit SHA you audit—not a floating @main tag if your policy forbids it. Related: MCP security guide and malicious Agents.md hijack.
Attack patterns that repeat across advisories
Reading ten Claude Code advisories feels repetitive because the harness primitives repeat:
- Untrusted workspace data becomes shell — git config, hook JSON,
.mcp.json, plugin manifests. - Sandboxed vs unsandboxed tool split — bugs often live on the boundary (Edit, Bash, desktop preview panes).
- Supply chain via plugins and marketplaces — hash pins and marketplace commits are trust anchors; bypasses are high severity.
- CI is a different machine — Actions runners hold org secrets; MCP enablement defaults matter more than on a laptop.
None of these are fixed by prompt engineering. They are semver and config problems.
Desktop, VS Code, and npm: three surfaces, one inventory
Claude Code is not only the global npm CLI. Teams also run:
- Claude Code Desktop with preview panes and local project roots (SneakPeek exfiltration class).
- VS Code extensions pinned in
package.jsonlockfiles (compromised extension incident). - GitHub Actions workflows that invoke claude-code-action on pull requests.
Your vulnerability inventory should list each surface, the package or extension version, and who can trigger it (every engineer laptop versus privileged CI). A patched npm CLI does not automatically patch an old Action tag or a stale VSIX side-loaded on one machine.
| Surface | Version check | Advisory home |
|---|---|---|
| npm CLI | claude --version | anthropics/claude-code |
| Desktop app | in-app About / vendor updater | same repo + release notes |
| VS Code ext | Extensions panel version | marketplace release + Beam posts for supply-chain cases |
| CI action | pinned tag or SHA in workflow | anthropics/claude-code-action |
How to tell if you were affected
Most Anthropic advisories describe conditional exploitation: you need a malicious repo, a winning race, or a privileged workflow run. There is rarely a magic network beacon that proves compromise.
Practical signals after a disclosed CVE:
- Version still in range during the disclosure window—if
claude --versionshows a build below the patched column, assume exposure until you prove otherwise. - Unexpected dotfile edits near agent sessions—
~/.ssh/config, shell profiles, or files outside the repo tree on macOS when Edit was in use (). - Plugins installed from marketplaces without a matching reviewed SHA during the hash-pin bug era ().
- CI secrets rotated after running Claude on a fork PR with
.mcp.jsonchanges ().
Beam does not know your semver. It can show which commands and paths a session touched—use that timeline to narrow whether an exploit path had room to run, not to replace npm install -g @anthropic-ai/claude-code@latest.
Patch rhythm for security-conscious teams
A lightweight patch rhythm beats a quarterly scramble:
- Subscribe to GitHub advisory notifications for
anthropics/claude-codeandclaude-code-action. - Mirror severity into your ticket system when Beam’s /cve/tool/claude-code sync adds high or critical rows.
- Smoke-test one repository after bumping semver—run a read-only task, confirm hooks still fire, re-scan MCP configs (MCP server security review).
- Document minimum versions in the same doc where you store API keys policy—auditors ask for both.
Anthropic’s advisories often close with “standard auto-update users already have the fix.” Security teams should still verify auto-update on every managed Mac and Linux box; MDM images and golden AMIs are where drift hides.
What this means if you run AI coding agents
Patch first. Set a weekly reminder to run claude --version on every machine that can touch production repos, and fail CI if the semver is below your org minimum.
Treat repos like untrusted code until workspace trust and MCP configs are reviewed. Beam’s skill and MCP scanner (eleven heuristics plus version-pin checks) catches known risky shapes—curl | bash, suspicious env exfil, missing pins—but it is not a substitute for reading GHSA text.
Log evidence locally. When an advisory mentions unexpected dotfile writes or plugin installs, check whether your agent session timeline shows matching Edit or Bash events. What is AI agent monitoring? explains the event classes worth capturing.
Revisit policy after every high CVE. If you use enforce mode for Claude Code PreToolUse denies, bump the minimum version in your runbook the same day you bump npm—see workspace policy docs for observe versus enforce limits.
What Beam can and cannot do here
Beam does not patch Anthropic releases or verify every Claude Code build on your PATH. It does:
- Scan skills and MCP configs before execution (heuristic, not malware reverse-engineering).
- Record hook events and flag risky command patterns with local NDJSON storage and redaction before persistence.
- Deny some PreToolUse tool calls for Claude Code and Codex when cached workspace policy is in enforce—fail-open if policy is missing or expired.
It does not kernel-sandbox the CLI, block npm downgrades, or intercept Anthropic auto-update channels.
Claude Code vulnerabilities versus model risk
Searchers sometimes conflate harness CVEs with model misalignment or prompt injection. They are different layers:
- CVE-2026-88968-class bugs break tool sandbox assumptions on the host OS—patch semver.
- Prompt injection in a trusted doc may trick the model into proposing a bad command—mitigate with hooks, policy, and human review ().
- Frontier base-model pacing (OpenAI’s sub-0.8 perplexity bands) may change what models attempt before harnesses catch up—track vendor essays separately from GHSA rows (OpenAI perplexity pacing).
Your Claude Code vulnerability program should own semver and config; your agent monitoring program owns evidence when proposals cross policy.
Do Claude Code vulnerability scanners exist?
Vendors market “vulnerability scanners” for AI stacks; for Claude Code specifically, the authoritative source remains Anthropic’s GitHub advisories and your installed semver. Third-party scanners may grep for known bad plugin hashes or leaked keys in transcripts—they rarely prove you are patched against CVE-2026-88968-class races. Use them as supplements, not as a replacement for claude --version.
Frequently asked questions
The front-matter FAQ mirrors the questions above. Re-check /cve/tool/claude-code after each Anthropic release—Beam syncs GitHub advisories on a schedule.
Related reading
- Claude Code VS Code compromised SSH backdoor — extension supply chain, not npm CLI, but same trust model
- Claude Code “don’t ask again” settings leaking secrets — local JSON risk adjacent to CVE class
- OpenAI pretraining pacing and cyber-capability bands — why base-model jumps can outpace harness patches
- Trail of Bits regression-hunt on agent changes — auditing what your agent changed after upgrades
- Coding assistant security solutions
- CVE database for agent tools
Sources
- Anthropic claude-code — Security advisories — authoritative vulnerable and patched semver.
- CVE-2026-88968 — NVD — government mirror of GHSA-5xjx-9qx6-jcrv.
- CVE-2025-59041 — NVD — git email injection advisory context.
Advisory severities, version floors, and CVSS vectors reflect GitHub and NVD records as of November 23, 2026.

