WP Coder 5.0以下 - 画像型ショートコード属性と_wp_attachment_image_alt添付ファイルメタデータを介した認証済みの投稿者以上による保存型クロスサイトスクリプティング
元情報の公開:2026/11/18 06:38 / 元情報の更新:2026/11/18 20:30(日本時間)
日本語訳
WordPress用プラグイン「WP Coder – Insert & Manage Code Snippets」は、5.0以下のすべてのバージョンで、入力のサニタイズと出力のエスケープが不十分なため、alt_text(WordPressメディアREST)から_wp_attachment_image_alt投稿メタデータへ保存される値パラメータを介した保存型クロスサイトスクリプティングの脆弱性があります。投稿者以上の権限を持つ認証済みの攻撃者が任意のウェブスクリプトをページに埋め込み、そのページにユーザーがアクセスするたびにスクリプトを実行させることができます。
サイトに管理者が作成した画像型のスニペットが存在する必要があります。攻撃者は標準のWordPressメディアRESTエンドポイントで画像をアップロードし、代替テキストをWordPressコアのsanitize_text_field()を通過する二重引用符ベースのペイロードに設定してから、ショートコードを埋め込んだ投稿を公開します。
原文(英語)
WP Coder <= 5.0 - Authenticated (Author+) Stored Cross-Site Scripting via '_wp_attachment_image_alt' Attachment Meta via Image-type Shortcode Attribute
The WP Coder – Insert & Manage Code Snippets plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the 'alt_text (WP media REST) → _wp_attachment_image_alt post meta' parameter in all versions up to, and including, 5.0 due to insufficient input sanitization and output escaping. This makes it possible for authenticated attackers, with author-level access and above, to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page. This requires that an admin-authored image-type snippet exists on the site, as the attacker uploads an image via the standard WordPress media REST endpoint, sets its Alt Text to a double-quote-based payload that survives WordPress core's sanitize_text_field(), and then publishes a post embedding the shortcode.
引用元:Wordfence
確認と対応の進め方
WordPress管理画面の「プラグイン」→「インストール済みプラグイン」で、対象製品の名前とバージョンを確認してください。
影響バージョンに該当する場合は、バックアップを確認し、「ダッシュボード」→「更新」から対象製品を更新してください。更新後は、記事に記載した修正版になっていることと、サイトの表示・機能を確認してください。
更新が表示されない場合は、製品の提供元で更新情報と更新方法を確認してください。