Skip to main content

Visual Studio Code CVE-2026-70335

| EUVDEUVD-2026-56588 HIGH
OS Command Injection (CWE-78)
2026-08-11 secure@microsoft.com GHSA-hj52-q5wj-vpwg
7.8
CVSS 3.1 · Vendor: microsoft
View

Attack ChainAIDerived

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

  1. Access
    Deliver malicious repository or workspace file
  2. Delivery
    Victim opens content in VS Code with Copilot active
  3. Exploit
    Attacker-controlled string reaches OS command execution
  4. Execution
    Shell metacharacters interpreted by subprocess
  5. Persist
    Injected command executes
  6. Impact
    Attacker privileges escalate on local system

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization OS command sanitization, avoid shell exec
MITRE ATT&CK

2 techniques across 1 tactic: Execution

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

Exploitation Conditions

The attack requires the ability to deliver a malicious file, repository, or workspace to a system where GitHub Copilot or Visual Studio Code is installed, and the victim must open that content (satisfying UI:R). The attacker requires no pre-existing privileges on the target system (PR:N per CVSS vector), making this a true privilege escalation from zero. The local attack vector (AV:L) prevents direct network exploitation without a prior delivery step such as phishing, supply chain compromise, or physical access. Exploitation is limited to machines running at least one of the two affected products. Specific internal configuration options, feature flags, or deployment modes that may further restrict or expand the vulnerable code path are not documented in the available intelligence and must be confirmed against the MSRC advisory.

Impact

The CVSS 3.1 vector AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H scores 7.8 High. The local attack vector (AV:L) is the primary constraint, preventing direct network exploitation and requiring the attacker to deliver malicious content to the victim's local environment through means such as a crafted repository, file, or social engineering lure. The low attack complexity (AC:L) and absence of required prior privileges (PR:N) indicate that once delivery is achieved, exploitation is straightforward and does not depend on a race condition or special system state. User interaction (UI:R) is required - the victim must open or interact with the malicious content. No EPSS score was provided, so exploitation probability cannot be quantified from the available data. The absence of a CISA KEV listing and the lack of any identified public proof-of-concept suggest this has not been broadly exploited in the wild, though targeted use cannot be excluded. Real-world risk is concentrated in developer workstations, particularly those processing untrusted repositories or third-party code with Copilot active.

Exploit ScenarioDerived

An attacker crafts a malicious repository or workspace file embedding OS shell metacharacters in locations processed by GitHub Copilot or Visual Studio Code - such as a task definition, launch configuration, or content fed to the Copilot extension for analysis. When a developer opens the repository in VS Code with Copilot active, the injected payload reaches an OS command execution path without proper sanitization, escalating the attacker's code to run with the privileges of the VS Code or system process. No public proof-of-concept has been identified at time of analysis.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
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 – Aug 11, 2026

OS command injection in GitHub Copilot and Visual Studio Code enables a local unauthorized attacker to escalate privileges on the affected developer workstation, achieving full High impact across confidentiality, integrity, and availability. The CWE-78 root cause indicates that attacker-influenced input containing shell metacharacters is improperly incorporated into OS-level command execution within one or both products, triggering upon a user action such as opening a malicious file or repository. No public exploit code has been identified and this vulnerability has not been confirmed actively exploited by CISA KEV at time of analysis; however, the local privilege escalation path on widely deployed developer tooling represents a meaningful risk in supply chain and social engineering scenarios.

RemediationAI

Consult the Microsoft Security Response Center advisory at https://msrc.microsoft.com/update-guide/vulnerability/CVE-2026-70335 for officially confirmed patched versions of Visual Studio Code and the GitHub Copilot extension; specific fix version numbers were not present in the available intelligence data and should not be inferred. As an interim compensating control, apply VS Code workspace trust settings to restrict automatic execution of tasks, terminal profiles, and extension features when opening untrusted folders or repositories - this directly targets the UI:R delivery vector by requiring explicit user approval before potentially dangerous workspace actions execute. Additionally, avoid opening files or workspaces from unknown or untrusted sources, particularly those shared externally. Note that workspace trust alone does not patch the underlying command injection flaw and should be treated as a stopgap until vendor-released updates are applied.

Affected VersionsENISA

Visual Studio Code 1.0.0 <1.132.1

Affected Packages

euvd visual_studio_code fix: 1.132.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

CWE-78 (Improper Neutralization of Special Elements used in an OS Command) describes vulnerabilities where attacker-controlled strings - containing characters such as semicolons, pipes, backticks, or newlines - are concatenated into OS shell commands without adequate sanitization or quoting. In the context of GitHub Copilot and Visual Studio Code, the injection surface likely resides in how one or both products process repository content, file paths, workspace configuration, extension inputs, or AI-analyzed code snippets that are subsequently passed to a subprocess or shell API. The CVSS local attack vector (AV:L) and user interaction requirement (UI:R) are consistent with a delivery path involving malicious workspace or file content processed during normal developer activity. No CPE strings were provided in the available intelligence, so exact affected product versions and build numbers must be derived directly from the MSRC advisory.

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

Vendor (microsoft) PRIMARY 7.8 HIGH
AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
ENISA EUVD HIGH
vuln.today AI 7.8 HIGH

Local vector and UI:R confirmed by description; PR:N reflects no prior privileges needed; full C/I/A High consistent with privilege escalation to arbitrary command execution.

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

Primary rating from Vendor (microsoft).

CVSS VectorVendor: microsoft

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

Lifecycle Timeline

2
Patch available
Aug 11, 2026 - 18:19 EUVD
CVE Published
Aug 11, 2026 - 17:19 nvd
HIGH 7.8

DescriptionCVE.org

Improper neutralization of special elements used in an os command ('os command injection') in GitHub Copilot and Visual Studio Code allows an unauthorized attacker to elevate privileges locally.

Executive ViewAI

Why It Matters

GitHub Copilot and Visual Studio Code contain a privilege escalation vulnerability that could allow attackers to seize full control of developer workstations after users interact with crafted malicious files or repositories. A compromised development machine becomes a direct attack vector into the organization's source code and software supply chain, potentially enabling injection of malicious code into products and dependencies. Immediate mitigation is required to protect development infrastructure and software integrity.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: disable Copilot in VS Code organizational settings to eliminate attack surface; restrict file cloning and pull operations from untrusted repositories using network or endpoint controls; implement mandatory code review and SAST scanning before merge to repository; isolate developer machines from production systems and sensitive credential stores using network segmentation; monitor process execution logs for unusual command-line arguments spawned by VS Code or node.js processes; consider containerized or sandboxed development environments to prevent local privilege escalation impact to the host system.

Threat Intelligence Overview

EPSS Score
0.5%
Top 61% exploitable
Prevalence
High
VS Code is among the most widely deployed IDEs globally
Threat Intel
1
1 sources
Vendor Status
Publicly Disclosed:No
Exploited:No
Latest Software Release:Exploitation More 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.5%
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
Small
Automatable
No
Human Impact
High
Technical Impact
Total

Priority Score

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

Attack Technique

OS command injection occurs when an application passes unsanitized user input directly into system shell commands.

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