Update dependency @clerk/nextjs to v4.29.3 [SECURITY]#75
Conversation
9398604 to
47ef87d
Compare
|
Important Review skippedBot user detected. To trigger a single review, invoke the You can disable this status message by setting the Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
47ef87d to
6c468ec
Compare
This PR contains the following updates:
4.25.5→4.29.3@clerk/nextjs auth() and getAuth() methods vulnerable to insecure direct object reference (IDOR)
CVE-2024-22206 / GHSA-q6w5-jg5q-47vg
More information
Details
Impact
Unauthorized access or privilege escalation due to a logic flaw in
auth()in the App Router orgetAuth()in the Pages Router.Affected Versions
All applications that that use
@clerk/nextjsversions in the range of>= 4.7.0,< 4.29.3in a Next.js backend to authenticate API Routes, App Router, or Route handlers. Specifically, those that callauth()in the App Router orgetAuth()in the Pages Router. Only the@clerk/nextjsSDK is impacted. Other SDKs, including other Javascript-based SDKs, are not impacted.Patches
Fix included in
@clerk/nextjs@4.29.3.References
Severity
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:HReferences
This data is provided by the GitHub Advisory Database (CC-BY 4.0).
Release Notes
clerk/javascript (@clerk/nextjs)
v4.29.3Compare Source
Patch Changes
Replace the
Clerk-Backend-SDKheader withUser-Agentin BAPI requests and update it's value to contain both the package name and the package version of the clerk package (#2579) by @nikosdouvlisexecuting the request. Eg request from
@clerk/nextjsto BAPI with appendUser-Agent: @​clerk/nextjs@5.0.0-alpha-v5.16using the latest version.Miscellaneous changes: The backend test build changed to use tsup.
Updated dependencies [
c59a2d4a2,2a615bf98]:v4.29.2Compare Source
Patch Changes
71b4b9ca2,65332d744]:v4.29.1Compare Source
Patch Changes
3ece3f80f,6c64c9bbc,0bf0bdd56]:v4.29.0Compare Source
Minor Changes
__clerk_db_jwtand__dev_sessionthe dev browser jwt in development (#2428) by @dimklPatch Changes
df40705d3,a8feab74a]:v4.28.1Compare Source
Patch Changes
v4.28.0Compare Source
Minor Changes
Introduce Protect for authorization. (#2309) by @panteliselef
Changes in public APIs:
experimentaltags and prefixessomefrom thehasutility and Protect. Protect now accepts aconditionprop where a function is expected with thehasbeing exposed as the param.<SignedIn>, if no authorization props are passed.haswill throw an error if neitherpermissionorroleis passed.auth().protect()for Nextjs App Router. Allow per page protection in app router. This utility will automatically throw a 404 error if user is not authorized or authenticated.not-foundcomponent set by the developerPatch Changes
Accept
redirectUrlas an option forauth().protect(). (#2333) by @panteliselefFor example:
Updated dependencies [
b4868ab8f,2dc93d4d8]:v4.27.7Compare Source
Patch Changes
Use dynamic imports in
<ClerkProvider />which you import from@clerk/nextjs. (#2292) by @LekoArtsUsers on Next.js 12 and older can run into errors like these:
The aforementioned
<ClerkProvider />component contains code for both Next.js 12 (+ older) and Next.js 13 (+ newer). On older versions it can't find the imports only available in newer versions.If you're seeing these errors, you have to do two things:
Update
@clerk/nextjsto this versionUpdate your
next.config.jsto ignore these imports:It is safe to ignore these modules as your Next.js 12 app won't hit these code paths.
v4.27.6Compare Source
Patch Changes
a62479810]:v4.27.5Compare Source
Patch Changes
31ee1438a,7ef3414ba,c7763fa60,12b362923]:v4.27.4Compare Source
Patch Changes
Drop the introduction of
OrganizationRoleandOrganizationPermissionresources fro BAPI. (#2257) by @panteliselefEnsure that cookies set inside Next.js Middleware are correctly passed through while using
authMiddleware. (#2260) by @clerk-cookieUpdated dependencies [
11fdbcb39]:v4.27.3Compare Source
Patch Changes
7130db0fb]:v4.27.2Compare Source
Patch Changes
Add OrganizationPermissionAPI for CRUD operations regarding instance level organization permissions. (#2185) by @panteliselef
Updated dependencies [
aaaf24a55,e41374abf,e41374abf,e61df051c,9d8a29b8e]:v4.27.1Compare Source
Patch Changes
1df2ffe77]:v4.27.0Compare Source
Minor Changes
<Gate/>with role checks. (#2051) by @panteliselefPatch Changes
Fix type inferance for auth helper. (#2049) by @panteliselef
Updated dependencies [
7fa8fbcf2,068a9025c,4c3429010,d7fe11ede,20eab8365,f9d1bc758,f652a5618,4f9214aca]:v4.26.2Compare Source
Patch Changes
Deprecate
user,session, andorganizationresources from the returned value ofauth(). (#1960) by @panteliselefImports
deprecatedObjectPropertyfrom@clerk/sharedas subpath. (#1989) by @clerk-cookieUpdated dependencies [
f6f67f9ab,a8d7a687e,7b91aca54,0f8aedd62,bc19fe025,60ea712fa]:v4.26.1Compare Source
Patch Changes
29a5f5641]:v4.26.0Compare Source
Minor Changes
Patch Changes
088724324,5d379bcbf]:v4.25.7Compare Source
Patch Changes
Fix an issue where only static routes would be allowed by
publicRoutesprop fromauthMiddleware. (#1928) by @desiprisgPublish packages with npm provenance enabled (#1891) by @LekoArts
Update
<ClerkProvider />to work in client components within the app router. This allows rendering of the provider in client components, previously the pages router provider was being imported and throwing an error. (#1840) by @BRKalowUpdate imports of
@clerk/sharedto granular entrypoints. This addresses warnings during a Next.js build that are the result of unsupported APIs being included in the module graph of builds for the edge runtime. (#1924) by @BRKalowUpdated dependencies [
3bf64107e,52f8553d2,92727eec3,b09b66eec,51861addf,37d8856ba,aa4cd7615]:v4.25.6Compare Source
Patch Changes
Update the error thrown by auth() or getAuth() to indicate that if the /src directory exists, then the middleware.ts file needs to be placed inside it, otherwise the middleware will not run. (#1908) by @nikosdouvlis
Updated dependencies [
9ca215702]:Configuration
📅 Schedule: (UTC)
🚦 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 was generated by Mend Renovate. View the repository job log.