Skip to main content

Markdown Preview Enhanced CVE-2026-49492

| EUVDEUVD-2026-34868 HIGH
OS Command Injection (CWE-78)
2026-06-05 VulnCheck GHSA-3vxg-8vgp-994w
8.6
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

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

  1. Access
    Craft markdown with shell metacharacters in filename/import/latex_engine attribute
  2. Delivery
    Deliver via PR, email, or repo clone
  3. Exploit
    Victim opens preview on Windows MPE <0.8.28
  4. Execution
    Extension passes attribute through cmd.exe shell
  5. Persist
    Injected OS commands execute as the user
  6. Impact
    Establish foothold on developer workstation

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

Exploitation requires three concrete conditions all present in the CVE description: (1) the victim runs Markdown Preview Enhanced before 0.8.28 on Windows - the description explicitly states the shell-injection path only reaches OS command execution on Windows; (2) the victim opens a preview of the attacker's markdown document (UI:A in the CVSS vector) - passive receipt of the file is not enough; (3) the malicious markdown must populate one of three specific sinks: a diagram block's filename attribute, an @import file path, or the latex_engine attribute on a code chunk. No authentication is required (PR:N) and attack complexity is low (AC:L). Limiting factors that reduce realistic risk: non-Windows installs (macOS/Linux) are not affected per the description, users who preview only their own markdown are not exposed, and organizations that disable the extension or block preview of untrusted files neutralize the chain.

Impact

CVSS 4.0 scores this 8.6 with vector AV:N/AC:L/AT:N/PR:N/UI:A and high confidentiality/integrity/availability impact, reflecting that delivery is over the network (a markdown file from any untrusted source) but the victim must open the preview (UI:A) - a realistic outcome for a tool whose entire purpose is previewing untrusted markdown. The vulnerability is not listed in CISA KEV and no EPSS score is supplied, so quantitative exploitation probability is unknown; no public exploit identified at time of analysis, though VulnCheck's coordinated advisory describes the injection sinks precisely. Real-world risk is concentrated on Windows developers and technical writers who routinely preview markdown received via email, pull requests, or cloned repositories - a population that overlaps with high-value targets. The CVSS vector indicates network attack vector but actual delivery is file-based social engineering, which defenders should weigh when prioritizing.

Exploit ScenarioDerived

An attacker authors a markdown file containing, for example, a Mermaid or PlantUML diagram block whose filename attribute embeds Windows shell metacharacters (e.g. a value chained with & or | to a second command), then delivers the file via a pull request, email attachment, or public repository. When a Windows developer opens the file and Markdown Preview Enhanced renders it, the shell-invoked open path concatenates the attacker-controlled value into a command line and cmd.exe executes the attached payload under the user's session. No public exploit identified at time of analysis, but the VulnCheck advisory and the release notes name the exact injectable attributes, making proof-of-concept development trivial.

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

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

Alert me

AnalysisAIv1 – Jun 05, 2026

Remote code execution in Markdown Preview Enhanced before 0.8.28 on Windows allows attackers to inject OS commands through crafted markdown documents that abuse the diagram filename attribute, imported file paths, or the latex_engine code-chunk attribute, all of which were passed through a shell without validation. Exploitation requires the victim to preview the malicious document (UI:A), and no public exploit identified at time of analysis, though VulnCheck-published advisory details and a tagged fix release make weaponization straightforward.

RemediationAI

Vendor-released patch: upgrade Markdown Preview Enhanced to 0.8.28 or later (https://github.com/shd101wyy/vscode-markdown-preview-enhanced/releases/tag/0.8.28), which spawns child processes with literal argv arrays and validates the diagram filename, @import paths, and latex_engine attributes before use; the bundled crossnote 0.9.29 upgrade also closes the related WaveDrom and Bitfield eval()/vm.runInNewContext RCE paths. Until the upgrade is rolled out, compensating controls for Windows users include disabling automatic preview on file open and refusing to preview markdown from untrusted sources (mail attachments, third-party PRs, cloned repos), which preserves editing but loses on-save preview; reviewing markdown as plain text via a non-rendering editor view eliminates the sink at the cost of formatting fidelity; and on managed fleets, restricting the extension via VS Code extension allow/deny policies removes the attack surface entirely at the cost of the feature. Cross-reference the VulnCheck advisory at https://www.vulncheck.com/advisories/markdown-preview-enhanced-os-command-injection-in-external-file-and-link-opening for indicators.

Affected VersionsENISA

Markdown Preview Enhanced 0 <0.8.28

Affected Packages

euvd markdown_preview_enhanced fix: 0.8.28

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 VS Code/Atom extension (shd101wyy/vscode-markdown-preview-enhanced per the CPE cpe:2.3:a:shd101wyy:markdown_preview_enhanced) that renders markdown with extended diagram, LaTeX, and import features. The root cause is CWE-78 (OS Command Injection): the extension invoked the OS shell to open external files/links and forwarded user-controlled values - diagram filename attributes, @import file paths, and the latex_engine attribute on code chunks - directly into shell command strings. On Windows, cmd.exe metacharacters embedded in those attributes are interpreted by the shell rather than treated as filename literals. The 0.8.28 release fixes this by spawning child processes with arguments passed as a literal argv array and by validating the inputs before use, and it also bundles unrelated fixes for eval()-based RCE in the WaveDrom and Bitfield renderers via crossnote 0.9.29.

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

Vendor (VulnCheck) PRIMARY 8.6 HIGH
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

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

3
Patch available
Jun 05, 2026 - 20:02 EUVD
CVSS changed
Jun 05, 2026 - 18:22 NVD
8.8 (HIGH) 8.6 (HIGH)
CVE Published
Jun 05, 2026 - 17:49 nvd
HIGH 8.6

DescriptionCVE.org

Markdown Preview Enhanced before 0.8.28 opens external files and links from the preview through a shell and does not validate untrusted inputs taken from the markdown document - the diagram filename attribute, imported file paths, and the latex_engine code-chunk attribute. On Windows, a crafted markdown document can inject operating system commands that execute when the document is previewed. Fixed in 0.8.28 by passing these inputs as literal arguments instead of through a shell and validating them before use.

Executive ViewAI

Why It Matters

Markdown Preview Enhanced for Windows contains a high-severity remote code execution vulnerability (CVSS 8.6) triggered by previewing malicious documents. Currently no public exploit identified, but developers are at immediate risk of system compromise, potentially exposing source code and credentials. Organizations using this extension across development teams face significant operational security risk.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: disable Markdown Preview Enhanced extension, disable diagram rendering and LaTeX processing in any markdown tool, restrict document sources to internal approved materials, enforce sandbox or container-based markdown processing, and monitor vendor release schedules for version 0.8.28.

Threat Intelligence Overview

EPSS Score
0.0%
Top 87% exploitable
Social Media
2
Sightings
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.0%
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

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

Attack Technique

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

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