Exploit databaseDownload repository ZIP
GH-0d9fd1ddf646006a26be68494daab7af
adjscent/vulnerable-nextjs-14-cve-2025-29927
Sources for CVE-2025-29927
158 sourcesPreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source
Repository files8
adjscent/vulnerable-nextjs-14-cve-2025-29927Revision c3ed51431f1e
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
middleware.js
Suggested starting fileJavaScript · 430 bytesimport { NextResponse } from "next/server";
export function middleware(req) {
const authHeader = req.headers.get("authorization");
if (!authHeader || authHeader !== "my-jwt-token-here") {
return NextResponse.json(
{
error: "Unauthorized",
},
{ status: 401 }
);
}
return NextResponse.next();
}
// Apply middleware to all API routes
export const config = {
matcher: "/api/:path*",
};