Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:N/VA:N/SC:H/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
AC:H reflects the two required non-default conditions (no-trailing-slash publicPath and physical filesystem); PR:N because no authentication is required to the HTTP endpoint; C:H for sensitive file disclosure; I:N and A:N as exploitation is read-only.
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:N/VA:N/SC:H/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
Lifecycle Timeline
3Blast Radius
ecosystem impact- 4 npm packages depend on webpack-dev-middleware (3 direct, 1 indirect)
Ecosystem-wide dependent count for version 7.0.0.
DescriptionCVE.org
webpack-dev-middleware resolves a request to a local file in getFilenameFromUrl by testing the request pathname against a traversal guard and then slicing it at a fixed character offset. The guard, UP_PATH_REGEXP applied to path.normalize(./${pathname}), only matches ".." that stands as a whole path segment, while the containment test is the string comparison pathname.startsWith(publicPathPathname) and the file path is built as path.join(outputPath, pathname.slice(publicPathPathname.length)). When the configured publicPath has no trailing slash, a request such as GET /assets../.env against publicPath /assets yields the pathname /assets../.env, whose only dot-dot sits inside the segment "assets.." and so passes the guard, but the offset slice cuts within that segment and hands "../.env" to path.join, resolving one directory above outputPath. Reading a file from that path requires the middleware to be backed by the physical filesystem, which happens when writeToDisk is true or a custom outputFileSystem is supplied, since the default memfs volume holds only build output. Traversal depth is limited to a single directory because a separately delimited dot-dot segment is collapsed during URL parsing before the guard runs. The default publicPath value of "auto" resolves to "/" and is not affected. This is an incomplete fix for CVE-2024-29180: the guard and offset slice were introduced by that fix and are present in every release from 5.3.4, 6.1.2 and 7.1.0 onward.
AnalysisAI
Path traversal in webpack-dev-middleware bypasses the incomplete CVE-2024-29180 fix by embedding dot-dot sequences within path segments (e.g., 'assets..') rather than as standalone segments, causing the UP_PATH_REGEXP guard to pass while the subsequent fixed-offset slice produces a parent-directory component that resolves above outputPath on the physical filesystem. Affected versions are precisely 5.3.4+, 6.1.2+, and 7.1.0+ - the releases that introduced the original guard-and-slice logic intended to fix path traversal. …
Unlock full vulnerability intelligence
- Risk assessment & exploitation conditions
- Attack chain visualization
- Remediation with exact patch versions
- Threat intelligence from 22 sources
- Personal watchlist & email alerts
Free forever · No credit card required
Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata
Vulnerability AssessmentAI
| Exploitation | Exploitation requires two simultaneous non-default configuration conditions: (1) publicPath must be configured WITHOUT a trailing slash - for example '/assets' rather than '/assets/' or the default 'auto' (which resolves to '/' and is explicitly not affected); (2) the middleware must use the physical filesystem, which occurs only when devMiddleware.writeToDisk is set to true, or when a custom outputFileSystem backed by real disk storage is supplied - the default in-memory memfs volume is not vulnerable. … Additional conditions and limiting factors are described in the full assessment. |
| Risk Assessment | The CVSS 4.0 score of 8.3 with VC:H and SC:H accurately reflects the confidentiality severity of file disclosure but overstates exploitability for typical deployments, because two non-default conditions must be simultaneously present: a publicPath configured without a trailing slash and physical filesystem access via writeToDisk or custom outputFileSystem. … Full risk analysis with EPSS, KEV, and SSVC signal comparison available after sign-in. |
| Exploit Scenario | An attacker with network access to a development server where publicPath is '/assets' (no trailing slash) and writeToDisk is true sends the crafted request GET /assets../.env HTTP/1.1. The UP_PATH_REGEXP guard passes because 'assets..' is not a standalone '..' path segment; the fixed-offset slice produces '../.env'; and path.join resolves this to one level above outputPath, returning the contents of the .env file containing environment secrets. … |
| Remediation | Upgrade webpack-dev-middleware to v8.1.1 or later, where the path construction logic is corrected per patch commits https://github.com/webpack/webpack-dev-middleware/commit/189c4ac7d2344ec132a4689e74dc837ec5be0132 and https://github.com/webpack/webpack-dev-middleware/commit/9670b3495da518fe667ff3428c5e4cb9f2f3d353; note that no formal vendor-published advisory with an explicit fixed-version table has been independently verified beyond the v8.1.1 source reference. … Detailed patch versions, workarounds, and compensating controls in full report. |
Recommended ActionAI
Within 24 hours, audit all webpack-dev-middleware deployments across development and CI/CD infrastructure to identify instances running versions 5.3.4 through 5.x, 6.1.2 through 6.x, or 7.1.0 and later with writeToDisk enabled and publicPath lacking a trailing slash. …
Sign in for detailed remediation steps and compensating controls.
Threat intelligence, references, and detailed analysis are available after sign-in.
More in Webpack Dev Middleware
View allSame weakness CWE-22 – Path Traversal
View allSame technique Path Traversal
View allShare
External POC / Exploit Code
Leaving vuln.today
EUVD-2026-64850
GHSA-p3f5-w63m-mxph