[Aikido] Fix 102 security issues in h3, lodash, lodash-es and 19 more - #78
Closed
aikido-autofix[bot] wants to merge 1 commit into
Closed
[Aikido] Fix 102 security issues in h3, lodash, lodash-es and 19 more#78aikido-autofix[bot] wants to merge 1 commit into
aikido-autofix[bot] wants to merge 1 commit into
Conversation
8 tasks
Author
|
Closed by Aikido: a new AutoFix has been created → #79 |
aikido-autofix
Bot
deleted the
fix/aikido-security-update-packages-101441870-7vmp
branch
September 3, 2026 00:55
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
Upgrade dependencies to fix critical RCE vulnerabilities in H3 (SSE injection), Lodash (code injection via template imports), Protobufjs (arbitrary code injection), and Seroval (prototype pollution and unsafe deserialization). This update includes breaking changes that require manual migration.
Motivation
Security Impact — CVE vulnerabilities fixed by this PR:
✅ 94 CVEs resolved by this upgrade, including 10 critical 🚨 CVEs
This PR will resolve the following CVEs:
serveStatic()via percent-encoded dot segments (%2e%2e) allows unauthenticated attackers to read arbitrary files outside the static directory on Node.js deployments. The vulnerability stems from insufficient path normalization before passing user-controlled paths to filesystem callbacks.protofield, enabling prototype chain manipulation and unintended property injection across the application.__proto__orconstructor, potentially influencing application behavior or enabling further attacks.__proto__,constructor, orprototypeinto internal objects, potentially modifying the prototype chain and influencing application behavior or enabling further attacks.DELETE/OPTIONSrequests allows attackers to bypass route restrictions and access unintended backend endpoints. An attacker could smuggle malicious requests to internal or admin routes through request boundary disagreement between proxy and backend.fetchcache keys are derived from lossy text decoding of request bodies, allowing distinct requests with different bodies to share cache entries and leak confidential response data between callers. The vulnerability affects the App Router and is fixed by keying the cache on raw body bytes instead.beforeInteractivescript serialization allows attackers to break script boundaries and execute arbitrary JavaScript in the browser (RCE).fetchresponses fails to account for request body differences, allowing unauthorized users to receive cached responses containing confidential data from other requests. This information disclosure vulnerability affects applications using the App Router.__proto__payloads in unsanitized user input, potentially leading to application logic bypass or information disclosure.Type of change (choose one)
Checklist
Check our Pull Request Guidelines
Breaking Changes & Upgrade Impact — prefer Warnings / Cautions /⚠️ sections over implementation sections (upgrade risks, breaking changes, manual migration steps):
@clerk/tanstack-react-start (0.26.10 => 1.4.20)
Where your code is affected:
ui/apps/dashboard/src/start.ts:1- UsesclerkMiddleware()ui/apps/support/src/start.ts:1- UsesclerkMiddleware()Multiple files using
useAuth(),signOut(), andgetToken()throughout both dashboard and support appsImpact:
clerkMiddlewarefunction signature change: The middleware no longer accepts individual props as functions. Code using prop function form (e.g.,domain: url => url.hostname) must migrate to options callback pattern (e.g.,clerkMiddleware(({ url }) => ({ domain: url.hostname }))). Currently both apps useclerkMiddleware()without arguments, so this is safe.getToken()behavior change: Now throwsClerkOfflineErrorinstead of returningnullwhen offline. This affects:ui/apps/dashboard/src/utils/useRestAPIRequest.ts:33- Callsawait getToken()without error handling for offline stateui/apps/dashboard/src/components/URQL/URQLProvider.tsx:48,56- Callsawait getToken({ skipCache: true })without offline error handlingui/apps/support/src/data/gqlApi.ts:4- Callsawait getToken()without offline error handlingui/apps/support/src/data/clerk.ts:5,21- Callsawait getToken()without offline error handlingui/apps/dashboard/src/queries/server/integrations/vercel.ts:8- Callsawait getToken()without offline error handlingui/apps/dashboard/src/queries/graphqlAPI.ts:6- Callsawait getToken()without offline error handlingui/apps/dashboard/src/lib/auth.ts:8- Callsawait getToken()without offline error handlingsignOut()withredirectUrlprop: The code usesredirectUrlin signOut calls:ui/apps/support/src/components/Navigation/ProfileMenu.tsx:30-signOut({ sessionId: session?.id, redirectUrl: "/sign-in/$" })ui/apps/dashboard/src/components/Auth/SignOutButton.tsx:20-signOut({ sessionId: session?.id, redirectUrl: '/sign-in/choose' })This is a deprecated legacy prop that may be removed in future versions.
Remediation:
Add try-catch blocks around all
getToken()calls to handleClerkOfflineErrorexceptionsConsider migrating from
redirectUrlto the new redirect pattern if documented in Clerk v4 migration guideReview and test all authentication flows after upgrade
@clerk/shared (3.36.0 => 4.25.5)
Where your code is affected:
The dashboard app uses
@clerk/sharedversion 3.44.0 (via@clerk/tanstack-react-start0.29.1)The support app uses
@clerk/sharedversion 3.36.0 (via@clerk/tanstack-react-start0.26.10)Impact:
Node.js version requirement increased from 18.17 to 20.9.0. The dashboard's
package.jsonspecifies"node": "20.x"which is compatible, but this needs verification for the support app and any CI/CD environments.Remediation:
Ensure all environments (local, CI/CD, production) use Node.js >= 20.9.0
Update any Node.js version specifications in deployment configurations
@opentelemetry/sdk-node & @opentelemetry/exporter-prometheus (0.208.0 => 0.217.0)
Where your code is affected:
pkg/telemetry/trace/tracer.go:318,334,350,366,424,476- Usestrace.NewBatchSpanProcessor(exp)andtrace.NewBatchSpanProcessor(exp, trace.WithBatchTimeout(...))Impact:
The
BatchSpanProcessorconstructor call signature changed in version 2.9.0 of the OpenTelemetry trace SDK. The code currently uses the old signaturetrace.NewBatchSpanProcessor(exporter, options...)but the new version requires an options object format:trace.NewBatchSpanProcessor({ exporter, ...options }).However, this appears to be for the JavaScript OpenTelemetry SDK (based on the changelog context), not the Go SDK. The Go code in this repository uses the Go OpenTelemetry SDK which has different versioning and APIs. This breaking change does NOT affect the Go code.
Remediation:
No action needed - this breaking change is for JavaScript/TypeScript OpenTelemetry SDK, not the Go SDK used in this codebase.
Node.js Version Requirements
Where your code is affected:
ui/apps/dashboard/package.json- Specifies"node": "20.x"Multiple package dependencies now require Node.js >= 18.18.0 or >= 20.9.0
Impact:
The Clerk v4 upgrade requires Node.js >= 20.9.0. The dashboard already specifies Node 20.x which is compatible, but the support app's package.json doesn't specify a Node version.
Remediation:
Add Node.js version specification to
ui/apps/support/package.json:"engines": { "node": "20.x" }Verify all deployment environments use Node.js >= 20.9.0
All breaking changes by upgrading lodash from version 4.17.21 to 4.18.1 (CHANGELOG)
_.unset/_.omitnow blockconstructorandprototypeas non-terminal path keys unconditionally. Calls that previously returnedtrueand deleted the property now returnfalseand leave the target untouched._.templatenow throws"Invalid imports option passed into _.template"whenimportskeys contain forbidden identifier characters, which were previously allowed.All breaking changes by upgrading lodash-es from version 4.17.21 to 4.18.1 (CHANGELOG)
_.unset/_.omit:constructorandprototypeare now blocked unconditionally as non-terminal path keys. Calls that previously returnedtrueand deleted the property now returnfalseand leave the target untouched._.template:importskeys containing forbidden identifier characters now throw"Invalid imports option passed into _.template"error, where previously they were accepted.All breaking changes by upgrading undici from version 7.16.0 to 7.29.0 (CHANGELOG)
All breaking changes by upgrading next from version 14.2.35 to 15.5.24 (CHANGELOG)
squooshin favor ofsharpas optional dependency for next/imageContent-Dispositiontoattachmentfor next/imagesrchas leading or trailing space in next/imagenext/headchildren reconciler by defaultgeoandipfromNextRequestnext lint"use server"and"use cache") at the same level will no longer be allowed.thisandargumentsin server functions: server functions can no longer usethisorarguments, which will break existing server functions that rely on these features.superin static class methods with server function directives: static class methods with server function directives cannot usesuper, breaking code that previously did so."use cache"is used withoutdynamicIOenabled: builds will now fail if"use cache"is used without enabling thedynamicIOflag.internal_disableSyncDynamicAPIWarningsflagcolorminfeature fromcssnanoexperimental.reactOwnerStackflagrootParams()is now a plain Promise (not exotic)--no-manglingCLI option fornext builddevIndicatorsoptionsappIsrStatusandbuildActivitydevIndicators.buildActivityPositionand renamed topositionoutput: exportis used with intercepting routesuseCacheis enabled and Edge runtime is usedrootParams()incachescopeforwardRefremoved from Link in App RouterlegacyBehaviorprop--turbopackflag withnext start, otherwise throws errorserver.mjsfor standalone withtype: moduleuseMDXComponentsargument removedexperimental.strictNextHeadremovedcookies&headersat runtime in Cache Componentsexperimental.dynamicIOrenamed toexperimental.cacheComponentsunstable_rootParamsdeprecated with warningAll breaking changes by upgrading @clerk/tanstack-react-start from version 0.26.10 to 1.4.20 (CHANGELOG)
clerkJSUrl,clerkJSVersion,clerkUIUrl, andclerkUIVersionprops from all SDKs. To pin a specific version of@clerk/clerk-js, import theClerkconstructor from@clerk/clerk-jsand pass it toClerkProvidervia theClerkprop. To pin a specific version of@clerk/ui, importuifrom@clerk/uiand pass it via theuiprop.<Protect>,<SignedIn>, and<SignedOut>components in favor of<Show when={...}>as the cross-framework authorization control componentgetToken()now throwsClerkOfflineErrorinstead of returningnullwhen the client is offlineuseAuth().getTokenis no longerundefinedduring server-side rendering, it is a function and calling it will throwinitialAuthStatetouseAuth. Instead pass ininitialStateto the<ClerkProvider>, ordynamicif using the Next packageclerkJSVariantoption and headless bundle. UseprefetchUI={false}insteadafterSign(In|Up)Url/redirectUrlprops,UserButtonsign-out overrides, organizationhideSlugflags,OrganizationSwitcher'safterSwitchOrganizationUrl,Client.activeSessions,setActive({ beforeEmit }), and theClerkMiddlewareAuthObjecttype aliassatelliteAutoSyncoption now defaults tofalse. Previously, satellite apps would automatically trigger a handshake redirect on every first page load; now this behavior requires explicitly settingsatelliteAutoSync: trueclerkMiddlewarefunction no longer accepts individual props as functions. Migrate from prop function form (e.g.,domain: url => url.hostname) to options callback pattern (e.g.,clerkMiddleware(({ url }) => ({ domain: url.hostname })))All breaking changes by upgrading uuid from version 9.0.1 to 13.0.2 (CHANGELOG)
All breaking changes by upgrading js-cookie from version 3.0.5 to 3.0.7 (CHANGELOG)
All breaking changes by upgrading form-data from version 4.0.4 to 4.0.6 (CHANGELOG)
"characters, which may change the behavior of code that previously relied on these characters being passed through unescaped.Note
High Risk
Major jumps on Clerk (0.x→1.x) and Next (14→15) in shared UI packages can break auth middleware and Storybook builds; overrides force h3/lodash globally and may surface latent compatibility issues after install.
Overview
This PR bumps direct dependencies across the UI monorepo and adds pnpm overrides at
ui/package.jsonto pull in patched transitive versions—lodash@4.18.1andnitro>h3at2.0.1-rc.15—addressing Lodash template/code-injection issues and h3 SSE/static-path vulnerabilities without waiting on upstream lockfile resolution alone.Dashboard pins
@clerk/tanstack-react-startto1.4.20(from^0.29.1), along with minor bumps to Segment analytics, Inngest,react-use, anduuid. Support aligns Clerk to the same1.4.20pin and upgrades TanStack Router/Start from 1.134.x to^1.158.1. Dev-server-ui bumps RTK Query’s GraphQL base query and moves GraphQL Codegen from v3-era packages to v6 CLI / v5 typescript plugins / v4 RTK-query plugin. Shared components upgradesnextto^15.5.24(from 14.x) andreact-use.There are no non-lockfile source edits in the diff; impact is install graph, build/codegen tooling, and runtime behavior of auth (Clerk v1), Storybook/Next in components, and Nitro/h3-backed SSR stacks.
Reviewed by Cursor Bugbot for commit 81e3258. Bugbot is set up for automated code reviews on this repo. Configure here.