This repository has been archived by the owner on Jan 19, 2024. It is now read-only.
fix(deps): update dependency next-auth to v4.5.0 [SECURITY] #212
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
4.3.4
->4.5.0
GitHub Vulnerability Alerts
CVE-2022-31093
Impact
An attacker can send a request to an app using NextAuth.js with an invalid
callbackUrl
query parameter, which internally we convert to aURL
object. The URL instantiation would fail due to a malformed URL being passed into the constructor, causing it to throw an unhandled error which led to our API route handler timing out and logging in to fail. This has been remedied in the following releases:next-auth v3 users before version 3.29.5 are impacted. (We recommend upgrading to v4, as v3 is considered unmaintained. See our migration guide)
next-auth v4 users before version 4.5.0 are impacted.
Patches
We've released patches for this vulnerability in:
3.29.5
4.5.0
You can do:
or
or
(This will update to the latest v4 version, but you can change
latest
to3
if you want to stay on v3. This is not recommended.)Workarounds
If for some reason you cannot upgrade, the workaround requires you to rely on Advanced Initialization. Here is an example:
Before:
After:
References
This vulnerability was discovered not long after GHSA-q2mx-j4x2-2h74 was published and is very similar in nature.
Related documentation:
A test case has been added so this kind of issue will be checked before publishing. See: nextauthjs/next-auth@e498483
For more information
If you have any concerns, we request responsible disclosure, outlined here: https://next-auth.js.org/security#reporting-a-vulnerability
Timeline
The issue was reported 2022 June 10th, a response was sent out to the reporter in less than 2 hours, and a patch was published within 3 hours.
Release Notes
nextauthjs/next-auth
v4.5.0
Compare Source
Bugfixes
v4.4.0
Compare Source
Features
4daa63d
)cookieName
(#4385) (7d8cc70
)jwt.decode
(#4210) (16622f6
)81afeef
)issuer
configurable on Salesforce (#4658) (358b80d
)Bugfixes
callbackUrl
(#4534) (75602a3
)getToken
ingetServerSideProps
(#4659) (e4ee520
)0a7a916
)46089eb
)callbackUrl
Other
0b953bd
)Configuration
📅 Schedule: Branch creation - "" in timezone Europe/Paris, Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.