Skip to main content

Markdown Preview Enhanced CVE-2026-54566

| EUVDEUVD-2026-101582 HIGH
Code Injection (CWE-94)
2026-10-14 security-advisories@github.com
8.5
CVSS 4.0 · Vendor: github
View

Attack ChainAIDerived

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

  1. Access
    Victim clones/opens malicious repository
  2. Delivery
    Open Markdown file loads .crossnote config/parser
  3. Exploit
    vm.runInNewContext evaluates untrusted JS
  4. Execution
    Prototype traversal reaches Function/process
  5. Impact
    Execute OS commands as victim account

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Code injection prevention, sandbox exec
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Initial Access

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 open a Markdown file inside an attacker-controlled repository that contains malicious .crossnote/config.js and/or .crossnote/parser.js files, with the Markdown Preview Enhanced extension (prior to 0.8.29 / crossnote prior to 0.9.30) installed in VS Code. The config and parser-hook files are loaded automatically on file open - no further user action, and no module-scoped require, is needed. Limiting factors: the attacker must get their repository onto the victim's machine and the victim must open a Markdown file from it (UI:P / local vector), so this is not remotely triggerable against a default install without that interaction. Default extension behavior auto-evaluates these workspace files, so no special non-default configuration is required on the victim side.

Impact

This is a genuine high-priority issue for developer environments, though it is not a mass-exploitable network flaw. The vendor-assigned CVSS 4.0 vector (AV:L/AC:L/AT:N/PR:N/UI:P, VC:H/VI:H/VA:H, score 8.5) is internally consistent with the description: exploitation is local in the CVSS sense (it requires a malicious repository to be present and a Markdown file within it to be opened), requires no privileges or prior authentication, but does require passive user interaction (UI:P). The technical impact is maximal - full arbitrary OS command execution as the victim account via prototype-chain traversal from the vm.runInNewContext sandbox to the host Function constructor and process object - which the C/I/A:H ratings correctly reflect. No EPSS score was provided and the vulnerability is NOT on CISA KEV, and no public exploit was supplied in the intelligence, so there is no evidence of active or widespread exploitation; the root-cause and fix are well documented in the GitHub Security Advisory (GHSA-427h-jhpr-8jch) and the patch commits. The realistic risk is targeted social-engineering (luring a developer into cloning/opening a malicious repo), not opportunistic internet-wide attack. SC/SI/SA:N indicate no modeled impact beyond the victim's own account, but in practice code execution as a developer is a serious foothold. Net: treat as a priority patch for anyone using this extension, while recognizing it depends on attacker-supplied repository content plus the victim opening a file.

Exploit ScenarioDerived

An attacker publishes a malicious repository (e.g., a tempting sample project, fork, or template) containing crafted .crossnote/config.js or .crossnote/parser.js files. When a developer clones it and opens any Markdown file with the Markdown Preview Enhanced extension, those files are automatically evaluated via vm.runInNewContext, and prototype-chain traversal reaches the host Function constructor and process object to run OS commands as the victim. No public exploit was provided in the intelligence, but the GitHub advisory and commit history describe the mechanism precisely, making weaponization straightforward.

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

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

Alert me

AnalysisAIv1 – Oct 14, 2026

Remote code execution in Markdown Preview Enhanced (a Visual Studio Code Markdown preview extension) before 0.8.29 lets a malicious repository run operating-system commands as the victim's account the moment the victim opens a Markdown file from that repository. The extension automatically evaluates repository-controlled .crossnote/config.js and .crossnote/parser.js files through vm.runInNewContext, and prototype-chain traversal escapes the Node.js host realm to reach the Function constructor and the process object - no further interaction and no module-scoped require are needed, and both the configuration-evaluation and parser-hook paths are affected. The vector requires local placement of the repository plus user interaction (opening the file), so it is not mass-exploitable over the network against a default install; there is no CISA KEV listing and no public exploit identified at time of analysis. The issue is fixed in Markdown Preview Enhanced 0.8.29, which bundles crossnote 0.9.30.

RemediationAI

Vendor-released patch: upgrade Markdown Preview Enhanced to 0.8.29 or later, which bundles crossnote 0.9.30 and evaluates .crossnote/config.js and .crossnote/parser.js inside a QuickJS WebAssembly sandbox instead of the Node.js vm realm (see https://github.com/shd101wyy/vscode-markdown-preview-enhanced/releases/tag/0.8.29 and https://github.com/shd101wyy/crossnote/releases/tag/0.9.30). If immediate upgrade is not possible, the most effective compensating control is to keep untrusted repositories in VS Code Restricted Mode (Workspace Trust) and decline trust prompts for externally sourced repos, and to inspect or remove any .crossnote/ directory before opening a Markdown file from a cloned repository - the trade-off is that Restricted Mode disables the extension's active features (preview rendering, @import/wikilink resolution, custom parser hooks), so developers lose functionality in those workspaces. Blocking the .crossnote paths via file-system or SCM policy prevents the auto-loaded payload but does not stop a hand-crafted repo from being opened outside those controls. Disabling or uninstalling the Markdown Preview Enhanced extension eliminates the exposure entirely at the cost of losing Markdown preview functionality. Because this is a local, interaction-gated vector rather than a remotely exploitable service flaw, patching the extension is the cleanest path and no network-level mitigation is required.

Affected VersionsENISA

vscode-markdown-preview-enhanced < 0.8.29

Affected Packages

euvd vscode_markdown_preview_enhanced fix: 0.8.29

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

The root cause is CWE-94 (Improper Control of Generation of Code / Code Injection). Markdown Preview Enhanced delegates rendering to the crossnote library, which evaluated the workspace files .crossnote/config.js and .crossnote/parser.js using Node.js's vm.runInNewContext. Node.js explicitly documents the vm module as not being a security mechanism - it isolates scope but shares the same host realm, so objects reachable from the sandboxed script still carry references into host prototypes. The attacker's script performed prototype-chain traversal (e.g., walking constructor chains from a reachable object) to obtain the host Function constructor, and from there reached the process object, enabling arbitrary command execution in the extension host process. Because the escape works from the global object graph rather than through module scope, the absence of module-scoped require inside the vm context provided no protection. The fix replaces the vm/sval evaluation with a QuickJS WebAssembly sandbox (quickjs-emscripten-core 0.32.0 and @jitl/quickjs-singlefile-cjs-release-sync), a genuinely separate JavaScript engine whose objects cannot reference Node.js host prototypes, and drops the previous sval/acorn-based evaluator. The affected component is the crossnote engine (versions prior to 0.9.30) shipped inside the VS Code extension (versions prior to 0.8.29); no CPE strings were provided in the source data.

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 (github) PRIMARY 8.5 HIGH
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
vuln.today AI 7.8 HIGH

Requires a local malicious repository and the victim opening a Markdown file (AV:L, UI:R), no privileges (PR:N); sandbox escape yields full OS command execution so C/I/A:H, no scope change.

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:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (github).

CVSS VectorVendor: github

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Passive
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

2
Patch available
Oct 14, 2026 - 20:34 EUVD
CVE Published
Oct 14, 2026 - 20:17 cve.org
HIGH 8.5

DescriptionCVE.org

Markdown Preview Enhanced is a Markdown preview extension for Visual Studio Code. Prior to 0.8.29, Markdown Preview Enhanced evaluates repository-controlled .crossnote/config.js and .crossnote/parser.js files with vm.runInNewContext, which does not provide a security boundary from the Node.js host realm. Opening a Markdown file in a malicious repository automatically loads these files, and prototype-chain traversal can reach the host Function constructor and process object, allowing operating-system commands to execute as the victim account without further interaction. Both configuration evaluation and parser-hook evaluation are affected, and the attack does not depend on module-scoped require being available. This issue is fixed in version 0.8.29.

Technical POC Analysis

CWE-94 (Improper Control of Generation of Code / Code Injection).

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

Markdown Preview Enhanced, a widely used Visual Studio Code extension, contains a high-severity remote code execution flaw (CVSS 8.5) that lets a malicious repository execute operating-system commands as the developer's own account the moment a Markdown file from that repository is opened. Any developer, contractor, or build workstation running an affected version and opening untrusted third-party code - routine during dependency review, vendor audits, and open-source contribution - is exposed to full user-level compromise. Leadership should care because a single ordinary file-open can lead to credential and token theft, source code exfiltration, and lateral movement from developer endpoints that typically carry privileged access to production systems.

Business Impact: Medium
Compensating Controls

Apply vendor patch: upgrade to Markdown Preview Enhanced 0.8.29 (bundles crossnote 0.9.30). Where upgrade cannot be completed immediately, disable the extension on exposed hosts, enable VS Code Workspace Trust / Restricted Mode so untrusted repositories cannot trigger extension evaluation of repository-controlled .crossnote files, and block the opening of Markdown files from untrusted or unverified repositories until remediation is complete.

Threat Intelligence Overview

EPSS Score
0.3%
Top 79% exploitable
Prevalence
High
very widely installed VS Code Markdown extension among developers
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 HIGH
CISA KEV No
Public POC No
EPSS 0.3%
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
Defer
Exploitation
Poc
System Exposure· derived
Small
Automatable
No
Human Impact
Medium
Technical Impact
Total

Priority Score

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

Attack Technique

Code Injection CRITICAL

Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.

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

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-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

CVE-2026-102235 HIGH
8.8 Oct 13

Remote code execution in Visual Studio Code versions 1.0.0 through 1.141.1 allows an unauthenticated, network-positioned

CVE-2026-78462 HIGH
8.8 Sep 08

Authorization bypass in Visual Studio Code versions 1.0.0 through 1.136.1 allows an unauthenticated network attacker to

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