
Cloud Vulnerability DB
A community-led vulnerabilities database
CVE-2026-39363 is an arbitrary file read vulnerability in the Vite JavaScript frontend tooling framework, caused by missing Origin header validation on the dev server's WebSocket interface. An unauthenticated, network-adjacent attacker can invoke the fetchModule function via the custom WebSocket event vite:invoke and use file:// URLs combined with ?raw or ?inline query parameters to retrieve arbitrary files from the server filesystem as JavaScript strings. Affected versions include Vite 6.0.0–6.4.1, 7.0.0–7.3.1, and 8.0.0–8.0.4, as well as vite-plus ≤0.1.15. The vulnerability was published on April 7, 2026, and carries a CVSS v3.1 score of 7.5 (High) and a CVSS v4.0 score of 8.2 (High) (GitHub Advisory, Red Hat Bugzilla).
The root cause is a combination of CWE-200 (Exposure of Sensitive Information to an Unauthorized Actor), CWE-306 (Missing Authentication for Critical Function), and CWE-1220 (Insufficient Granularity of Access Control). The Vite dev server exposes a WebSocket-based RPC mechanism that accepts vite:invoke events to call internal functions such as fetchModule. Because no Origin header validation is enforced on WebSocket connections, any network-reachable client can connect without authentication. The server.fs.allow access control list — which correctly blocks equivalent HTTP requests (e.g., /@fs/etc/passwd?raw returns HTTP 403) — is not applied to this WebSocket code path, allowing an attacker to bypass it entirely by sending a crafted fetchModule call with a file:// URL. Exploitation requires that the dev server is explicitly exposed to the network (via --host or server.host) and that WebSocket is not disabled (server.ws: false) (GitHub Advisory, Red Hat Bugzilla).
Successful exploitation allows an unauthenticated attacker to read the contents of arbitrary files on the server hosting the Vite dev server — including source code, environment files (.env), credentials, SSH keys, /etc/passwd, and other sensitive data — returned as JavaScript module strings. The impact is limited to confidentiality (no integrity or availability impact), but exposure of secrets or credentials could enable lateral movement or privilege escalation in CI/CD pipelines, development machines, or containerized environments. IBM API Connect is also listed as an affected downstream product (GitHub Advisory, IBM Advisory).
Public proof-of-concept exploit code is available in Python (exp.py) and Node.js (poc.js) on GitHub, with documented usage examples for reading arbitrary files via WebSocket RPC abuse (e.g., python exp.py -t localhost -p 5173 -f "C:/Windows/win.ini"). The official Vite security advisory also provides step-by-step reproduction instructions. As of the time of reporting, there is no confirmed evidence of in-the-wild exploitation, and no threat actor attribution has been made. The EPSS score is approximately 0.068% (low probability of near-term exploitation). The vulnerability is not currently listed in the CISA KEV catalog. Detection templates have been added to Nuclei, Qualys, and Nessus (GitHub PoC, GitHub Advisory).
--host 0.0.0.0 or equivalent.server.fs.allow is active: curl -i 'http://<target>:5173/@fs/etc/passwd?raw' — expect a 403 Restricted response.ws://<target>:5173) without including an Origin header, bypassing any origin-based access control.vite:invoke event: Transmit a WebSocket message invoking the fetchModule function via the vite:invoke event type, specifying a file:// URL to the target file with ?raw or ?inline appended (e.g., file:///etc/passwd?raw).export default "root:x:0:0:..."), completing the arbitrary file read.exp.py or poc.js scripts to automate reading multiple files of interest (e.g., .env, SSH keys, application secrets) (GitHub PoC, GitHub Advisory).Origin header; outbound data transfers from the dev server to unknown hosts.vite:invoke WebSocket events with fetchModule calls referencing file:// URLs or paths outside the project directory; repeated WebSocket connection attempts from a single IP..env, ~/.ssh/id_rsa, /etc/passwd, or application configuration files in server access logs.Upgrade Vite to a patched version: 6.4.2, 7.3.2, or 8.0.5 (or later); vite-plus users should upgrade to 0.1.16 or later. As an immediate workaround, disable WebSocket support by setting server.ws: false in the Vite config, or restrict network exposure by not using --host or server.host to bind the dev server to untrusted networks. If the dev server must be network-accessible, enforce Origin header validation at the network or reverse proxy level. Red Hat has addressed this in Red Hat Ansible Automation Platform via RHSA-2026:24761 and RHSA-2026:24762, and IBM has issued an advisory for IBM API Connect (GitHub Advisory, Red Hat Bugzilla, IBM Advisory).
The Vite security team (credited to sapphi-red, bluwy, and external reporters odgrso, CodeAnt-AI-Security, and tronglinh23) published the advisory on April 6, 2026, with patches released promptly. Red Hat triaged the issue as high severity and issued errata for Ansible Automation Platform within approximately two months. The vulnerability attracted attention on Bluesky and was indexed by multiple threat intelligence aggregators (Sangfor, VulDB, Sploitus, Vulners). ProjectDiscovery added Nuclei detection templates for the vulnerability across multiple template releases in April–May 2026, and the issue was included in ProjectDiscovery's April 2026 Nuclei templates blog post (GitHub Advisory, Red Hat Bugzilla).
Fix availability across major Linux distributions and their releases.
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."