Mistune projectのMistuneにおけるクロスサイトスクリプティングの脆弱性
タイトル Mistune projectのMistuneにおけるクロスサイトスクリプティングの脆弱性
概要

Mistuneはレンダラーとプラグインを備えたPython製Markdownパーサーです。バージョン3.2.1以前では、render_toc_ul()は(level, id, text)のタプルリストからul目次ツリーを構築します。id値(href="#id"として使用)およびテキスト値(リンクの表示ラベルとして使用)は、どちらもHTMLエスケープされることなくプレーンなPythonフォーマット文字列を通じてaタグに挿入されます。見出しIDがユーザー提供の見出しテキストから派生される場合(可読スラッグアンカーの標準的な使用例)、攻撃者はhref="#..."属性のコンテキストを突破し、レンダリングされたTOCに任意のHTMLタグを直接注入できます。scriptブロックも含めて、見出しテキストにそれらを作成可能です。この脆弱性はバージョン3.2.1で修正されました。

想定される影響 ・当該ソフトウェアが扱う情報の一部が外部に漏れる可能性があります。 ・当該ソフトウェアが扱う情報の一部が書き換えられる可能性があります。 ・当該ソフトウェアは停止しません。 
対策

ベンダ情報を参照して適切な対策を実施してください。

公表日 2026年5月26日0:00
登録日 2026年6月3日15:35
最終更新日 2026年6月3日15:35
CVSS3.0 : 警告
スコア 6.1
ベクター CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
影響を受けるシステム
Mistune project
Mistune 3.2.1 未満
CVE (情報セキュリティ 共通脆弱性識別子)
CWE (共通脆弱性タイプ一覧)
ベンダー情報
その他
変更履歴
No 変更内容 変更日
1 [2026年06月03日]
  掲載
2026年6月3日15:35

NVD脆弱性情報
CVE-2026-44898
概要

Mistune is a Python Markdown parser with renderers and plugins. Prior to 3.2.1, render_toc_ul() builds a <ul> table-of-contents tree from a list of (level, id, text) tuples. Both the id value (used as href="#<id>") and the text value (used as the visible link label) are inserted into <a> tags via a plain Python format string — with no HTML escaping applied to either value. When heading IDs are derived from user-supplied heading text (the standard use-case for readable slug anchors), an attacker can craft a heading whose text breaks out of the href="#..." attribute context, injecting arbitrary HTML tags including <script> blocks directly into the rendered TOC. This vulnerability is fixed in 3.2.1.

公表日 2026年5月27日6:16
登録日 2026年5月28日4:09
最終更新日 2026年5月28日22:42
影響を受けるソフトウェアの構成
構成1 以上 以下 より上 未満
cpe:2.3:a:mistune_project:mistune:*:*:*:*:*:*:*:* 3.2.1
関連情報、対策とツール
共通脆弱性一覧