{"id":"CVE-2021-32702","published":"2021-06-25T16:25:11Z","modified":"2024-08-03T23:25:31Z","title":"Reflected XSS from the callback handler's error query parameter","vendor":"auth0","product":"nextjs-auth0","tier":"tail","description":{"text":"The Auth0 Next.js SDK is a library for implementing user authentication in Next.js applications. Versions before and including `1.4.1` are vulnerable to reflected XSS. An attacker can execute arbitrary code by providing an XSS payload in the `error` query parameter which is then processed by the callback handler as an error message. You are affected by this vulnerability if you are using `@auth0/nextjs-auth0` version `1.4.1` or lower **unless** you are using custom error handling that does not return the error message in an HTML response. Upgrade to version `1.4.1` to resolve. The fix adds basic HTML escaping to the error message and it should not impact your users.","provenance":"source","from":"CVE.org"},"cvss":{"score":8,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.01397,"percentile":0.73097,"provenance":"source"},"cwes":[{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation"}],"references":[{"url":"https://github.com/auth0/nextjs-auth0/security/advisories/GHSA-954c-jjx6-cxv7","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/auth0/nextjs-auth0/commit/6996e2528ceed98627caa28abafbc09e90163ccf","tags":["x_refsource_MISC"]},{"url":"https://www.npmjs.com/package/%40auth0/nextjs-auth0","tags":["x_refsource_MISC"]}],"priority":{"score":20.2,"factors":[{"name":"EPSS percentile","points":14.62},{"name":"CVSS severity","points":5.6}]},"vendorSlug":"auth0","affectedVersions":[{"vendor":"auth0","product":"nextjs-auth0","versions":["< 1.4.2"]}],"affected":[{"ecosystem":"npm","package":"@auth0/nextjs-auth0","vulnerableRanges":["<1.4.2"],"patched":["1.4.2"],"from":["GHSA-954c-jjx6-cxv7"],"provenance":"source"}],"summary":{"text":"The Auth0 Next.js SDK (nextjs-auth0, versions up to and including 1.4.1) contains a reflected cross-site scripting flaw in its callback handler, which processes the error query parameter and returns it in HTML without escaping. An attacker who can get a victim to open a crafted link can run script in the victim's browser, but only if the victim interacts with the page and the application uses the default error handling rather than custom handling that does not return the error message in an HTML response.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T07:14:32Z"},"euvd":{"id":"EUVD-2021-1297","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-auth0-nextjs-auth0-cve-2021-32702","children":[{"from":"CVE-2021-32702","to":"CVE-2021-43812","relation":"successor","confidence":"high","kind":"lineage","evidence":[{"kind":"version-step","provenance":"source","package":"npm:@auth0/nextjs-auth0","fromFixed":"1.4.2","toFixed":"1.6.2","daysApart":174},{"kind":"same-code","provenance":"machine","files":["src/handlers/login.ts"],"commits":["https://github.com/auth0/nextjs-auth0/commit/6996e2528ceed98627caa28abafbc09e90163ccf","https://github.com/auth0/nextjs-auth0/commit/0bbd9f8a0c93af51f607f28633b5fb18c5e48ad6"],"basis":"rarely changed file"}]}],"packageHistory":[{"cve":"CVE-2021-32702","published":"2021-06-25","fixed":"1.4.2","kev":false},{"cve":"CVE-2021-43812","published":"2021-12-16","fixed":"1.6.2","kev":false},{"cve":"CVE-2025-46344","published":"2025-04-29","fixed":"4.5.1","kev":false},{"cve":"CVE-2025-48947","published":"2025-06-04","fixed":"4.6.1","kev":false}],"package":"npm:@auth0/nextjs-auth0"}}