{"id":"CVE-2022-39263","published":"2022-09-28T21:05:09Z","modified":"2025-04-23T16:54:22Z","title":"NextAuth.js Upstash Adapter missing token verification","vendor":"nextauthjs","product":"next-auth","tier":"tail","description":{"text":"`@next-auth/upstash-redis-adapter` is the Upstash Redis adapter for NextAuth.js, which provides authentication for Next.js. Applications that use `next-auth` Email Provider and `@next-auth/upstash-redis-adapter` before v3.0.2 are affected by this vulnerability. The Upstash Redis adapter implementation did not check for both the identifier (email) and the token, but only checking for the identifier when verifying the token in the email callback flow. An attacker who knows about the victim's email could easily sign in as the victim, given the attacker also knows about the verification token's expired duration. The vulnerability is patched in v3.0.2. A workaround is available. Using Advanced Initialization, developers can check the requests and compare the query's token and identifier before proceeding.","provenance":"source","from":"CVE.org"},"cvss":{"score":6.8,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00737,"percentile":0.55442,"provenance":"source"},"cwes":[{"id":"CWE-287","name":"Improper Authentication"}],"references":[{"url":"https://github.com/nextauthjs/next-auth/security/advisories/GHSA-4rxr-27mm-mxq9","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/nextauthjs/next-auth/commit/d16e04848ee703cf797724194d4ad2907fe125a9","tags":["x_refsource_MISC"]}],"priority":{"score":15.8,"factors":[{"name":"EPSS percentile","points":11.09},{"name":"CVSS severity","points":4.76}]},"vendorSlug":"nextauthjs","affectedVersions":[{"vendor":"nextauthjs","product":"next-auth","versions":["< 3.0.2"]}],"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"total","timestamp":"2025-04-23T15:48:44.642001Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"npm","package":"@next-auth/upstash-redis-adapter","vulnerableRanges":["<3.0.2"],"patched":["3.0.2"],"from":["GHSA-4rxr-27mm-mxq9"],"provenance":"source"}],"summary":{"text":"The NextAuth.js Upstash Redis Adapter (@next-auth/upstash-redis-adapter, used with the next-auth Email Provider) fails to verify the verification token during the email callback, checking only the email identifier. An unauthenticated remote attacker who knows a victim's email address and the token's expiry window can sign in as that victim, but only with user interaction and under high attack complexity.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:28:34Z"},"euvd":{"id":"EUVD-2022-6695","exploited":false,"provenance":"source"}}