Next.js / React
Next.js / React exploit
Find All Paths
Dev Tools - Console:
console.log(__BUILD_MANIFEST.sortedPages)
javascript:console.log(__BUILD_MANIFEST.sortedPages.join('\n'));React2Shell / NextRCE
CVE-2025-55182:
Safe probe for Flight parser error with Curl and without harmful execution.
Indicators of vulnerability:
Response Code = 500
Word "digest" appears in response body
Nuclei Template:
RCE PoC:

Prototype Pollution
ppmap:
SSRF
Header Injection
CVE-2025-49826 - CPDos
Version < 15.1.8
Detected with HExHTTP
CVE-2025-29927: Next.js Middleware Bypass
All versions before 14.2.25 and 15.2.3
Next.js 15.x should upgrade to 15.2.3
Next.js 14.x should upgrade to 14.2.25
Next.js 13.x should upgrade to 13.5.9
Next.js 12.x should upgrade to 12.3.5
add the extra HTTP header x-middleware-subrequest: middleware
You can also try the header x-middleware-subrequest: src/middleware:src/middleware:src/middleware:src/middleware:src/middleware if the previous payload doesn't work
Cache Poisoning
DoS - Empty page
Add the x-middleware-prefetch header results in an empty JSON object {} as a response. If a CDN or caching system is present, this empty response can potentially be cached —depending on the cache rules configuration— rendering the targeted page impractical and its content inaccessible.

Display RSC Payload

Rsc: 1— was added to the cache-key via the Vary response header
DoS
Include x-invoke-status: 888 as a header


Cache poisoning via race-condition
Cache Poisoning to XSS - CVE-2024-46982
To be potentially affected all of the following must apply:
Next.js between 13.5.1 and 14.2.9
Using pages router
Using non-dynamic server-side rendered routes e.g.
pages/dashboard.tsxnotpages/blog/[slug].tsx
CVE-2024-34351
SSRF - Fixed in v14.1.1.
SSRFCVE-2024-51479
Interesting Books
Interesting BooksThe Web Application Hacker’s Handbook The go-to manual for web app pentesters. Covers XSS, SQLi, logic flaws, and more
Bug Bounty Bootcamp: The Guide to Finding and Reporting Web Vulnerabilities Learn how to perform reconnaissance on a target, how to identify vulnerabilities, and how to exploit them
Real-World Bug Hunting: A Field Guide to Web Hacking Learn about the most common types of bugs like cross-site scripting, insecure direct object references, and server-side request forgery.
Support this Gitbook
I hope it helps you as much as it has helped me. If you can support me in any way, I would deeply appreciate it.
Last updated


