Skip to content
KitploitKITPLOIT
ToolsBlog
Submit
ToolsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

··Feeds·Contact·Privacy·© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
ghost-route — Python-based scanner that detects CVE-2025-29927 middleware bypass vulnerability in Next.js sites by sending a crafted x-middleware-subrequest header to protected paths. | Kitploit
Tools/GitHubGitHub/phoscoder/ghost-route
Vulnerability ScannersWeb SecurityLearning & Education
GitHubphoscoder/ghost-route

ghost-route

Python-based scanner that detects CVE-2025-29927 middleware bypass vulnerability in Next.js sites by sending a crafted x-middleware-subrequest header to protected paths.

View Repository
91 year agoNot yet reviewed

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share

👻 Ghost Route

Logo

A Python script to check Next.js sites for corrupt middleware vulnerability (CVE-2025-29927).

The corrupt middleware vulnerability allows an attacker to bypass authentication and access protected routes by send a custom header x-middleware-subrequest.

Next JS versions affected:

  • 11.1.4 and up

[!WARNING] This tool is for educational purposes only. Do not use it on websites or systems you do not own or have explicit permission to test. Unauthorized testing may be illegal and unethical.

Installation

Clone the repo

root@kitploit:~
git clone https://github.com/takumade/ghost-route.git
cd ghost-route

Create and activate virtual environment

root@kitploit:~
python -m venv .venv
source .venv/bin/activate

Install dependencies

root@kitploit:~
pip install -r requirements.txt

Usage

root@kitploit:~
python ghost-route.py <url> <path> <show_headers>
  • <url>: Base URL of the Next.js site (e.g., https://example.com)
  • <path>: Protected path to test (default: /admin)
  • <show_headers>: Show response headers (default: False)

Example

Basic Example

root@kitploit:~
python ghost-route.py https://example.com /admin

Show Response Headers

root@kitploit:~
python ghost-route.py https://example.com /admin True

License

MIT License

Credits

  • CVE-2025-29927
  • Next.js and the corrupt middleware: the authorizing artifact
  • Rachid A.
  • Yasser Allam
Download Tool