Default redirect callback vulnerable to open redirects
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- Required
- Attack complexity
- High
- Impact type
- Security bypass, Spoofing
- Confidentiality · integrity · availability
- High · None · None
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub. Impact type from CWE-290 and CWE-601.
Summary
next-auth v3 users before version 3.29.2 are impacted. next-auth version 4 users before version 4.3.2 are also impacted. Upgrading to 3.29.2 or 4.3.2 will patch this vulnerability. If you are not able to upgrade for any reason, you can add a configuration to your callbacks option. If you already have a `redirect` callback, make sure that you match the incoming `url` origin against the `baseUrl`.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| nextauthjs | next-auth | < 3.29.2, < 4.3.2 | — | No fix listed | CNA |
| — | next-auth (npm) | before 3.29.2 | 3.29.2 | Patch available | GHSA-f9wg-5f46-cjmw |
| — | next-auth (npm) | 4.0.0 to before 4.3.2 | 4.3.2 | Patch available | GHSA-f9wg-5f46-cjmw |
- next-auth Vendornextauthjs Affected < 3.29.2, < 4.3.2 Fixed in — No fix listed CNA
- next-auth (npm) Vendor— Affected before 3.29.2 Fixed in 3.29.2 Patch available GHSA-f9wg-5f46-cjmw
- next-auth (npm) Vendor— Affected 4.0.0 to before 4.3.2 Fixed in 4.3.2 Patch available GHSA-f9wg-5f46-cjmw
CPE configurations NVD · 1
| CPE | Versions | Role | Vendor |
|---|---|---|---|
| cpe:2.3:a:nextauth.js:next-auth:*:*:*:*:*:node.js:*:* | 3.0.0 to before 3.29.2; 4.0.0 to before 4.3.2 | Vulnerable | nextauthjs |
- cpe:2.3:a:nextauth.js:next-auth:*:*:*:*:*:node.js:*:* Versions 3.0.0 to before 3.29.2; 4.0.0 to before 4.3.2 Vulnerable ·nextauthjs
Remediation
- Fix · GHSA-f9wg-5f46-cjmw next-auth (npm) Fixed in 3.29.2 Advisory →
- Fix · GHSA-f9wg-5f46-cjmw next-auth (npm) Fixed in 4.3.2 Advisory →
Timeline
- 2026-10-02 Threatist record created from CVE-2022-24858
- 2026-10-03 Alias added: GHSA-f9wg-5f46-cjmw
References
Advisory 4
More nextauthjs Next-auth vulnerabilities
- TI-2022-13171 Improper handling of email input in next-auth CVSS 3.1HIGH 7.1
- TI-2022-16351 Verification requests (magic link) sent to unwanted emails CVSS 3.1CRITICAL 9.1
- TI-2022-13137 Improper Handling of `callbackUrl` parameter in next-auth CVSS 3.1HIGH 7.5
- TI-2023-12218 Missing proper state, nonce and PKCE checks for OAuth authentication in next-auth CVSS 3.1HIGH 8.8
- TI-2022-18639 NextAuth.js Upstash Adapter missing token verification CVSS 3.1HIGH 8.1
- TI-2023-26172 next-auth vulnerable to possible user mocking that bypasses basic authentication CVSS 3.1MEDIUM 5.3
Sources
- CVE-2022-24858 · CVE Program
- CVE-2022-24858 · NVD
- FIRST EPSS
- GHSA-f9wg-5f46-cjmw · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences