Intel

AIKIDO-2026-808118

@descope/nextjs-sdk is vulnerable to Authentication Bypass

Authentication BypassGHSA-3j4q-2465-2m5r Published 2 days ago

91

Critical Risk

This Affects:

JS@descope/nextjs-sdk
0.0.1 - 0.15.55
Fixed in 0.15.56
Are you affected? Scan for Free

TL;DR

The session() and getSession(req) server helpers decode the client-supplied x-descope-session request header from Base64 and return it as trusted authentication data without validating the JWT signature. When this header is present it is returned before the cookie path that would call validateJwt, so signature verification is never reached. An unauthenticated request can forge arbitrary session claims, including user identity and roles such as admin, to bypass authentication in any route handler or server component that relies on these helpers. The fix removes the unvalidated header path so session data is only accepted after JWT validation.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and your application uses the session() or getSession(req) server helpers from @descope/nextjs-sdk/server to make authentication or authorization decisions.

Background info

@descope/nextjs-sdk is vulnerable to Authentication Bypass in versions 0.0.1 - 0.15.55.

How to fix this

Upgrade the @descope/nextjs-sdk library to the patch version.