WP STAGING 4.17.0以下 - rest_routeクエリパラメータを介した認証不要の認可回避
元情報の公開:2026/11/25 09:00 / 元情報の更新:2026/11/27 00:47(日本時間)
日本語訳
WordPress用プラグイン「WP STAGING – Backups & Restore, Migration & Clone Plugin – Cloud Backups, Scheduled Backups」は、4.17.0以下のすべてのバージョンで、REQUEST_URIクエリパラメータを介した認可回避の脆弱性があります。
原因はshowLoginForm()の解析方法の食い違いです。プラグインのisRestUrl()は、クエリ文字列を含むREQUEST_URI全体に対して、位置を先頭に固定しないstrpos()によるプレフィックス一致検索を行います。REST形式に見えるURLを検出すると、isStagingSite()やcurrent_user_can('manage_options')を含む認可チェックをすべて省略します。一方、WordPress本体がREST API呼び出しと扱うのは、rest_routeクエリ変数が空でない場合だけです。
認証されていない攻撃者は、/wp-json/?rest_route=のように空のrest_routeパラメータを付加し、ステージングサイトのログイン制限を完全に回避できます。プラグインが制限を省略する一方、WordPress本体は通常のテーマによるサイト表示を続けるため、ステージングサイトのテーマで描画される内容全体が露出します。非公開投稿の内容、ページビルダーの出力、WooCommerceのページ、ステージング側データベースのサイト内検索結果も含まれます。
この回避が影響するのは、ログイン制限が有効なステージングサイトだけです。プラグインで複製されたサイトでは、wpstg_is_staging_siteオプションがtrueか、ABSPATHに.wp-stagingマーカーファイルが存在する場合、ログイン制限が有効な状態がデフォルトです。
原文(英語)
WP STAGING <= 4.17.0 - Unauthenticated Authorization Bypass via 'rest_route' Query Parameter
The WP STAGING – Backups & Restore, Migration & Clone Plugin – Cloud Backups, Scheduled Backups plugin for WordPress is vulnerable to Authorization Bypass in all versions up to, and including, 4.17.0 via the `REQUEST_URI` query parameter. This is due to a parser-differential flaw in `showLoginForm()`: the plugin's `isRestUrl()` function performs an unanchored `strpos()` prefix match against the full `REQUEST_URI` — including the query string — and short-circuits all authorization checks (including `isStagingSite()` and `current_user_can('manage_options')`) whenever it detects a REST-like URL, while WordPress core only treats a request as a REST API call when the `rest_route` query variable is non-empty. This makes it possible for unauthenticated attackers to bypass the staging-site login gate entirely by appending an empty `rest_route` parameter (e.g. `/wp-json/?rest_route=`), causing the plugin to skip its gate while core proceeds to render the ordinary theme front end, exposing the full theme-rendered contents of the staging site — including private post content, page-builder output, WooCommerce pages, and site search results over the staging database. This bypass only affects staging sites where the login gate is active, which is the default state for any site cloned by the plugin when the `wpstg_is_staging_site` option is set to `true` or the `.wp-staging` marker file is present in `ABSPATH`.
引用元:Wordfence
確認と対応の進め方
WordPress管理画面の「プラグイン」→「インストール済みプラグイン」で、対象製品の名前とバージョンを確認してください。
影響バージョンに該当する場合は、バックアップを確認し、「ダッシュボード」→「更新」から対象製品を更新してください。更新後は、記事に記載した修正版になっていることと、サイトの表示・機能を確認してください。
更新が表示されない場合は、製品の提供元で更新情報と更新方法を確認してください。