Skip to main content

Visual Studio Code CVE-2026-40376

| EUVDEUVD-2026-35536 HIGH
Improper Input Validation (CWE-20)
2026-06-09 secure@microsoft.com GHSA-rg3p-gp39-622w
8.1
CVSS 3.1 · NVD
Temporal: 6.5
View

Attack ChainAIDerived

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

  1. Access
    Identify VS Code instance with network listener exposed
  2. Delivery
    Send crafted input to vulnerable endpoint
  3. Exploit
    Bypass authentication via input validation flaw
  4. Execution
    Trigger privileged handler with attacker payload
  5. Persist
    Execute actions in developer user context
  6. Impact
    Exfiltrate source, credentials, or pivot internally

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V2 - Validation and Business Logic Input validation, allowlisting
Exploitation Conditions

The VS Code instance must be reachable over a network channel that the editor processes before authentication - most plausibly a Remote/Server/Tunnel listener, Live Share session, or debug adapter port - since the CVSS vector is AV:N/PR:N/UI:N and the tag 'Authentication Bypass' indicates the flaw sits in pre-auth input handling. Exploitation is limited by AC:H, meaning the attacker needs conditions outside their control to align (likely a specific VS Code feature enabled such as Remote Tunnels or Live Share, a particular workspace state, or a race/timing window), and is constrained to versions 1.0.0 through 1.119.0; instances on 1.119.1 or later, or with all network-exposed collaboration features disabled, are not exploitable. The MSRC advisory should be consulted to confirm exactly which subsystem accepts the malformed input, as that detail is not in the public NVD description.

Impact

The signals here are genuinely mixed and warrant a nuanced priority. The CVSS 3.1 score of 8.1 (AV:N/AC:H/PR:N/UI:N) describes a remote, unauthenticated, no-user-interaction path with full CIA impact, and SSVC confirms 'total' technical impact, which on paper makes this high severity. However, the CVSS attack complexity is High (meaning specialised conditions outside attacker control must align), SSVC marks the issue as not automatable with exploitation status 'none', EPSS is only 0.09% (26th percentile), and there is no CISA KEV listing or public POC. The 'AV:N/UI:N' rating is unusual for a desktop editor and conflicts with how VS Code is typically reached - verify with Microsoft's MSRC advisory whether the network vector requires the user to open a specific workspace, connect to a Remote/Tunnel endpoint, or expose a Live Share/debug session, because that distinction sharply changes real-world exposure. Treat as a meaningful patch priority for fleets of developer workstations (especially those using Remote Tunnels or Live Share) but not a drop-everything incident absent in-the-wild activity.

Exploit ScenarioDerived

An attacker hosts a malicious endpoint - for example a crafted Remote Tunnel, Live Share session, or rogue extension-update service - and entices a developer's VS Code client to contact it, sending malformed protocol input that bypasses the editor's authentication check and is processed by a privileged handler. The handler executes attacker-controlled actions in the developer's user context (file write, command execution, or credential exfiltration from the editor's secret storage), giving the attacker the same access level as the developer including SSH keys and source repositories. No public exploit identified at time of analysis, and the High attack complexity means the attacker must align specific timing or configuration conditions for the bypass to succeed.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.1% exploitation probability (EPSS)

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

Alert me

AnalysisAIv3 – Jun 11, 2026

Privilege escalation in Microsoft Visual Studio Code versions 1.0.0 through 1.119.0 allows remote unauthenticated attackers to elevate privileges over a network by exploiting improper input validation (CWE-20). Microsoft has released a patched build (1.119.1) and SSVC rates technical impact as total, though EPSS remains low at 0.09% with no public exploit identified at time of analysis.

Earlier versions of this analysis (2)
v2 Jun 11, 2026 - 19:12 cvss changed CVSS 8.1

Network-based privilege elevation in Microsoft Visual Studio Code versions 1.0.0 through 1.119.0 allows remote attackers to gain elevated privileges by exploiting improper input validation (CWE-20). Microsoft has released a fix in version 1.119.1, and while no public exploit identified at time of analysis, the SSVC technical impact is rated as total, meaning successful exploitation grants full control over the affected component. EPSS probability is low at 0.09%, indicating exploitation in the wild is currently unlikely despite the high CVSS score of 8.1.

v1 Jun 09, 2026 - 17:33 CVSS 7.5

Privilege elevation in Microsoft Visual Studio Code allows remote attackers to gain elevated privileges over a network by exploiting an improper input validation flaw (CWE-20). Exploitation requires user interaction and has high attack complexity, but successful attacks yield high confidentiality, integrity, and availability impact. No public exploit identified at time of analysis, and the issue is not currently listed in CISA KEV.

RemediationAI

Vendor-released patch: Visual Studio Code 1.119.1 - upgrade all instances to 1.119.1 or later via the in-app auto-updater, MSI/DEB/RPM packages, or your endpoint management tool, using the Microsoft advisory at https://msrc.microsoft.com/update-guide/vulnerability/CVE-2026-40376 as the authoritative reference. No vendor-supplied workaround is published; compensating controls until rollout completes include disabling Remote Tunnels (settings 'remote.tunnels.access') and Live Share on managed workstations to remove the externally reachable surface (trade-off: blocks remote pair programming and cloud-hosted dev workflows), restricting outbound connections from VS Code processes to known Microsoft endpoints via host firewall (may break marketplace updates if over-restricted), and requiring users to only open trusted workspaces under Workspace Trust (already default, but verify policy enforcement). Cross-reference VulDB entry https://vuldb.com/vuln/369591 for additional triage data.

Affected VersionsENISA

Visual Studio Code 1.0.0 <1.119.1

Affected Packages

euvd visual_studio_code fix: 1.119.1

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

Visual Studio Code is Microsoft's cross-platform source-code editor built on the Electron framework, which combines Chromium and Node.js to execute web technologies with local OS privileges. The root cause is CWE-20 (Improper Input Validation), meaning the editor accepts data from a network-reachable surface without enforcing expected syntactic, semantic, or length constraints before passing it to a privileged operation. The single CPE microsoft:visual_studio_code:* confirms the desktop editor itself is in scope rather than a specific extension, and the 'Authentication Bypass' tag indicates the malformed input is processed before any identity check is enforced, allowing the attacker's input to reach privileged code paths intended for authenticated users.

Know when Visual Studio Code 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

NVD PRIMARY 8.1 HIGH
AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
ENISA EUVD HIGH
CIRCL (temporal) 6.5 MEDIUM
vuln.today AI 8.1 HIGH

Pre-auth network input handler (AV:N/PR:N/UI:N) with specialised timing/config prerequisites (AC:H) yielding full code-execution-class impact in the user's context (C:H/I:H/A:H, S:U).

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

Primary rating from NVD.

CVSS VectorNVD

Attack Vector
Network
Attack Complexity
High
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Lifecycle Timeline

4
Analysis Updated
Jun 11, 2026 - 19:13 vuln.today
v3 - CVSS changed
Analysis Updated
Jun 11, 2026 - 19:12 vuln.today
v2 - CVSS changed
CVSS changed
Jun 11, 2026 - 19:07 NVD
7.5 (HIGH) 8.1 (HIGH)
Patch available
Jun 09, 2026 - 19:03 EUVD

DescriptionNVD

Improper input validation in Visual Studio Code allows an unauthorized attacker to elevate privileges over a network.

Executive ViewAI

Why It Matters

Microsoft Visual Studio Code versions prior to 1.119.1 contain a privilege escalation vulnerability enabling remote attackers to gain full system access on developer workstations. This directly exposes organizations' source code, intellectual property, and build infrastructure to compromise. Developer machines represent high-value targets for supply chain attacks, making urgent patching essential.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.1%
Top 74% exploitable
Threat Intel
1
1 sources
Vendor Action
See Below
Required. The vulnerability documented by this CVE requires customer action to resolve.
Vendor Status
Publicly Disclosed:No
Exploited:No
Latest Software Release:Exploitation Less Likely
Data Quality
7 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 HIGH
CISA KEV No
Public POC No
EPSS 0.1%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
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
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact
High
Technical Impact
Total

Priority Score

45
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +40
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: +5

Attack Technique

Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.

CVE-2022-41034 HIGH POC
7.8 Oct 11

Visual Studio Code Remote Code Execution Vulnerability. Rated high severity (CVSS 7.8), this vulnerability is no authent

CVE-2022-30129 HIGH POC
8.8 May 10

Visual Studio Code Remote Code Execution Vulnerability. Rated high severity (CVSS 8.8), this vulnerability is remotely e

CVE-2026-81376 CRITICAL
9.6 Sep 08

Security-feature bypass in Microsoft Visual Studio Code before 1.136.2 lets a remote, unauthenticated attacker defeat a

CVE-2026-102238 CRITICAL
9.6 Oct 13

Remote code execution in Visual Studio Code (versions 1.0.0 up to but not including 1.141.1) is achievable through a pat

CVE-2026-47281 CRITICAL
9.6 Jun 09

Privilege escalation in Microsoft Visual Studio Code allows remote unauthenticated attackers to elevate privileges over

CVE-2021-43891 HIGH
7.8 Dec 15

Visual Studio Code Remote Code Execution Vulnerability. Rated high severity (CVSS 7.8), this vulnerability is no authent

CVE-2026-121663 HIGH
8.8 Nov 10

Security feature bypass in Visual Studio Code before 1.145.3 allows an unauthenticated remote attacker to evade a securi

CVE-2026-119975 HIGH
8.8 Nov 10

Cross-site scripting in Visual Studio Code before 1.145.3 can let unauthenticated, network-reachable attackers run attac

CVE-2026-57102 HIGH
8.8 Jul 14

Security-feature bypass in Microsoft Visual Studio Code lets a remote attacker deliver functionality from an untrusted c

CVE-2026-59113 HIGH
8.8 Aug 11

Remote code execution in Visual Studio Code (versions 1.0.0 through 1.132.0) is enabled by a missing authorization check

CVE-2026-69370 HIGH
8.8 Oct 13

Command injection in Visual Studio Code 1.0.0 through 1.141.0 allows an unauthenticated remote attacker to execute arbit

CVE-2026-70336 HIGH
8.8 Aug 11

Remote code execution in Microsoft Visual Studio Code allows a network-based attacker to inject and execute arbitrary co

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