MEDIUMCVSS v4 6.9Vulnerability

CVE-2026-140098

> [!IMPORTANT] > **This advisory only affects beta versions.** ### Summary With 8.4.0-beta.1, the contents of files that are outside [`server.fs.allow`](https://vite.dev/config/server-options#server-fs-allow) and not included in [`server.fs.deny`](https://vite.dev/config/server-options#server-fs-deny) can be returned to the browser. ### Impact Only apps that match the following conditions are affected: - explicitly exposes the Vite dev server to the network (using `--host` or [`server.host` config option](https://vitejs.dev/config/server-options.html#server-host)) - the sensitive file exists is not specified by [server.fs.deny](https://vite.dev/config/server-options#server-fs-deny) - Uses v8.4.0-beta.1 ### Details In 8.4.0-beta.1, a dev server can be made to serve any file outside `server.fs.allow` that is not matched by `server.fs.deny`, with two unauthenticated GET requests and no preconditions: 1. `GET /@fs/<absolute-path>?worker&import`. The worker plugin generates a `WorkerWrapper` module whose body embeds the request-chosen path, and in doing so registers the absolute path in `config.environments.client.safeModulePaths`. 2. `GET /@fs/<absolute-path>` 200 with the file content. The safeModulePaths check short-circuits before the `fs.allow` check. Only `server.fs.deny` matches keep working after registration. `?sharedworker&import` triggers the same flow, and `?wasm` / `?init&import` / `?source&import` queries register `.wasm` files the same way. This is new in 8.4. The poisoning write (`fileToDevUrl` → `safeModulePaths.addId`) was introduced by commit https://github.com/vitejs/vite/commit/e258ce140eef64cf89ff38c410125abd8726f274 (https://github.com/vitejs/vite/pull/23168). ### PoC Minimal reproduction (two requests): ``` # 1) Before registration — correctly denied GET /@fs/etc/passwd -> 403 Restricted ("The request id /etc/passwd is outside...") # 2) Register the path via the worker query GET /@fs/etc/passwd?worker&import -> 200 -> body: export de

Properties

Severity
medium
Summary
Vite [beta only]: files otuside `server.fs.allow` and not included in `server.fs.deny` can be served by two requests using `?worker`
Nvd fetched at
2026-12-02T06:37:54.190518+00:00
Epss score
0.0065
Cvss severity
MEDIUM
Cvss score
6.9
Retrieved at
2026-12-02T06:40:14+00:00
Ghsa published
2026-12-01T19:02:48Z
Source url
https://github.com/advisories/GHSA-qppr-rxr4-jjq2
Ghsa updated
2026-12-01T19:02:49Z
Ghsa id
GHSA-qppr-rxr4-jjq2
Last source
FIRST EPSS
Score
6.9
Cvss version
4.0
Cve id
CVE-2026-140098
Cvss vector
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/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
First seen by Signal
2026-12-01T02:29:47+00:00
Name
CVE-2026-140098
Is ghsa only
false
Vector
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/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

Related Entities (3)

AFFECTS (1)

→[Software]npm/vite

VULNERABLE_TO (1)

←[Software]npm/vite

Related research

Explore deeper with Ninja Signal's threat intelligence graph

CVE-2026-140098 (CVSS v4 6.9) — Ninja Signal Threat Intelligence | Ninja Signal