Bump bundled DOMPurify to 3.4.12+ (0.56.0 ships 3.4.8)
[email protected] depends on [email protected].
Two DOMPurify advisories land above that version:
| CVE | Fixed in DOMPurify |
|---|---|
| CVE-2026-65898 | 3.4.11 |
| CVE-2026-66010 | 3.4.12 |
DOMPurify 3.4.13 is current on npm.
Why this matters to embedders specifically
DOMPurify is bundled into the shipped monaco artifacts (e.g. min/vs/editor.api-*.js) rather than resolved at the consumer's dependency graph. That means downstream consumers cannot upgrade it themselves — the only options are to hand-patch a third-party bundle, or wait.
In practice it surfaces as a "Vulnerable JS Library" finding against every site embedding Monaco, and there is no consumer-side remediation to offer in response.
Would you consider bumping the DOMPurify dependency to 3.4.12 or later?
Note on severity
I appreciate Monaco uses DOMPurify for its own internal sanitisation (markdown in hovers, suggestion documentation and similar), so the practical exposure for many embedders is lower than a raw CVE count suggests. This is raised as dependency hygiene and to remove a recurring, unactionable scanner finding for embedders, not as a report of an exploitable path in Monaco itself.
linked: https://github.com/microsoft/monaco-editor/issues/5352
Hi — thanks for the clear write-up, and for framing this as embedder hygiene rather than a Monaco exploit path.
I would be happy to help land a bump to DOMPurify ≥3.4.12 (likely 3.4.14, current on the registry). From #5333 / #5347 it looks like the bundled copy is driven by the vendored files in microsoft/vscode (src/vs/base/browser/dompurify/, still on 3.4.8 in cgmanifest.json), so a lockfile-only change here would not stick.
Would you (and the maintainers) prefer:
- a vscode built-in dompurify bump PR first, then a monaco-editor-core / lockfile follow-up here, or
- guidance on another path you already have in mind?
Happy to take whichever approach you prefer. Thanks!
it seems to be fixed in monaco-editor v0.57.0.
$ npm view [email protected] --json dependencies
{
"marked": "14.0.0",
"dompurify": "3.4.15"
}
3.4.15 is still too old. This needs to be updated to 3.4.16 to address this:
https://github.com/advisories/GHSA-p98j-92pf-mc4p
Better yet, just use a range version?
3.4.16 has 3 more issues:
https://github.com/advisories/GHSA-cg2g-xh64-v4q7 https://github.com/advisories/GHSA-mrv2-3pqr-j5jr https://github.com/advisories/GHSA-c6gr-qvv4-5v3f
monaco-editor 0.57.0 (now latest) bundles DOMPurify 3.4.15, verified in the published package. That covers CVE-2026-65898 (fixed in 3.4.11) and CVE-2026-66010 (fixed in 3.4.12), so I'm closing this.
The later advisories mentioned here (GHSA-p98j-92pf-mc4p, GHSA-6688-9rhm-gjv2, GHSA-cg2g-xh64-v4q7, GHSA-mrv2-3pqr-j5jr, GHSA-c6gr-qvv4-5v3f) need IN_PLACE, SAFE_FOR_TEMPLATES or PARSER_MEDIA_TYPE: 'application/xhtml+xml'. Monaco uses none of these. Monaco's DOMPurify comes from VS Code, which already vendors 3.4.16, so future releases will pick that up.