9 Criticals in a Row — Mind Hacking on HackerOne
A Next.js middleware authentication bypass (CVE-2025-29927) allowed access to protected areas by sending a crafted header. The author used this to find and report nine critical vulnerabilities across private bug bounty programs.
medium.com
Published on medium.com
Hey world, this is rootplinix, aka Abu Hurayra — your friendly neighborhood hacker from Bangladesh. By day, I’m a bug bounty chaser; by night, I morph into a digital detective unraveling the secrets of the web.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely a flaw in how Next.js middleware handles a specific header, allowing an attacker to bypass authentication checks.
What the attacker needed
Target runs vulnerable Next.js version; Ability to send custom headers
How it was found
- Send a request with the X-Nextjs-Data header set to 1 and observe a 307 redirect.
- Add the X-Middleware-Subrequest header with a crafted value to bypass authentication.
- Use httpx to find live subdomains and inject the X-Nextjs-Data header.
- Use Webanalyze to detect Next.js versions and filter for vulnerable ones.
- Inject the payload into each target using Burp Suite Repeater and check for access.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
This is about a flaw in Next.js, a tool for building websites. A special header in a web request could trick the site into skipping its login check, letting someone see pages they shouldn't. The author found many sites with this flaw and reported them.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.