Skip to content

chore(deps): pin dompurify to 3.4.17 in the Studio frontend - #514

Merged
pbertsch merged 1 commit into
mainfrom
chore/bump-dompurify
Oct 27, 2026
Merged

pbertsch merged 1 commit into
mainfrom
chore/bump-dompurify

Conversation

@pbertsch

Copy link
Copy Markdown
Member

Summary

Pins dompurify to 3.4.17 in the Studio frontend's npm tree with an overrides entry, which closes the open Dependabot alerts on the lockfile.

monaco-editor 0.57.0 (the latest release) pins dompurify exactly at 3.4.15, so npm update changes nothing and an override is the only lockfile-level fix. The editor bundles its own copy of DOMPurify, so the shipped editor code does not change until a Monaco release vendors a patched version. The advisories need options (IN_PLACE, SAFE_FOR_TEMPLATES, PARSER_MEDIA_TYPE) that the editor's sanitizer does not set.

Test plan

  • npm ci, npm run build, npm run typecheck:device-view in studio/frontend
  • npm run test:device-view (116) and npm run test:probescript (11), npm run check:probescript
  • CI green: Build, Go unit tests, probe-convert tests, Lint, Disclosure guard, Studio frontend, Studio UI

🤖 Generated with Claude Code

monaco-editor 0.57.0 declares dompurify exactly at 3.4.15, so npm update cannot move the resolved version. An npm override sets dompurify to 3.4.17 for the Studio frontend's whole tree, the patched release for GHSA-cg2g-xh64-v4q7, GHSA-mrv2-3pqr-j5jr, GHSA-c6gr-qvv4-5v3f, GHSA-6688-9rhm-gjv2 and GHSA-p98j-92pf-mc4p.

The editor does not import this npm package. It bundles its own copy of DOMPurify, 3.4.15, and the built assets still contain that copy, so the override changes the lockfile and node_modules, not the code that ships. The advisories need options the bundled sanitizer does not set: IN_PLACE, SAFE_FOR_TEMPLATES or PARSER_MEDIA_TYPE. Shipping the patched sanitizer needs a monaco-editor release that bundles 3.4.17.

Checked with npm ci, npm run build, typecheck:device-view, test:device-view, test:probescript and check:probescript.
@pbertsch
pbertsch requested a review from a team as a code owner October 27, 2026 02:16
@pbertsch
pbertsch merged commit 6e794e7 into main Oct 27, 2026
21 of 22 checks passed
@pbertsch pbertsch mentioned this pull request Oct 27, 2026
3 of 4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant