Vulnerability · Published Jul 8, 2026 · Assigned by GitHub_M

CVE-2026-59926Mistune: XSS via unescaped class option in Admonition 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.3% (higher than 26% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 4.0)5.3Medium
Exploit odds (30 days)0.3%top 74.1% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

Mistune is a Python Markdown parser with renderers and plugins. Prior to 3.2.1, render_admonition() in src/mistune/directives/admonition.py concatenates the Admonition directive :class: option into the HTML class attribute without escaping, allowing attribute injection and cross-site scripting even when HTMLRenderer escape mode is enabled. This issue is fixed in version 3.2.1.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:13mistuneno fix listedDEBIAN-CVE-2026-59926
Debian:14mistune3.1.4-1DEBIAN-CVE-2026-59926
PyPImistune3.3.0GHSA-g97x-gvcm-x72h
PyPImistune3.3.0PYSEC-2026-2214
Ubuntu:22.04:LTSmistuneno fix listedUBUNTU-CVE-2026-59926
Ubuntu:24.04:LTSmistuneno fix listedUBUNTU-CVE-2026-59926
Ubuntu:25.10mistuneno fix listedUBUNTU-CVE-2026-59926
Ubuntu:26.04:LTSmistuneno fix listedUBUNTU-CVE-2026-59926
Ubuntu:26.10mistuneno fix listedUBUNTU-CVE-2026-59926

Affected products (as reported)

VendorProductVersions
lepture mistune < 3.2.1

Weakness: CWE-79 · Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N

References