Critical Next.js Security Flaw Exposes Millions to Attack; Urgent Patches Released

March 24, 2025
Critical Next.js Security Flaw Exposes Millions to Attack; Urgent Patches Released
  • Next.js middleware functions as a gatekeeper for user authentication and security, making this vulnerability particularly concerning for developers relying on it.

  • The flaw was reported by security researchers Rachid Allam and Yasser Allam, who provided technical details and emphasized the urgency for users to apply fixes immediately.

  • This incident underscores the importance of layered security measures and vigilance in security practices, as even minor coding oversights can lead to significant vulnerabilities.

  • NSFOCUS CERT reported the vulnerability and released details and proof of concept (PoC), urging users to take protective measures promptly.

  • Next.js, a widely used React framework developed by Vercel, has over 9 million weekly downloads and is popular among major companies like Netflix, TikTok, and Uber.

  • Recently, a critical security vulnerability tracked as CVE-2025-29927 was discovered in Next.js, allowing attackers to bypass authorization checks, which poses a significant risk to web applications.

  • Patches and temporary workarounds have been released, with users urged to update their systems to mitigate risks; those unable to patch should block requests containing the 'x-middleware-subrequest' header.

  • Next.js versions 12.3.5, 13.5.9, 14.2.25, and 15.2.3 have resolved the issue, while applications not using the 'middleware' command or hosted on Vercel or Netlify are unaffected.

  • Johannes Ullrich from the SANS Institute noted that this vulnerability allows a trivial authentication bypass, enabling unauthorized access to features intended for authorized users.

  • The security implications are severe, as the vulnerability allows complete authentication bypass, which could lead to unauthorized access to sensitive areas of websites.

  • Security researcher Rachid.A from Zhero Web Security provided an in-depth analysis of the issue, highlighting the potential risks for users.

  • In response to the vulnerability, Vercel has updated its documentation to provide clearer guidance on secure middleware usage.

Summary based on 11 sources


Get a daily email with more Tech stories

More Stories