Vite - Path Traversal (CVE-2026-112947)
Description
Vite is a frontend tooling framework for JavaScript. From 8.2.0 until 8.2.4 and 8.3.3, the first 4 bytes of files outside of server.fs setting can be returned to the browser by a request containing ?vite-wasm-instance. Requests containing the ?vite-wasm-instance query are handled by the internal Wasm plugin's load hook. The hook removes the query and reads the resulting path directly from disk, but the server.fs checks were not applied. After reading the file, Vite attempts to parse it as WebAssembly. When that parse fails, Node and deno throws an error that contains the first 4 bytes of the file. This vulnerability is fixed in 8.2.4 and 8.3.3.
psychologyCrowdSec Analysis
CVE-2026-112947 is a path traversal vulnerability in Vite and vite-plus that bypasses configured filesystem restrictions when processing requests containing the ?vite-wasm-instance query. An unauthenticated remote attacker may exploit this flaw to disclose the first four bytes of files outside the allowed directory, potentially exposing limited sensitive information. The issue is fixed in Vite 8.2.4 and 8.3.3.
CrowdSec has been tracking this vulnerability and its exploits since 24th of November 2026.
CrowdSec has not observed any significant exploitation activity targeting CVE-2026-112947 across its network. As a result, no community-driven trend analysis is available for this vulnerability at this time.
Attackers target Vite’s /@fs/ endpoint with the vite-wasm-instance query parameter to bypass filesystem restrictions and probe or disclose files. Requests such as /@fs/etc/passwd?vite-wasm-instance may trigger an error that reveals the file’s first four bytes.
Full Intelligence Available
Connect your API key to access CrowdSec scores, exploit timelines, and attacker IPs.
| Event | Date |
|---|---|
| CVE Published | 2026-10-20 |
| Rule Released | 2026-11-24 |
Related Weaknesses
The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory.
The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
The product generates an error message that includes sensitive information about its environment, users, or associated data.
Remediation & Protection
External References
- https://github.com/vitejs/vite/commit/b6c6d2fb3f853aab4092dc25f0d6816a96c23dff
- https://github.com/vitejs/vite/commit/ba8b7ab43b4afa5d0292ab4b6e3a7b5033cc9c73
- https://github.com/vitejs/vite/security/advisories/GHSA-vfpm-58rq-9qcg
- https://github.com/vitejs/vite/pull/23655
- https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2026/CVE-2026-112947.yaml