CVE-2026-6402
webpack-dev-server vulnerable to cross-origin source code exposure on non-HTTPS origins
webpack-dev-server versions up to and including 5.2.3 are vulnerable to cross-origin source code exposure when serving over a non-potentially trustworthy origin such as plain HTTP. The previous fix relied on the Sec-Fetch-Mode and Sec-Fetch-Site request headers, which browsers omit for non-trustworthy origins, allowing a malicious site to load the bundled source as a script and read it across origins. Impact: an attacker controlling a website visited by a developer running webpack-dev-server can recover the application source code when the dev server runs over HTTP at a guessable host and port. Chromium based browsers from Chrome 142 onward are not affected due to local network access restrictions. Upgrade to webpack-dev-server 5.2.4 or later, which sets Cross-Origin-Resource-Policy: same-origin on responses.
Attack profile
How easy it is to exploit
- Attack vector
- Network
- Complexity
- High
- Privileges needed
- None
- User interaction
- Required
What an attacker can affect
- Confidentiality
- High
- Integrity
- None
- Availability
- None
Exploit likelihood
What each source reports
CVE List Score used
5.3
webpack-dev-server vulnerable to cross-origin source code exposure on non-HTTPS origins
webpack-dev-server versions up to and including 5.2.3 are vulnerable to cross-origin source code exposure when serving over a non-potentially trustworthy origin such as plain HTTP. The previous fix relied on the Sec-Fetch-Mode and Sec-Fetch-Site request headers, which browsers omit for non-trustworthy origins, allowing a malicious site to load the bundled source as a script and read it across origins. Impact: an attacker controlling a website visited by a developer running webpack-dev-server can recover the application source code when the dev server runs over HTTP at a guessable host and port. Chromium based browsers from Chrome 142 onward are not affected due to local network access restrictions. Upgrade to webpack-dev-server 5.2.4 or later, which sets Cross-Origin-Resource-Policy: same-origin on responses.
- Record
CVE-2026-6402- CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N - Weakness
- CWE-749
- Updated
- 2026-11-02
EUVDEUVD-2026-29404
5.3
webpack-dev-server versions up to and including 5.2.3 are vulnerable to cross-origin source code exposure when serving over a non-potentially trustworthy origin such as plain HTTP. The previous fix relied on the Sec-Fetch-Mode and Sec-Fetch-Site request headers, which browsers omit for non-trustworthy origins, allowing a malicious site to load the bundled source as a script and read it across origins. Impact: an attacker controlling a website visited by a developer running webpack-dev-server can recover the application source code when the dev server runs over HTTP at a guessable host and port. Chromium based browsers from Chrome 142 onward are not affected due to local network access restrictions. Upgrade to webpack-dev-server 5.2.4 or later, which sets Cross-Origin-Resource-Policy: same-origin on responses.
- Record
EUVD-2026-29404- CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N - Updated
- 2026-11-02
GitHub AdvisoriesGHSA-79cf-xcqc-c78w
5.3
webpack-dev-server vulnerable to cross-origin source code exposure on non-HTTPS origins
Impact
When webpack-dev-server is running on a non-HTTPS origin (the default), cross-origin requests from malicious websites can load the dev server's JavaScript bundles via <script> tags. The fix introduced in v5.2.1 (CVE-2025-30359) relied on Sec-Fetch-Mode and Sec-Fetch-Site request headers to block these requests, but browsers only send these headers for potentially trustworthy origins. Over plain HTTP, the headers are absent and the check is bypassed.
An attacker who knows the dev server's host, port, and output path can exfiltrate all module source code by intercepting the webpack runtime's module registration.
This does not affect Chrome 142+ (and other Chromium-based browsers) due to local network access restrictions.
Patches
Patched in webpack-dev-server >= 5.2.4 by setting Cross-Origin-Resource-Policy: same-origin on responses.
Workarounds
Run the dev server with HTTPS enabled (--https or server.type: 'https' in config).
Resources
- GHSA-4v9v-hfq4-rm2v (CVE-2025-30359) - original vulnerability
- GHSA-9jgg-88mc-972h (CVE-2025-30360) - prior bypass
- Record
GHSA-79cf-xcqc-c78w- CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N - Weakness
- CWE-749
- Updated
- 2026-11-02
NVD
5.3
webpack-dev-server versions up to and including 5.2.3 are vulnerable to cross-origin source code exposure when serving over a non-potentially trustworthy origin such as plain HTTP. The previous fix relied on the Sec-Fetch-Mode and Sec-Fetch-Site request headers, which browsers omit for non-trustworthy origins, allowing a malicious site to load the bundled source as a script and read it across origins. Impact: an attacker controlling a website visited by a developer running webpack-dev-server can recover the application source code when the dev server runs over HTTP at a guessable host and port. Chromium based browsers from Chrome 142 onward are not affected due to local network access restrictions. Upgrade to webpack-dev-server 5.2.4 or later, which sets Cross-Origin-Resource-Policy: same-origin on responses.
- Record
CVE-2026-6402- CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N - CVSS 3.1
- 6.5 Medium
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N - Weakness
- CWE-749
- Updated
- 2026-11-02
OSV
5.3
webpack-dev-server vulnerable to cross-origin source code exposure on non-HTTPS origins
webpack-dev-server versions up to and including 5.2.3 are vulnerable to cross-origin source code exposure when serving over a non-potentially trustworthy origin such as plain HTTP. The previous fix relied on the Sec-Fetch-Mode and Sec-Fetch-Site request headers, which browsers omit for non-trustworthy origins, allowing a malicious site to load the bundled source as a script and read it across origins. Impact: an attacker controlling a website visited by a developer running webpack-dev-server can recover the application source code when the dev server runs over HTTP at a guessable host and port. Chromium based browsers from Chrome 142 onward are not affected due to local network access restrictions. Upgrade to webpack-dev-server 5.2.4 or later, which sets Cross-Origin-Resource-Policy: same-origin on responses.
- Record
CVE-2026-6402- CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N - Weakness
- CWE-749
- Updated
- 2026-11-02
OSVGHSA-79cf-xcqc-c78w
5.3
webpack-dev-server vulnerable to cross-origin source code exposure on non-HTTPS origins
Impact
When webpack-dev-server is running on a non-HTTPS origin (the default), cross-origin requests from malicious websites can load the dev server's JavaScript bundles via <script> tags. The fix introduced in v5.2.1 (CVE-2025-30359) relied on Sec-Fetch-Mode and Sec-Fetch-Site request headers to block these requests, but browsers only send these headers for potentially trustworthy origins. Over plain HTTP, the headers are absent and the check is bypassed.
An attacker who knows the dev server's host, port, and output path can exfiltrate all module source code by intercepting the webpack runtime's module registration.
This does not affect Chrome 142+ (and other Chromium-based browsers) due to local network access restrictions.
Patches
Patched in webpack-dev-server >= 5.2.4 by setting Cross-Origin-Resource-Policy: same-origin on responses.
Workarounds
Run the dev server with HTTPS enabled (--https or server.type: 'https' in config).
Resources
- GHSA-4v9v-hfq4-rm2v (CVE-2025-30359) - original vulnerability
- GHSA-9jgg-88mc-972h (CVE-2025-30360) - prior bypass
- Record
GHSA-79cf-xcqc-c78w- CVSS 3.1
- 5.3 Medium
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N - Weakness
- CWE-749
- Updated
- 2026-11-02
Show 14 moreShow less
OSVCLSA-2026-1779238046 No score
TuxCare security update for webpack-dev-server (1 CVE)
TuxCare rebuilt webpack-dev-server to address 1 CVE. Fixed in 4.15.1-tuxcare.3.
- Record
CLSA-2026-1779238046- Updated
- 2026-11-02
OSVCLSA-2026-1784077483 No score
TuxCare security update for webpack-dev-server (3 CVEs)
TuxCare rebuilt webpack-dev-server to address 3 CVEs. Fixed in 4.15.2-tuxcare.1.
- Record
CLSA-2026-1784077483- Updated
- 2026-11-02
OSVCLSA-2026-1784683094 No score
TuxCare security update for webpack-dev-server (1 CVE)
TuxCare rebuilt webpack-dev-server to address 1 CVE. Fixed in 4.11.0-tuxcare.2.
- Record
CLSA-2026-1784683094- Updated
- 2026-11-02
OSVCLSA-2026-1784769523 No score
TuxCare security update for webpack-dev-server (1 CVE)
TuxCare rebuilt webpack-dev-server to address 1 CVE. Fixed in 3.11.3-tuxcare.3.
- Record
CLSA-2026-1784769523- Updated
- 2026-11-02
OSVCLSA-2026-1784769600 No score
TuxCare security update for webpack-dev-server (1 CVE)
TuxCare rebuilt webpack-dev-server to address 1 CVE. Fixed in 3.11.2-tuxcare.2.
- Record
CLSA-2026-1784769600- Updated
- 2026-11-02
OSVCLSA-2026-1784856196 No score
TuxCare security update for webpack-dev-server (1 CVE)
TuxCare rebuilt webpack-dev-server to address 1 CVE. Fixed in 3.11.0-tuxcare.4.
- Record
CLSA-2026-1784856196- Updated
- 2026-11-02
OSVCLSA-2026-1784856456 No score
TuxCare security update for webpack-dev-server (1 CVE)
TuxCare rebuilt webpack-dev-server to address 1 CVE. Fixed in 3.1.14-tuxcare.3.
- Record
CLSA-2026-1784856456- Updated
- 2026-11-02
OSVCLSA-2026-1784943228 No score
TuxCare security update for webpack-dev-server (1 CVE)
TuxCare rebuilt webpack-dev-server to address 1 CVE. Fixed in 2.11.5-tuxcare.3.
- Record
CLSA-2026-1784943228- Updated
- 2026-11-02
OSVCLSA-2026-1784943286 No score
TuxCare security update for webpack-dev-server (1 CVE)
TuxCare rebuilt webpack-dev-server to address 1 CVE. Fixed in 2.7.1-tuxcare.3.
- Record
CLSA-2026-1784943286- Updated
- 2026-11-02
OSVCLSA-2026-1787828309 No score
TuxCare security update for webpack-dev-server (1 CVE)
TuxCare rebuilt webpack-dev-server to address 1 CVE. Fixed in 4.7.3-tuxcare.6.
- Record
CLSA-2026-1787828309- Updated
- 2026-11-02
OSVCLSA-2026-1790004677 No score
TuxCare security update for webpack-dev-server (3 CVEs)
TuxCare rebuilt webpack-dev-server to address 3 CVEs. Fixed in 5.2.2-tuxcare.2.
- Record
CLSA-2026-1790004677- Updated
- 2026-11-02
OSVCLSA-2026-1790604947 No score
TuxCare security update for webpack-dev-server (4 CVEs)
TuxCare rebuilt webpack-dev-server to address 4 CVEs. Fixed in 4.9.3-tuxcare.1.
- Record
CLSA-2026-1790604947- Updated
- 2026-11-02
OSVopenSUSE-SU-2026:10979-1 No score
agama-web-ui-21+360.16caae772-44.1 on GA media
These are all security issues fixed in the agama-web-ui-21+360.16caae772-44.1 package on the GA media of openSUSE Tumbleweed.
- Record
openSUSE-SU-2026:10979-1- Updated
- 2026-11-02
OSVROOT-APP-NPM-CVE-2026-6402 No score
CVE-2026-6402 in webpack-dev-server - Patched by Root
Root has patched CVE-2026-6402 in the webpack-dev-server package for Root:npm. Multiple fixed versions available.
- Record
ROOT-APP-NPM-CVE-2026-6402- Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
webpack-dev-servernpm |
through 5.2.3 | 5.2.4 |
webpack-dev-serverTuxCare:npm |
4.15.1-tuxcare.0 up to 4.15.1-tuxcare.3, plus listed versions 4.15.14.15.1-tuxcare.14.15.1-tuxcare.2 |
4.15.1-tuxcare.3 |
webpack-dev-serverTuxCare:npm From an advisory covering 3 CVEs |
4.15.2-tuxcare.0 up to 4.15.2-tuxcare.1, plus listed versions 4.15.2 |
4.15.2-tuxcare.1 |
webpack-dev-serverTuxCare:npm |
4.11.0-tuxcare.0 up to 4.11.0-tuxcare.2, plus listed versions 4.11.04.11.0-tuxcare.1 |
4.11.0-tuxcare.2 |
webpack-dev-serverTuxCare:npm |
3.11.3-tuxcare.0 up to 3.11.3-tuxcare.3, plus listed versions 3.11.33.11.3-tuxcare.13.11.3-tuxcare.2 |
3.11.3-tuxcare.3 |
webpack-dev-serverTuxCare:npm |
3.11.2-tuxcare.0 up to 3.11.2-tuxcare.2, plus listed versions 3.11.23.11.2-tuxcare.1 |
3.11.2-tuxcare.2 |
webpack-dev-serverTuxCare:npm |
3.11.0-tuxcare.0 up to 3.11.0-tuxcare.4, plus listed versions 3.11.03.11.0-tuxcare.13.11.0-tuxcare.23.11.0-tuxcare.3 |
3.11.0-tuxcare.4 |
webpack-dev-serverTuxCare:npm |
3.1.14-tuxcare.0 up to 3.1.14-tuxcare.3, plus listed versions 3.1.143.1.14-tuxcare.13.1.14-tuxcare.2 |
3.1.14-tuxcare.3 |
webpack-dev-serverTuxCare:npm |
2.11.5-tuxcare.0 up to 2.11.5-tuxcare.3, plus listed versions 2.11.52.11.5-tuxcare.12.11.5-tuxcare.2 |
2.11.5-tuxcare.3 |
webpack-dev-serverTuxCare:npm |
2.7.1-tuxcare.0 up to 2.7.1-tuxcare.3, plus listed versions 2.7.12.7.1-tuxcare.12.7.1-tuxcare.2 |
2.7.1-tuxcare.3 |
Show 7 moreShow less
| Package | Affected | Fixed |
|---|---|---|
webpack-dev-serverTuxCare:npm |
4.7.3-tuxcare.0 up to 4.7.3-tuxcare.6, plus listed versions 4.7.34.7.3-tuxcare.14.7.3-tuxcare.24.7.3-tuxcare.34.7.3-tuxcare.44.7.3-tuxcare.5 |
4.7.3-tuxcare.6 |
webpack-dev-serverTuxCare:npm From an advisory covering 3 CVEs |
5.2.2-tuxcare.0 up to 5.2.2-tuxcare.2, plus listed versions 5.2.25.2.2-tuxcare.1 |
5.2.2-tuxcare.2 |
webpack-dev-serverTuxCare:npm From an advisory covering 4 CVEs |
4.9.3-tuxcare.0 up to 4.9.3-tuxcare.1, plus listed versions 4.9.3 |
4.9.3-tuxcare.1 |
webpack-dev-servernpm |
before 5.2.4 | 5.2.4 |
webpack-dev-serverRoot:npm |
before 5.2.3-aikido.1 | 5.2.3-aikido.15.2.2-aikido.13.11.3-aikido.14.10.0-aikido.13.11.3-aikido.24.10.0-aikido.23.11.3-aikido.35.0.4-aikido.15.2.2-aikido.25.2.3-aikido.25.2.2-aikido.35.2.3-aikido.35.0.4-aikido.23.11.3-aikido.44.10.0-aikido.3 |
@rootio/webpack-dev-serverRoot:npm |
before 5.2.3-root.io.1 | 5.2.3-root.io.15.2.2-root.io.13.11.3-root.io.14.10.0-root.io.13.11.3-root.io.24.10.0-root.io.23.11.3-root.io.35.0.4-root.io.15.2.2-root.io.25.2.3-root.io.25.2.2-root.io.35.2.3-root.io.35.0.4-root.io.23.11.3-root.io.44.10.0-root.io.3 |
agama-web-uiopenSUSE:Tumbleweed From an advisory covering 2 CVEs |
before 21+360.16caae772-44.1 | 21+360.16caae772-44.1 |
History
| Recorded | Changed | Sources |
|---|---|---|
| affected, facts | ||
| first indexed | CVE List, EUVD, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2026-6402 is a medium vulnerability (CVSS 5.3) in Webpack-dev-server, published May 12, 2026. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.29%, the 21st percentile. Fixed in webpack-dev-server 5.2.4.
References
github.com/webpack/webpack-dev-server/security/advisories/GHSA-79cf-xcqc-c78w
cna.openjsf.org/security-advisories.html
github.com/webpack/webpack-dev-server/security/advisories/GHSA-4v9v-hfq4-rm2v
github.com/webpack/webpack-dev-server/security/advisories/GHSA-9jgg-88mc-972h
nvd.nist.gov/vuln/detail/CVE-2026-6402
github.com/advisories/GHSA-79cf-xcqc-c78w