CVE-2026-54702: Markdown Preview Enhanced: Blind Command Dispatch via Unvalidated Webview Message Handler

Published Oct 14, 2026
·
Updated

Markdown Preview Enhanced is a Markdown preview extension for Visual Studio Code. Prior to 0.8.30, the webview message handler in src/preview-provider.ts accepts an attacker-controlled command value and attacker-controlled args, constructs a command in the crossnote namespace, and invokes vscode.commands.executeCommand without an allowlist or type validation. JavaScript already executing in the preview webview can use this bridge to invoke privileged extension commands, including file modification, code-chunk execution, export-tool execution, and arbitrary URL opening, with attacker-selected arguments. Exploitation requires a separate webview JavaScript execution path, such as the independently tracked .crossnote/head.html injection, but no further authorization check protects the extension-host command boundary. This issue is fixed in version 0.8.30.

Affected Software

1 affected component
Markdown Preview Enhanced<0.8.30

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade Markdown Preview Enhanced to a version that resolves this vulnerability.

    Fixed in 0.8.30

Event History

Oct 14, 2026
CVE Published
via MITRE·07:13 PM
Data Sourced
via MITRE·07:13 PM
DescriptionWeakness

Frequently Asked Questions

1

What must an attacker achieve before they can exploit this issue?

They need a separate way to execute JavaScript in the Markdown Preview Enhanced preview webview, such as the independently tracked .crossnote/head.html injection. The command bridge itself does not add another authorization check once malicious JavaScript is running in that webview.

2

What actions could malicious webview JavaScript trigger?

It can invoke privileged commands in the extension's _crossnote namespace with attacker-selected arguments. The described impacts include file modification, code-chunk execution, export-tool execution, and opening arbitrary URLs.

3

Which versions need to be remediated?

Versions earlier than 0.8.30 are affected. Update Markdown Preview Enhanced to version 0.8.30 or later.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203