Vulnerability · Published May 26, 2026 · Assigned by GitHub_M
CVE-2026-44896Mistune: XSS via unescaped figclass/figwidth in Figure directive
Medium 5.3
In plain English
A medium-severity cross-site scripting in mistune from lepture. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.2% (higher than 10% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
Mistune is a Python Markdown parser with renderers and plugins. In 3.2.0 and earlier, in src/mistune/directives/image.py, the render_figure() function concatenates figclass and figwidth options directly into HTML attributes without escaping. This allows attribute injection and XSS even when HTMLRenderer(escape=True) is used, because these values bypass the inline renderer. Version 3.2.1 contains a patch.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian:12 | mistune | no fix listed | DEBIAN-CVE-2026-44896 |
| Debian:13 | mistune | no fix listed | DEBIAN-CVE-2026-44896 |
| Debian:14 | mistune | no fix listed | DEBIAN-CVE-2026-44896 |
| PyPI | mistune | 3.2.1 | GHSA-58cw-g322-p94v |
| PyPI | mistune | 3.2.1 | PYSEC-2026-168 |
| Ubuntu:22.04:LTS | mistune | no fix listed | UBUNTU-CVE-2026-44896 |
| Ubuntu:24.04:LTS | mistune | no fix listed | UBUNTU-CVE-2026-44896 |
| Ubuntu:25.10 | mistune | no fix listed | UBUNTU-CVE-2026-44896 |
| Ubuntu:26.04:LTS | mistune | no fix listed | UBUNTU-CVE-2026-44896 |
| Ubuntu:26.10 | mistune | no fix listed | UBUNTU-CVE-2026-44896 |
| Ubuntu:22.04:LTS | mistune0 | no fix listed | UBUNTU-CVE-2026-44896 |
| Ubuntu:24.04:LTS | mistune0 | no fix listed | UBUNTU-CVE-2026-44896 |
| Ubuntu:25.10 | mistune0 | no fix listed | UBUNTU-CVE-2026-44896 |
| Ubuntu:26.04:LTS | mistune0 | no fix listed | UBUNTU-CVE-2026-44896 |
| Ubuntu:26.10 | mistune0 | no fix listed | UBUNTU-CVE-2026-44896 |
Affected products (as reported)
Weakness: CWE-79 · Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N