id: PYSEC-2026-2209 published: "2026-05-26T21:16:39.953Z" modified: "2026-07-13T05:49:57.392852Z" aliases: - CVE-2026-44899 - GHSA-ccfx-mfmx-2fx9 details: "Mistune is a Python Markdown parser with renderers and plugins. Prior to 3.2.1, the Image directive plugin validates the :width: and :height: options with a regex compiled as _num_re = re.compile(r\"^\\d+(?:\\.\\d*)?\"). When the validated value is not a plain integer, render_block_image() inserts it directly into a style=\"width:...;\" or style=\"height:...;\" attribute. Because the value was accepted by the prefix-only regex, any CSS after the leading digits reaches the style= attribute verbatim and without escaping. This vulnerability is fixed in 3.2.1." affected: - package: name: mistune ecosystem: PyPI purl: pkg:pypi/mistune ranges: - type: ECOSYSTEM events: - introduced: "0" - fixed: 3.2.1 versions: - 0.1.0 - 0.2.0 - 0.3.0 - 0.3.1 - "0.4" - 0.4.1 - "0.5" - 0.5.1 - "0.6" - "0.7" - 0.7.1 - 0.7.2 - 0.7.3 - 0.7.4 - "0.8" - 0.8.1 - 0.8.2 - 0.8.3 - 0.8.4 - 2.0.0 - 2.0.0a1 - 2.0.0a2 - 2.0.0a3 - 2.0.0a4 - 2.0.0a5 - 2.0.0a6 - 2.0.0rc1 - 2.0.1 - 2.0.2 - 2.0.3 - 2.0.4 - 2.0.5 - 2.1.0 - 3.0.0 - 3.0.0a1 - 3.0.0a2 - 3.0.0a3 - 3.0.0rc1 - 3.0.0rc2 - 3.0.0rc3 - 3.0.0rc4 - 3.0.0rc5 - 3.0.1 - 3.0.2 - 3.1.0 - 3.1.1 - 3.1.2 - 3.1.3 - 3.1.4 - 3.2.0 ecosystem_specific: {} references: - type: ADVISORY url: https://github.com/lepture/mistune/releases/tag/v3.2.1 - type: EVIDENCE url: https://github.com/lepture/mistune/security/advisories/GHSA-ccfx-mfmx-2fx9 severity: - type: CVSS_V3 score: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N