Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessCraft markdown with malicious bitfield block
-
DeliveryDeliver via repo, PR, or attachment
-
ExploitVictim opens preview or exports document
-
ExecutioninterpretJS calls vm.runInNewContext
-
PersistArbitrary JS executes in extension host
-
ImpactSteal source/credentials or pivot
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 have Markdown Preview Enhanced (vscode-markdown-preview-enhanced) at a version below 0.8.28 installed and to actively render or export a markdown document supplied by the attacker - the CVSS UI:A flag corresponds to the victim invoking the 'Open Preview' command or one of the HTML/PDF/Presentation export paths. The malicious document must contain a Bitfield fenced code block ( |
| Impact | The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:A, VC/VI/VA:H, SC/SI/SA:N) describes a network-reachable, low-complexity, unauthenticated bug with full confidentiality, integrity, and availability impact on the vulnerable component, but it explicitly requires Active user interaction - a victim must open or export a malicious markdown document. There is no EPSS score provided and the CVE is not in CISA KEV, so this is not confirmed actively exploited; no public exploit identified at time of analysis. Realistic risk is high for developer and documentation workflows because Markdown Preview Enhanced is widely installed, markdown files routinely travel through repos, issue trackers, and shared drives, and the exploit primitive (RCE on render) requires no privileges and no exotic configuration. Net assessment: prioritize patching for any environment where developers preview or export untrusted markdown, but the UI:A requirement and absence of KEV/EPSS evidence put it below true wormable RCEs. |
| Exploit ScenarioDerived | An attacker commits a README.md or design-doc markdown file containing a malicious |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jun 05, 2026
Arbitrary code execution in Markdown Preview Enhanced (shd101wyy) before 0.8.28 lets a crafted markdown document run attacker-controlled JavaScript when rendered or exported, because Bitfield fenced code blocks were evaluated through interpretJS() / vm.runInNewContext() instead of being parsed as data. CVSS 4.0 scores this 8.6 with network vector and active user interaction; no public exploit identified at time of analysis and the CVE is not listed in CISA KEV.
RemediationAI
Vendor-released patch: upgrade Markdown Preview Enhanced to 0.8.28 or later (which pulls in crossnote 0.9.29), per the release at https://github.com/shd101wyy/vscode-markdown-preview-enhanced/releases/tag/0.8.28 and the VulnCheck advisory at https://www.vulncheck.com/advisories/markdown-preview-enhanced-arbitrary-code-execution-via-bitfield-interpretjs. Until the upgrade is rolled out, compensating controls include disabling or uninstalling the Markdown Preview Enhanced extension on machines that handle untrusted markdown (trade-off: loss of diagram/preview functionality), avoiding the 'open preview' and HTML/PDF export commands on markdown originating from external sources such as cloned repos, email attachments, or downloaded gists, and configuring code review or repo-scan rules to reject markdown containing `bitfield (and `wavedrom, which the same release patches) fenced blocks pending the upgrade; note the markdown-scanning approach can be bypassed by attribute or whitespace variations, so it is a stopgap rather than a substitute for patching.
Affected VersionsENISA
Affected Packages
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
Markdown Preview Enhanced is a popular markdown rendering extension (available for VS Code and Atom) maintained by shd101wyy, identified by CPE cpe:2.3:a:shd101wyy:markdown_preview_enhanced. The extension supports embedded diagrams via fenced code blocks, including Bitfield register diagrams. Pre-0.8.28 the Bitfield renderer passed the block body to an interpretJS() helper that ultimately called Node's vm.runInNewContext(), turning what should be a static data island (arrays of register-field objects) into an arbitrary JavaScript execution context. This is a textbook CWE-94 (Improper Control of Generation of Code, 'Code Injection'): untrusted input is concatenated into a code-evaluation API. The 0.8.28 release replaces interpretJS() with JSON5.parse(), and the same release also patches a parallel eval()-based RCE in the WaveDrom renderer (issue #2315) and a Windows command-injection issue in external link opening, indicating a broader audit of unsafe parsers.
Know when Markdown Preview Enhanced 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
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Primary rating from Vendor (VulnCheck) · only source for this CVE.
CVSS VectorVendor: VulnCheck
Lifecycle Timeline
2DescriptionCVE.org
Markdown Preview Enhanced before 0.8.28 parses Bitfield fenced code blocks with interpretJS(), which evaluates the block content as code via vm.runInNewContext(), allowing arbitrary code execution. A crafted markdown document containing a malicious bitfield code block executes attacker-controlled code on the server side when the document is rendered or exported. Fixed in 0.8.28 by parsing bitfield register definitions with JSON5.parse(), since they are purely data.
Executive ViewAI
Markdown Preview Enhanced contains a critical arbitrary code execution vulnerability enabling attackers to compromise user systems through distribution of malicious markdown files that execute code when previewed or exported. Development teams and markdown-dependent users face direct system compromise risk. With no security patch currently available, immediate containment measures are required to reduce organizational exposure.
No vendor-released patch identified at time of analysis. Interim mitigations: restrict markdown preview operations to internally-trusted document sources only; disable extension for non-markdown-dependent users; require administrative review of markdown files from external sources before user access; establish daily monitoring of Markdown Preview Enhanced official releases for patch availability.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
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.
More in Markdown Preview Enhanced
View allAn issue in Markdown Preview Enhanced v0.6.5 and v0.19.6 for VSCode and Atom allows attackers to execute arbitrary comma
Markdown Preview Enhanced v0.6.5 and v0.19.6 for VSCode and Atom was discovered to contain a command injection vulnerabi
An issue in Visual Studio Code Extensions Markdown Preview Enhanced v0.8.18 allows attackers to execute arbitrary code v
Remote code execution in the Markdown Preview Enhanced extension (versions before 0.8.28) allows attackers to run arbitr
Remote code execution in Markdown Preview Enhanced before 0.8.28 on Windows allows attackers to inject OS commands throu
Arbitrary JavaScript execution in the Markdown Preview Enhanced VS Code extension (0.8.x, bundling crossnote 0.9.28) is
EUVD-2026-34869
GHSA-m5v2-jw65-jh59
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB