Skip to content
FlawDB
Sign in
Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

CVE-2025-58751

LOW 2.3EPSS 73%

Vite middleware may serve files starting with the same name with the public directory

Also known as GHSA-g4jq-h2w9-997c

Mitigation

  • Upgrade vite to one of 7.1.5, 7.0.7, 6.3.6, 5.4.20 (or later in the same release line).

Who should check

  • Projects that depend on npm package vite (>= 7.1.0, < 7.1.5)
  • Anyone running vitejs vite < 5.4.20; >= 6.0.0, < 6.3.6; >= 7.0.0, < 7.0.7; >= 7.1.0, < 7.1.5

Vulnerability facts

Affected
vite >= 7.1.0, < 7.1.5
Fixed in
7.1.5, 7.0.7, 6.3.6, 5.4.20
Exploited in the wild
Not in CISA KEV
Public exploit / PoC
None known
Remote exploitation
Remote, no login needed
CVSS
2.3 (v4.0, CNA)CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:L/VI:N/VA:N/SC:N/SI:N/SA:NOpen in CVSS calculator
Show all 11 CVSS metrics
  • Attack vector: Network
  • Attack complexity: Low
  • Attack requirements: Present
  • Privileges required: None
  • User interaction: Passive
  • Confidentiality impact: Low
  • Integrity impact: None
  • Availability impact: None
  • Confidentiality impact on other systems: None
  • Integrity impact on other systems: None
  • Availability impact on other systems: None
EPSS
1.40% chance of exploitation in 30 days (percentile 73, 2026-11-26)
CWE
CWE-22, CWE-200, CWE-284
Published
Modified

Description

Vite is a frontend tooling framework for JavaScript. Prior to versions 7.1.5, 7.0.7, 6.3.6, and 5.4.20, files starting with the same name with the public directory were served bypassing the `server.fs` settings. Only apps that explicitly expose the Vite dev server to the network (using --host or `server.host` config option), use the public directory feature (enabled by default), and have a symlink in the public directory are affected. Versions 7.1.5, 7.0.7, 6.3.6, and 5.4.20 fix the issue.

Affected and fixed versions

Package / productAffectedFixedSource
npm vite>= 7.1.0, < 7.1.57.1.5, 7.0.7, 6.3.6, 5.4.20osv
vitejs vite< 5.4.20; >= 6.0.0, < 6.3.6; >= 7.0.0, < 7.0.7; >= 7.1.0, < 7.1.5—cvelist

Check your systems with an agent

Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.

Check whether anything I run is affected by CVE-2025-58751. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-58751.md
Affected: vite >= 7.1.0, < 7.1.5
Fixed in: 7.1.5, 7.0.7, 6.3.6, 5.4.20

Steps:
1. Search this machine and project for vite (npm), vitejs vite: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.

References

FAQ

Is CVE-2025-58751 being exploited?

There is no confirmed exploitation: CVE-2025-58751 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 1.40% chance of exploitation in the next 30 days (as of 2026-11-26).

How serious is CVE-2025-58751?

Low: CVSS 2.3 (v4.0, scored by CNA). Remote, no login needed. A user has to take an action, such as opening a link, for the attack to work.

Which versions are affected by CVE-2025-58751?

vite >= 7.1.0, < 7.1.5.

Is there a fix for CVE-2025-58751?

Yes. Fixed in 7.1.5, 7.0.7, 6.3.6, 5.4.20. Upgrade vite to one of 7.1.5, 7.0.7, 6.3.6, 5.4.20 (or later in the same release line).

How do I check if I'm affected by CVE-2025-58751?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

Sponsors