Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-94543 Overview
CVE-2026-94543 is a cache key confusion vulnerability in Next.js, the React framework maintained by Vercel for building full-stack web applications. The flaw affects self-hosted applications using the Pages Router with Static Site Generation (SSG) or Incremental Static Regeneration (ISR). Affected deployments can key a response cache entry without sufficiently binding it to the source route. An attacker can replace one page's cache entry with content from a different route, causing the affected page to serve incorrect content to every visitor until revalidation. The issue affects versions 15.0.0 through 15.5.26 and 16.0.0 through 16.3.7. Applications deployed on Vercel are not affected.
Critical Impact
Self-hosted Next.js sites can serve attacker-controlled or wrong-route content to all visitors through a poisoned shared response cache entry until revalidation occurs.
Affected Products
- Vercel Next.js 15.0.0 through 15.5.26 (self-hosted, Pages Router with SSG/ISR)
- Vercel Next.js 16.0.0 through 16.3.7 (self-hosted, Pages Router with SSG/ISR)
- Not affected: Applications deployed on Vercel infrastructure
Discovery Timeline
- 2026-10-02 - CVE-2026-94543 published to the National Vulnerability Database (NVD)
- 2026-10-06 - Last updated in NVD database
- Patch released - Fixed in Next.js 15.5.27 and 16.3.8
Technical Details for CVE-2026-94543
Vulnerability Analysis
The vulnerability is categorized under [CWE-524: Use of Cache Containing Sensitive Information] and manifests as a cache key confusion issue. Next.js maintains a response cache for pages generated through SSG and ISR in the Pages Router. The cache key used to store rendered responses does not sufficiently bind the entry to the originating route.
As a result, a request processed under one route path can write a cache entry that another route later reads. Subsequent visitors to the affected page receive content rendered for a different route. The incorrect response persists until the next revalidation cycle, affecting every visitor during that window.
The scope is limited to self-hosted deployments. Vercel's hosting layer uses a separate caching stack and is not vulnerable. The attack requires specific conditions and does not grant code execution, but it undermines content integrity and can be used to serve misleading or malicious content under a trusted route.
Root Cause
The root cause is insufficient scoping of response cache keys. The response cache logic treated keys as route-agnostic in certain code paths, allowing an entry generated for route A to satisfy a lookup for route B. The patch introduces a dedicated route-cache-key module and a getRouteCacheKey helper, along with an isRouteCacheOwner check used during app-page runtime rendering. These additions bind each cache entry to its source route and prevent cross-route reuse.
Attack Vector
Exploitation requires network access to the self-hosted application and the ability to trigger cache population for routes that use SSG or ISR. The attacker crafts requests that cause the response cache to persist content under a key that another route resolves. No authentication or user interaction is required, though attack complexity is high because the attacker must align request shaping with cache internals.
// Patch excerpt: packages/next/src/build/collect-build-traces.ts
// Scope response cache keys to their source route
import { defaultOverrides } from '../server/require-hook'
import { nodeFileTrace } from 'next/dist/compiled/@vercel/nft'
import { normalizePagePath } from '../shared/lib/page-path/normalize-page-path'
-import { normalizeAppPath } from '../shared/lib/router/utils/app-paths'
+import {
+ normalizeAppPath,
+ selectAppPageEntry,
+} from '../shared/lib/router/utils/app-paths'
import isError from '../lib/is-error'
// Patch excerpt: packages/next/src/build/index.ts
+import {
+ getRouteCacheKey,
+ ROUTE_CACHE_DIRECTORY,
+} from '../server/lib/route-cache-key'
+import { RouteKind } from '../server/route-kind'
// Patch excerpt: packages/next/src/build/templates/app-page-runtime.ts
+import { isRouteCacheOwner } from '../../server/lib/route-cache-key'
+ with { 'turbopack-transition': 'next-server-utility' }
Source: Next.js commit 52c94ab and Next.js commit 719e4c6
Detection Methods for CVE-2026-94543
Indicators of Compromise
- Static or ISR-cached pages serving content that belongs to a different route path.
- Unexpected x-nextjs-cache HIT responses returning the body of an unrelated page.
- Error reports from users describing wrong page content on a known-good URL that resolves after revalidation.
- Divergence between the HTML served and the expected template defined in pages/.
Detection Strategies
- Compare rendered HTML of SSG and ISR routes against known canonical hashes to flag mismatches.
- Audit application logs for cache lookups and populations that reference inconsistent route identifiers.
- Run synthetic monitoring that fetches each cached route and validates route-specific markers in the response body.
Monitoring Recommendations
- Enable verbose logging around the Next.js response cache during triage and record cache keys with originating route paths.
- Monitor CDN or reverse-proxy logs for anomalous request patterns targeting SSG or ISR endpoints with crafted headers or paths.
- Track revalidation events and alert on cache entries that change content fingerprint without a corresponding deployment or data change.
How to Mitigate CVE-2026-94543
Immediate Actions Required
- Upgrade self-hosted Next.js to 15.5.27 or 16.3.8 as soon as possible.
- Inventory all self-hosted Next.js deployments to confirm whether they use the Pages Router with SSG or ISR.
- Purge the response cache after upgrading to remove any entries created under the vulnerable keying logic.
- Review access logs for suspicious request patterns against SSG and ISR routes prior to the upgrade.
Patch Information
Vercel released fixes in Next.js 15.5.27 and 16.3.8. The patches scope response cache keys to their source route via a new route-cache-key module, getRouteCacheKey helper, and isRouteCacheOwner runtime check. See the GitHub Security Advisory GHSA-4jqv-mc3x-m676, the Next.js v15.5.27 release, and the Next.js v16.3.8 release.
Workarounds
- Migrate affected routes from the Pages Router to the App Router where feasible, as the issue is specific to Pages Router SSG and ISR.
- Disable ISR and SSG on sensitive routes and switch to Server-Side Rendering (SSR) until the patch is applied.
- Deploy on Vercel infrastructure, which is not affected by this issue.
- Place a validating CDN or reverse proxy in front of the application to enforce per-route cache keys based on the full request path.
# Upgrade self-hosted Next.js to a patched release
npm install next@15.5.27
# or
npm install next@16.3.8
# Verify installed version
npx next --version
# Clear the build and cache artifacts before redeploying
rm -rf .next
npm run build
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

