<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/supply-chain-security-analysis-of-a-9-5m-install-vs-code-extension-projectdiscovery-blog-mj5ppg0hr" -->

---
title: Supply Chain Security Analysis of a 9.5M-Install VS Code...
description: A security audit by ProjectDiscovery's Neo agent uncovered five CVEs in Markdown Preview Enhanced, a VS Code extension with roughly 9.5 million installs. A...
canonical: https://daily.dev/posts/supply-chain-security-analysis-of-a-9-5m-install-vs-code-extension-projectdiscovery-blog-mj5ppg0hr
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Supply Chain Security Analysis of a 9.5M-Install VS Code Extension — ProjectDiscovery Blog | daily.dev
og:description: A security audit by ProjectDiscovery's Neo agent uncovered five CVEs in Markdown Preview Enhanced, a VS Code extension with roughly 9.5 million installs. A...
og:url: https://daily.dev/posts/supply-chain-security-analysis-of-a-9-5m-install-vs-code-extension-projectdiscovery-blog-mj5ppg0hr
og:image: https://api.daily.dev/og/posts/Mj5pPG0hr.png
og:image:alt: Supply Chain Security Analysis of a 9.5M-Install VS Code Extension — ProjectDiscovery Blog
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Supply Chain Security Analysis of a 9.5M-Install VS Code Extension — ProjectDiscovery Blog

**[ProjectDiscovery Blog](https://daily.dev/sources/project-discovery)** · 12 min read · 2 upvotes · 0 comments

## Summary

A security audit by ProjectDiscovery's Neo agent uncovered five CVEs in Markdown Preview Enhanced, a VS Code extension with roughly 9.5 million installs. A WaveDrom diagram block could trigger JavaScript execution via eval() inside the preview webview, chaining through an unvalidated postMessage dispatcher to an arbitrary file write on disk (CVE-2026-50733). Further auditing found a VM sandbox escape in workspace config files (CVE-2026-54566) giving direct OS command execution, a stored XSS via unsanitized head.html injection (CVE-2026-54701), and two shared infrastructure flaws in the command dispatcher and file-write API (CVE-2026-54702, CVE-2026-54703). All five were fixed across versions v0.8.28 through v0.8.30, with eval replaced by JSON parsing, vm.runInNewContext() and sval replaced with a WASM-isolated QuickJS engine, script stripping added to head.html injection, and a command allowlist plus URI pinning added to the dispatcher. Users are urged to update to v0.8.30 or later.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://projectdiscovery.io/blog/a-9-5m-install-vs-code-extension-one-markdown-file-and-a-supply-chain-foothold>

## Questions this post answers

### What is CVE-2026-50733 in the Markdown Preview Enhanced VS Code extension?

CVE-2026-50733 is a WaveDrom rendering vulnerability where the extension used window.eval() to render raw text from WaveDrom diagram blocks in Markdown files, letting attacker-controlled JavaScript execute inside the preview webview with no opt-in required. It was fixed in version 0.8.28 by replacing eval with JSON5.parse and a normalizeWavedromSource() validator.

_Track fixes like this one for VS Code extensions you depend on directly on daily.dev._

### How did the VM sandbox escape in Markdown Preview Enhanced (CVE-2026-54566) allow arbitrary command execution?

The extension evaluated .crossnote/config.js and .crossnote/parser.js using Node's vm.runInNewContext(), which Node's own documentation warns is not a security boundary. Because the sandbox object shares the host V8 realm, an attacker could reach this.constructor.constructor to get the host Function constructor, then call getBuiltinModule('child_process') to run arbitrary OS commands, just by opening a Markdown file in a workspace containing the malicious config file. Fixed in v0.8.29 by switching to QuickJS compiled to WebAssembly.

_Developers auditing extension sandboxing can weigh cases like this on daily.dev before trusting vm.runInNewContext()._

### Why does a webview XSS bug in a code editor extension count as a supply-chain risk?

Because arbitrary file write from inside a webview can target files the system later trusts, such as shell startup files (~/.bashrc), Git hooks (.git/hooks/pre-commit), build configs (.vscode/tasks.json), or SSH authorized_keys, turning a Markdown-triggered exploit into persistent remote access or CI compromise. A vulnerable build of a 9.5-million-install extension becomes a shared dependency across millions of auto-updating environments.

_Anyone assessing extension risk in their toolchain can follow writeups like this on daily.dev._

## Similar posts on daily.dev

- [When Your IDE Becomes a RCE Endpoint](https://daily.dev/posts/when-your-ide-becomes-a-rce-endpoint-fwzhdkz3r) · Trendyol Tech · 6 upvotes · 1 comments
- [CVE-2026-22718: Command injection on user machine using VSCode extension for Spring CLI](https://daily.dev/posts/cve-2026-22718-command-injection-on-user-machine-using-vscode-extension-for-spring-cli-qah3dxopu) · Spring · 1 upvotes · 0 comments
- [Bloom Security’s Extension Resurrection research exposes a blind spot in developer security](https://daily.dev/posts/bloom-security-s-extension-resurrection-research-exposes-a-blind-spot-in-developer-security-ww5xzwiek) · The Next Web · 0 upvotes · 0 comments

---

Tags: [#security](https://daily.dev/tags/security), [#javascript](https://daily.dev/tags/javascript), [#vscode](https://daily.dev/tags/vscode)

[View this post on daily.dev](https://daily.dev/posts/supply-chain-security-analysis-of-a-9-5m-install-vs-code-extension-projectdiscovery-blog-mj5ppg0hr)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Supply Chain Security Analysis of a 9.5M-Install VS Code Extension — ProjectDiscovery Blog","url":"https://daily.dev/posts/supply-chain-security-analysis-of-a-9-5m-install-vs-code-extension-projectdiscovery-blog-mj5ppg0hr","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/supply-chain-security-analysis-of-a-9-5m-install-vs-code-extension-projectdiscovery-blog-mj5ppg0hr"},"datePublished":"2026-08-16T13:09:43.068Z","dateModified":"2026-09-14T07:18:41.423Z","description":"A security audit by ProjectDiscovery's Neo agent uncovered five CVEs in Markdown Preview Enhanced, a VS Code extension with roughly 9.5 million installs. A...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/3568fcd6b8e29a7fad997eb36dbb83fc?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/3568fcd6b8e29a7fad997eb36dbb83fc?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"ProjectDiscovery Blog","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"ProjectDiscovery Blog","logo":"https://media.daily.dev/image/upload/s--dG5jxdtR--/f_auto,q_auto/v1780213349/logos/project-discovery?_a=BAMAMiWQ0","url":"https://daily.dev/sources/project-discovery"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/supply-chain-security-analysis-of-a-9-5m-install-vs-code-extension-projectdiscovery-blog-mj5ppg0hr","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":2},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"security,javascript,vscode","timeRequired":"PT12M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"ProjectDiscovery Blog","item":"https://daily.dev/sources/project-discovery"},{"@type":"ListItem","position":3,"name":"Supply Chain Security Analysis of a 9.5M-Install VS Code Extension — ProjectDiscovery Blog"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/supply-chain-security-analysis-of-a-9-5m-install-vs-code-extension-projectdiscovery-blog-mj5ppg0hr#faq","mainEntity":[{"@type":"Question","name":"What is CVE-2026-50733 in the Markdown Preview Enhanced VS Code extension?","acceptedAnswer":{"@type":"Answer","text":"CVE-2026-50733 is a WaveDrom rendering vulnerability where the extension used window.eval() to render raw text from WaveDrom diagram blocks in Markdown files, letting attacker-controlled JavaScript execute inside the preview webview with no opt-in required. It was fixed in version 0.8.28 by replacing eval with JSON5.parse and a normalizeWavedromSource() validator. Track fixes like this one for VS Code extensions you depend on directly on daily.dev."}},{"@type":"Question","name":"How did the VM sandbox escape in Markdown Preview Enhanced (CVE-2026-54566) allow arbitrary command execution?","acceptedAnswer":{"@type":"Answer","text":"The extension evaluated .crossnote/config.js and .crossnote/parser.js using Node's vm.runInNewContext(), which Node's own documentation warns is not a security boundary. Because the sandbox object shares the host V8 realm, an attacker could reach this.constructor.constructor to get the host Function constructor, then call getBuiltinModule('child_process') to run arbitrary OS commands, just by opening a Markdown file in a workspace containing the malicious config file. Fixed in v0.8.29 by switching to QuickJS compiled to WebAssembly. Developers auditing extension sandboxing can weigh cases like this on daily.dev before trusting vm.runInNewContext()."}},{"@type":"Question","name":"Why does a webview XSS bug in a code editor extension count as a supply-chain risk?","acceptedAnswer":{"@type":"Answer","text":"Because arbitrary file write from inside a webview can target files the system later trusts, such as shell startup files (~/.bashrc), Git hooks (.git/hooks/pre-commit), build configs (.vscode/tasks.json), or SSH authorized_keys, turning a Markdown-triggered exploit into persistent remote access or CI compromise. A vulnerable build of a 9.5-million-install extension becomes a shared dependency across millions of auto-updating environments. Anyone assessing extension risk in their toolchain can follow writeups like this on daily.dev."}}]}
```

