CVE-2023-48309
Last modified
CVE-2023-48309 is a medium-severity vulnerability rated 5.3/10 on the CVSS scale. NextAuth.js provides authentication for Next.js. `next-auth` applications prior to version 4.24.5 that rely on the default Middleware authorization are affected by a vulnerability. EPSS estimates a 0.70% chance of exploitation in the next 30 days.
Description
NextAuth.js provides authentication for Next.js. `next-auth` applications prior to version 4.24.5 that rely on the default Middleware authorization are affected by a vulnerability. A bad actor could create an empty/mock user, by getting hold of a NextAuth.js-issued JWT from an interrupted OAuth sign-in flow (state, PKCE or nonce). Manually overriding the `next-auth.session-token` cookie value with this non-related JWT would let the user simulate a logged in user, albeit having no user information associated with it. (The only property on this user is an opaque randomly generated string). This vulnerability does not give access to other users' data, neither to resources that require proper authorization via scopes or other means. The created mock user has no information associated with it (ie. no name, email, access_token, etc.) This vulnerability can be exploited by bad actors to peek at logged in user states (e.g. dashboard layout). `next-auth` `v4.24.5` contains a patch for the vulnerability. As a workaround, using a custom authorization callback for Middleware, developers can manually do a basic authentication.
Metrics
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N
Weakness Enumeration
Affected Software
| Vendor | Product | Versions |
|---|---|---|
| Nextauth.Js | Next-Auth | < 4.24.5 |
References
- https://authjs.dev/guides/basics/role-based-access-controlTechnical Description
- https://next-auth.js.org/configuration/nextjs#advanced-usageTechnical Description
- https://next-auth.js.org/configuration/nextjs#middlewarTechnical Description
- https://authjs.dev/guides/basics/role-based-access-controlTechnical Description
- https://next-auth.js.org/configuration/nextjs#advanced-usageTechnical Description
- https://next-auth.js.org/configuration/nextjs#middlewarTechnical Description
Timeline
- Published
- Last Modified
- Status
- Modified
Frequently Asked Questions
What is CVE-2023-48309?
How severe is CVE-2023-48309?
How do I fix CVE-2023-48309?
How Strix Helps
- Uncovering a hidden BOLA in Appsmith's snapshot logicStrix autonomously discovered a BOLA/IDOR vulnerability in Appsmith's snapshot deletion path.
- Autonomous PentestingAI agents that find and validate exploitable vulnerabilities like this one across your applications.
- PR ReviewsPentest every pull request so vulnerable code is caught before it ships to production.
- AI Penetration TestingHow AI-driven penetration testing continuously covers your attack surface.
Related CVEs from 2023
- CVE-2023-48303Nextcloud Server provides data storage for Nextcloud, an ope…2.7
- CVE-2023-48304Nextcloud Server provides data storage for Nextcloud, an ope…4.3
- CVE-2023-48305Nextcloud Server provides data storage for Nextcloud, an ope…4.4
- CVE-2023-48306Nextcloud Server provides data storage for Nextcloud, an ope…9.8
- CVE-2023-48307Nextcloud Mail is the mail app for Nextcloud, a self-hosted …9.8
- CVE-2023-48308Nextcloud/Cloud is a calendar app for Nextcloud. An attacker…6.5
- CVE-2023-4831Improper Neutralization of Special Elements used in an SQL C…9.8
- CVE-2023-48310TestingPlatform is a testing platform for Internet Security …7.5
- CVE-2023-48311dockerspawner is a tool to spawn JupyterHub single user serv…4.3
- CVE-2023-48312capsule-proxy is a reverse proxy for the capsule operator pr…9.8
- CVE-2023-48313Umbraco is an ASP.NET content management system (CMS). Star…6.1
- CVE-2023-48314Collabora Online is a collaborative online office suite base…6.1
Are you affected by CVE-2023-48309?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
