Skip to main content

Cursor EUVDEUVD-2026-39537

| CVE-2026-50548 CRITICAL
Path Traversal (CWE-22)
2026-06-25 GitHub_M
9.3
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Influence agent via untrusted prompt/repo
  2. Delivery
    Set working_directory to sensitive path
  3. Exploit
    Sandbox exposes writable external path
  4. Execution
    Overwrite cursorsandbox helper
  5. Persist
    Later command runs unsandboxed
  6. Impact
    Execute arbitrary code as user

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK

2 techniques across 2 tactics: Discovery, Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires the victim to be running Cursor prior to 3.0 with agent terminal command execution in its default sandbox mode (the sandbox that grants write access to the command's working directory). The concrete prerequisite is that the agent be induced to set the working_directory parameter to a sensitive location outside the workspace - i.e., the agent must be malicious or manipulated (e.g., via injected/untrusted prompt or repository content). The vendor states no user interaction is needed beyond a benign prompt, meaning the only human action is normally invoking the agent; what limits exploitation is that an attacker must influence the agent's instructions or content, the victim must be on a pre-3.0 build with the sandbox enabled, and the impact runs under the user's existing privileges rather than escalating beyond them.

Impact

The vendor-supplied CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N, VC/VI/VA:H) yields 9.3 and models full unauthenticated network-reachable compromise with high impact - consistent with the described arbitrary file write and resulting RCE under the user's privileges. There is no CISA KEV listing and no public exploit identified at time of analysis, so this is not yet evidence of active or widespread exploitation; EPSS and SSVC data were not provided in the input. A nuance worth flagging: the vector states UI:N, yet the description says exploitation requires the user to issue a 'benign prompt' to the agent and that the agent be malicious/manipulated - so realistically a human triggers the agent run, even if unwittingly, which argues for a user-interaction or attack-requirement caveat. Net assessment: a genuinely high-priority issue for any developer running Cursor with agent mode and sandbox defaults, driven by severity and product popularity rather than confirmed in-the-wild use.

Exploit ScenarioDerived

A developer uses Cursor's agent on an attacker-influenced repository or follows an attacker-supplied prompt; the agent issues a terminal command whose working_directory is set to a sensitive path outside the workspace. The sandbox then permits writing there, and the agent overwrites the cursorsandbox helper so the next command runs unsandboxed with the user's privileges, achieving full RCE. No public exploit code is identified at time of analysis, and the network attack vector with low complexity makes the chain straightforward once the agent processes malicious instructions.

Act Now Prioritize within 24-48h. Why: CRITICAL severity + public POC available.
Patch available 0.5% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jun 25, 2026

Sandbox escape leading to non-sandboxed remote code execution affects the Cursor AI code editor prior to version 3.0, where agent terminal commands run in a sandbox that grants write access to the command's working directory. By manipulating the working_directory parameter, a malicious or prompt-injected agent can cause the sandbox to expose writable paths outside the intended workspace, then overwrite the cursorsandbox helper so subsequent commands execute outside the sandbox entirely. There is no public exploit identified at time of analysis, but the vendor rates this 9.3 (CVSS 4.0) with high confidentiality, integrity, and availability impact and notes it requires no user interaction beyond a benign prompt.

RemediationAI

Vendor-released patch: upgrade to Cursor 3.0, which fixes the working_directory path-traversal that allowed the sandbox to include writable paths outside the workspace; this is the primary and authoritative fix per the GitHub Security Advisory GHSA-3p48-7v9f-v5cw (https://github.com/cursor/cursor/security/advisories/GHSA-3p48-7v9f-v5cw). For installs that cannot immediately update, reduce exposure by disabling agent auto-run of terminal commands or requiring manual approval for each command (trade-off: significantly reduces agent automation/productivity), avoiding opening or running the agent against untrusted repositories and prompts (trade-off: limits collaboration workflows), and running Cursor under a least-privileged OS user so that any escaped write occurs with minimal filesystem reach (trade-off: may break tooling that expects broader permissions). These are mitigations only; upgrading to 3.0 is the sole confirmed remediation.

Affected VersionsENISA

cursor < 3.0

Affected Packages

euvd cursor fix: 3.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Cursor is an Electron-based code editor (cpe:2.3:a:cursor:cursor) that embeds an AI agent capable of executing terminal commands on the developer's machine. To contain those commands it uses a sandbox (the cursorsandbox helper) that, by design, grants write access to the command's working directory. The root cause is CWE-22 (Improper Limitation of a Pathname to a Restricted Directory / Path Traversal): the working_directory parameter is not properly constrained, so a manipulated value resolves to writable paths outside the intended workspace. Because the sandbox derives its writable set from this parameter, controlling it effectively widens the sandbox's write boundary and allows the protective helper binary itself to be replaced, collapsing the sandbox guarantee.

Know when Cursor gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 9.3 CRITICAL
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
vuln.today AI 9.6 CRITICAL

Network-delivered malicious agent content with low complexity and no auth (PR:N), but a user must invoke the agent (UI:R); sandbox escape to host execution is a scope change (S:C) with full C/I/A impact.

3.1 AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
High
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

1
Patch available
Jun 25, 2026 - 20:03 EUVD

DescriptionCVE.org

Cursor is a code editor built for programming with AI. Prior to 3.0, Cursor runs agent terminal commands in a sandbox by default, and the sandbox grants write access to the command's working directory. A flaw was identified in how the agent could modify the working_directory parameter, which could cause the sandbox to include writable paths outside the intended workspace. A malicious agent could set working_directory to a sensitive location and write arbitrary files outside the workspace under the user's privileges. This enables non-sandboxed Remote Code Execution - for example by overwriting the cursorsandbox helper so later commands run unsandboxed - with no user interaction beyond a benign prompt. This vulnerability is fixed in 3.0.

Executive ViewAI

Why It Matters

Cursor AI code editor versions prior to 3.0 contain a critical sandbox escape vulnerability enabling remote code execution on developer machines through prompt injection of agent commands. This allows attackers to execute arbitrary code with full access to the developer's environment, risking compromise of source code, credentials, and intellectual property.

Business Impact: Severe
Compensating Controls

No vendor-released patch identified at time of analysis. No public exploit identified at time of analysis. Interim mitigations include: disabling agent automation features if available, restricting Cursor usage to isolated development environments with limited network access, and implementing enhanced monitoring of agent terminal command execution. Organizations should prioritize upgrade to version 3.0 as permanent remediation.

Threat Intelligence Overview

EPSS Score
0.5%
Top 60% exploitable
Prevalence
High
very widely adopted AI code editor among developers
Exploit
POC
Public exploit code exists
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC Yes
EPSS 0.5%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity + public POC available
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Out-of-Cycle
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
Very High
Technical Impact
Total

Priority Score

67
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +46
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

More in Cursor

View all
CVE-2026-63093 HIGH POC
8.7 Jul 17

Arbitrary code execution in Cursor for Windows 3.2.16 lets remote attackers run code on a developer's machine by plantin

CVE-2025-59944 CRITICAL
9.8 Oct 03

Remote code execution in Cursor IDE 1.6.23 and below can be triggered by prompt injection that abuses case-insensitive p

CVE-2026-22708 CRITICAL POC
9.8 Jan 14

Cursor AI code editor before 2.3 allows prompt injection to bypass the Agent's Allowlist mode. Shell built-ins can execu

CVE-2026-50549 CRITICAL POC
9.3 Jun 25

Sandbox escape leading to non-sandboxed remote code execution in Cursor (the AI code editor) prior to version 3.0, where

CVE-2025-61592 HIGH
8.8 Oct 03

Cursor is a code editor built for programming with AI. In versions 1.7 and below, automatic loading of project-specific

CVE-2025-61593 HIGH
8.8 Oct 03

Remote code execution in Cursor CLI Agent 1.7 and earlier can be triggered by unauthenticated attackers through prompt i

CVE-2025-64108 HIGH
8.8 Nov 04

Cursor is a code editor built for programming with AI. Rated high severity (CVSS 8.8), this vulnerability is remotely ex

CVE-2025-61591 HIGH
8.8 Oct 03

Cursor is a code editor built for programming with AI. In versions 1.7 and below, when MCP uses OAuth authentication wit

CVE-2025-64106 HIGH
8.8 Nov 04

Cursor is a code editor built for programming with AI. Rated high severity (CVSS 8.8), this vulnerability is remotely ex

CVE-2025-64107 HIGH
8.8 Nov 04

Cursor is a code editor built for programming with AI. Rated high severity (CVSS 8.8), this vulnerability is remotely ex

CVE-2026-31854 HIGH POC
8.8 Mar 11

Cursor is a code editor built for programming with AI. versions up to 2.0 is affected by os command injection.

CVE-2025-64110 HIGH
8.7 Nov 05

Cursor is a code editor built for programming with AI. Rated high severity (CVSS 8.7), this vulnerability is remotely ex

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy