# CVE-2025-59536: Anthropic Claude Code command execution before trust dialog

Source: https://junglewise.ai/threats/cve-2025-59536-anthropic-claude-code-command-execution-before-trust-dialog  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2025-10-03. Updated: 2026-09-25  
License: CC BY 4.0 with a link back

CVE-2025-59536 · Severity: medium · CVSS 4 · Published 2025-10-03

Claude Code is an AI-assisted coding tool that runs in the terminal and executes code operations on behalf of users. A bug in its startup security dialog allowed the tool to execute commands from untrusted project files before prompting the user to approve the action, potentially enabling attackers to run arbitrary code by distributing malicious projects.

Technologies: [Anthropic Claude Code](https://junglewise.ai/threats/technologies/claude-code), [@anthropic-ai/claude-code (npm)](https://junglewise.ai/threats/technologies/anthropic-ai-claude-code). Vendors: [Anthropic](https://junglewise.ai/threats/vendors/anthropic), [npm](https://junglewise.ai/threats/vendors/npm).

## Quick answers

**Is CVE-2025-59536 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2025-59536 being exploited in the wild.

**How severe is CVE-2025-59536?** Medium severity, with a CVSS score of 4, published 3 October 2025.

**Which products and versions are affected?** Anthropic Claude Code < 1.0.111; @anthropic-ai/claude-code (npm) SEMVER:introduced=0,fixed=1.0.111.

**Is there a fix for CVE-2025-59536?** Yes. @anthropic-ai/claude-code (npm): upgrade to 1.0.111 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2025-59536 attacked?** It is attacked over the network or with local access, in a software library.

**Am I affected by CVE-2025-59536?** Check whether you run Anthropic Claude Code or @anthropic-ai/claude-code (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- @anthropic-ai/claude-code (npm): upgrade to 1.0.111 or later

  ```sh
  npm install @anthropic-ai/claude-code@1.0.111
  ```


## Technical details

This vulnerability is a code injection flaw (CWE-94) in Claude Code's startup trust dialog mechanism. The root cause is improper validation of code execution timing: the application executes commands from project files before enforcing the user-confirmation trust dialog, allowing code to run without explicit user consent. The attack vector is local/network-adjacent and requires a user to start Claude Code in a directory containing malicious project files; user interaction is required (the user must launch the application in an untrusted location). An attacker can achieve arbitrary command execution with the privileges of the Claude Code process and the invoking user. The vulnerability has been patched in version 1.0.111; users with auto-update enabled received the fix automatically.

## Affected products

- Anthropic Claude Code < 1.0.111

## Identifiers

- CVE-2025-59536
- GHSA-4fgq-fpq9-mr3g

## Timeline

- 2025-10-03: disclosed: GHSA-4fgq-fpq9-mr3g advisory published

## References

- [https://github.com/anthropics/claude-code/security/advisories/GHSA-4fgq-fpq9-mr3g](https://github.com/anthropics/claude-code/security/advisories/GHSA-4fgq-fpq9-mr3g)
- [https://github.com/anthropics/claude-code](https://github.com/anthropics/claude-code)

## Related threats

- [Anthropic Claude Code time-of-check-to-time-of-use in Edit tool](https://junglewise.ai/threats/cve-2026-88968-claude-code-is-an-agentic-coding-tool-prior-to-2-1-251-the-edit)
- [Anthropic Claude Code plugin hash pin bypass in git checkout](https://junglewise.ai/threats/cve-2026-86063-claude-code-plugin-hash-pin-bypass-allows-bypass-of-hash-pinning)
- [Anthropic Claude Code managed settings bypass with stored API key](https://junglewise.ai/threats/cve-2026-103012-claude-code-selected-an-api-key-stored-by-claude-code-for)
- [Anthropic Claude Code sandbox escape via git worktree path confusion](https://junglewise.ai/threats/cve-2026-55607-anthropic-claude-code-sandbox-escape-via-git-worktree-path)
- [Anthropic Claude Code insecure temporary file in copy command](https://junglewise.ai/threats/cve-2026-46406-anthropic-claude-code-insecure-temporary-file-in-copy-command)
