本文へ移動
English version →
高 8.2

SVGOのremoveScriptsで実行可能なリンクが残り、スクリプトを実行される

CVE-2026-84370 SecPulse初出

概要

SVGOのopt-inプラグインremoveScriptsが、名前空間付きのa要素や制御文字を含むURLを正しく除去できず、実行可能なリンクが残る問題です。悪用されると、被害者がリンクを開いた際にSVGの配信元のオリジンでスクリプトが実行される恐れがあります。影響を受けるのはnpmのsvgoの4.0.0以上4.1.0未満で、4.1.0に更新してください。

AI要約

SecPulse が外部の生成 AI を使って作った要約です。誤りを含むことがあります。重要な判断の前に、下の原文と参照URLを確認してください。

svgo という製品で、CVE-2026-84370 という番号がついた弱点 (脆弱性) が見つかりました。
悪い人がインターネット越しに removeScripts のような特定の入り口を狙うことで、製品の中を不正に操作できてしまいます。
機密情報が外部に流出する可能性があります。重要度は CVSS スコア 8.2/10 です。
対策: svgo を 4.1.0 以上に更新してください。
心配なら、システム担当者や製品の公式サイトで「svgo CVE-2026-84370」を検索してください。

CVE-2026-84370 (svgo) — CWE-79 / CVSS v3 8.2
攻撃ベクター: ネットワーク経由 (リモート攻撃可) / 認証不要
脆弱箇所: removeScripts / href / removeScriptElement
修正バージョン: 4.1.0 (即時適用推奨)
暫定回避: For hostile input, use a dedicated SVG sanitization tool before passing the SVG to SVGO.
対応方針: 1) SBOMで影響バージョン横断確認, 2) ステージング検証→本番更新, 3) WAF/プロキシで該当エンドポイントを監視, 4) ログでIOC調査。
参考: 当ページの『参照URL』の GHSA / vendor advisory / patched release を参照。

何が問題か

svgo に クロスサイトスクリプティング (XSS) (CWE-79) があります。攻撃者は removeScripts を経由して脆弱な処理に到達し、認証なしで悪用できます。

影響範囲

svgo の影響バージョンはベンダーのアドバイザリで確認してください。攻撃箇所: removeScripts / href / removeScriptElement。

重要度

重要度: 重要 (CVSS 8.2/10)。機密情報が外部に流出する可能性があります。

修正方法

4.1.0 に更新してください。

暫定回避

暫定回避: For hostile input, use a dedicated SVG sanitization tool before passing the SVG to SVGO.

検知方法

Webサーバ・プロキシ・WAFログで該当CVEのIOCに合致する不審リクエストを検索。SBOM/依存ファイルで影響バージョンを横断確認。

対応アクション

SOC/SREチームが順番に実行すべき具体的なステップとコマンド例

  1. 1
    影響範囲の特定identify
    grep -r 'svgo' . | grep -v node_modules

    リポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で svgo を grep し、稼働しているサービス・バージョンを把握する。

  2. 2
    暫定回避策の適用mitigate
    For hostile input, use a dedicated SVG sanitization tool before passing the SVG to SVGO.

    パッチが適用されるまでの応急処置として、For hostile input, use a dedicated SVG sanitization tool before passing the SVG to SVGO. を実施。回避策の副作用 (機能低下) を確認した上で。

  3. 3
    パッチ適用patch
    Upgrade svgo to 4.1.0

    ステージング環境で 4.1.0 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。

  4. 4
    事後検証verify
    Confirm patched version is live in production

    パッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。

影響パッケージ

パッケージ影響を受ける版 → 修正版
npmsvgo
4.1.0 未満→ 4.1.0

ディストリビューション別の修正状況

各ディストリビューションが公開している、この CVE の記録です。修正版は配布版ごとに違うので、リンク先で確かめてください。

原文の説明 取得元が公開している説明をそのまま載せています (多くは英語)。

Summary

SVGO's opt-in removeScripts plugin failed to remove some executable links. Namespace-prefixed SVG anchors and URL schemes containing ASCII tabs or newlines could bypass its checks. Applications that used this plugin as their only protection for untrusted SVG input could expose users to cross-site scripting (XSS).

SVGO is an optimizer rather than a comprehensive sanitization library, but removeScripts is maintained for consumers that already rely on it to remove common script execution paths.

Details

Two related bypasses were present:

  1. The plugin inspected unprefixed SVG elements but did not recognize namespace-prefixed SVG anchors such as when the prefix was bound to the SVG namespace. Their executable href or namespaced *:href values remained intact.
  2. The URL check did not account for ASCII tab, line-feed, or carriage-return characters embedded in a scheme. Browsers remove these characters before parsing the scheme, so values such as java	script: could remain executable after bypassing the plugin's javascript: check.

Anchors in unrelated custom namespaces are not executable SVG anchors and remain untouched.

Impact

If an application optimized attacker-controlled SVGs with removeScripts and then served the result in an active browser context, a victim could follow a link that executes script in the SVG's origin. Depending on the embedding and origin configuration, this could expose cookies or local storage, modify content, or…

出典: NIST National Vulnerability Database NVD GitHub Advisory

参照URL

当サイトでは、アクセス解析と広告の効果測定のためにCookieを使います。株式会社Gameのサイト共通の設定です。 詳しく