CVE-2025-31125: Vite Vitejs Improper Access Control Vulnerability
CVE-2025-31125 is a medium-severity flaw (CVSS 5.3) affecting vite, reported as exploited in the wild. Below: why it ranks where it does, which versions are affected, what to do, and the exact commands.
Vite is a frontend tooling framework for javascript. Vite exposes content of non-allowed files using ?inline&import or ?raw?import. Only apps explicitly exposing the Vite dev server to the network (using --host or server.host config option) are affected. This vulnerability is fixed in 6.2.4, 6.1.3, 6.0.13, 5.4.16, and 4.5.11.
Why this priority
- EPSS top 1%: very likely to be exploited
- Exploited in the wild (CISA KEV)
- Public exploit reference
A fixed release or distro patch exists.
Last updated 2026-06-17 · Sources: CVE Program, NVD, CISA KEV, EPSS and vendor advisories · How we score
Am I affected?
Timeline
- Published CVE record published
- Exploited Added to the CISA Known Exploited Vulnerabilities list
- Deadline CISA due date for US federal agencies to patch
- Updated Record last modified
Exact fixes by distribution
Public exploits and detection
Public code exists for this CVE. Treat unpatched systems as at risk, and only run PoCs in a lab.
- GitHub PoC: sunhuiHi666/CVE-2025-31125 (6 stars)
- GitHub PoC: MuhammadWaseem29/Vitejs-exploit (0 stars)
- GitHub PoC: 0xgh057r3c0n/CVE-2025-31125 (0 stars)
- Write-up: github.com/vitejs/vite/security/advisories/GHSA-4r4m-qw57-chr8
- GitHub PoC: harshgupptaa/Path-Transversal-CVE-2025-31125-
- Nuclei scan template: Vite Development Server - Path Traversal
Scores and fixes here are computed automatically from those and other public sources. Confirm with the vendor advisory before changing production systems.
Quick answers
How do I fix CVE-2025-31125?
vite: upgrade to 4.5.11, 5.4.16, 6.0.13, 6.1.3, 6.2.4. Exact commands for each OS are on this page.
Is CVE-2025-31125 being exploited?
Yes. CVE-2025-31125 is on the CISA Known Exploited Vulnerabilities list, so treat it as patch-now.
What does CVE-2025-31125 affect?
CVE-2025-31125 affects vite. Severity is medium (CVSS 5.3). Vite is a frontend tooling framework for javascript. Vite exposes content of non-allowed files using ?inline&import or ?raw?import. Only apps explicitly exposing the Vite dev server to the network (using --host or server.host config option)
How urgent is CVE-2025-31125?
Priority 73/100. EPSS top 1%: very likely to be exploited; Exploited in the wild (CISA KEV); Public exploit reference
Related CVEs
- CVE-2026-53571 HIGH 7.5 UPGRADE UPGRADE Vite is a frontend tooling framework for JavaScript
- CVE-2025-58752 MEDIUM 5.3 UPGRADE Vite is a frontend tooling framework for JavaScript
- CVE-2026-39363 HIGH 7.5 UPGRADE UPGRADE Vite is a frontend tooling framework for JavaScript
- CVE-2026-39364 HIGH 7.5 UPGRADE UPGRADE Vite is a frontend tooling framework for JavaScript
- CVE-2026-39365 MEDIUM 5.3 UPGRADE UPGRADE Vite is a frontend tooling framework for JavaScript