Every CVE Search/ Get API key

CVE-2025-31125

Vite has a `server.fs.deny` bypassed for `inline` and `raw` with `?import` query

5.3 MediumIn KEVPublic exploitFix available

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.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
High
Privileges needed
None
User interaction
Required

What an attacker can affect

Confidentiality
High
Integrity
None
Availability
None

Exploit likelihood

74.9%Up 74.9 points since Apr 1, 2025
90%50%10%1%

What each source reports

CVE List Score used 5.3

Vite has a `server.fs.deny` bypassed for `inline` and `raw` with `?import` query

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.

Record
CVE-2025-31125
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N
Weakness
CWE-200, CWE-284
Updated
2026-11-02
EUVDEUVD-2025-8866 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) are affected. This vulnerability is fixed in 6.2.4, 6.1.3, 6.0.13, 5.4.16, and 4.5.11.

Record
EUVD-2025-8866
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N
Updated
2026-11-02
GitHub AdvisoriesGHSA-4r4m-qw57-chr8 5.3

Vite has a `server.fs.deny` bypassed for `inline` and `raw` with `?import` query

Summary

The contents of arbitrary files can be returned to the browser.

Impact

Only apps explicitly exposing the Vite dev server to the network (using --host or server.host config option) are affected.

Details

  • base64 encoded content of non-allowed files is exposed using ?inline&import (originally reported as ?import&?inline=1.wasm?init)
  • content of non-allowed files is exposed using ?raw?import

/@fs/ isn't needed to reproduce the issue for files inside the project root.

PoC

Original report (check details above for simplified cases):

The ?import&?inline=1.wasm?init ending allows attackers to read arbitrary files and returns the file content if it exists. Base64 decoding needs to be performed twice

$ npm create vite@latest
$ cd vite-project/
$ npm install
$ npm run dev

Example full URL http://localhost:5173/@fs/C:/windows/win.ini?import&?inline=1.wasm?init

Record
GHSA-4r4m-qw57-chr8
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N
Weakness
CWE-200, CWE-284
Updated
2026-11-02
CISA KEV No score

Vite Vitejs Improper Access Control Vulnerability

Vite Vitejs contains an improper access control vulnerability that 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.

Record
CVE-2025-31125
Weakness
CWE-200, CWE-284
Updated
2026-11-02
NVD 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) are affected. This vulnerability is fixed in 6.2.4, 6.1.3, 6.0.13, 5.4.16, and 4.5.11.

Record
CVE-2025-31125
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N
CVSS 3.1
7.5 HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
Weakness
CWE-200, CWE-284
Updated
2026-11-02
OSV 5.3

Vite has a `server.fs.deny` bypassed for `inline` and `raw` with `?import` query

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.

Record
CVE-2025-31125
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N
Weakness
CWE-200, CWE-284
Updated
2026-11-04
Show 11 moreShow less
OSVGHSA-4r4m-qw57-chr8 5.3

Vite has a `server.fs.deny` bypassed for `inline` and `raw` with `?import` query

Summary

The contents of arbitrary files can be returned to the browser.

Impact

Only apps explicitly exposing the Vite dev server to the network (using --host or server.host config option) are affected.

Details

  • base64 encoded content of non-allowed files is exposed using ?inline&import (originally reported as ?import&?inline=1.wasm?init)
  • content of non-allowed files is exposed using ?raw?import

/@fs/ isn't needed to reproduce the issue for files inside the project root.

PoC

Original report (check details above for simplified cases):

The ?import&?inline=1.wasm?init ending allows attackers to read arbitrary files and returns the file content if it exists. Base64 decoding needs to be performed twice

$ npm create vite@latest
$ cd vite-project/
$ npm install
$ npm run dev

Example full URL http://localhost:5173/@fs/C:/windows/win.ini?import&?inline=1.wasm?init

Record
GHSA-4r4m-qw57-chr8
CVSS 3.1
5.3 MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N
Weakness
CWE-200, CWE-284
Updated
2026-11-02
OSVCLSA-2026-1775176118 No score

TuxCare security update for vite (6 CVEs)

TuxCare rebuilt vite to address 6 CVEs. Fixed in 4.5.5-tuxcare.1.

Record
CLSA-2026-1775176118
Updated
2026-11-02
OSVCLSA-2026-1777249675 No score

TuxCare security update for vite (4 CVEs)

TuxCare rebuilt vite to address 4 CVEs. Fixed in 5.4.14-tuxcare.2.

Record
CLSA-2026-1777249675
Updated
2026-11-02
OSVCLSA-2026-1777509608 No score

TuxCare security update for vite (11 CVEs)

TuxCare rebuilt vite to address 11 CVEs. Fixed in 2.9.18-tuxcare.1.

Record
CLSA-2026-1777509608
Updated
2026-11-02
OSVCLSA-2026-1777509610 No score

TuxCare security update for vite (6 CVEs)

TuxCare rebuilt vite to address 6 CVEs. Fixed in 3.2.11-tuxcare.1.

Record
CLSA-2026-1777509610
Updated
2026-11-02
OSVCLSA-2026-1789031855 No score

TuxCare security update for vite (16 CVEs)

TuxCare rebuilt vite to address 16 CVEs. Fixed in 4.1.5-tuxcare.1.

Record
CLSA-2026-1789031855
Updated
2026-11-02
OSVCLSA-2026-1790801785 No score

TuxCare security update for vite (3 CVEs)

TuxCare rebuilt vite to address 3 CVEs. Fixed in 5.0.12-tuxcare.1.

Record
CLSA-2026-1790801785
Updated
2026-11-02
OSVCLSA-2026-1790803771 No score

TuxCare security update for vite (3 CVEs)

TuxCare rebuilt vite to address 3 CVEs. Fixed in 4.5.0-tuxcare.1.

Record
CLSA-2026-1790803771
Updated
2026-11-02
OSVCLSA-2026-1790804788 No score

TuxCare security update for vite (2 CVEs)

TuxCare rebuilt vite to address 2 CVEs. Fixed in 5.4.10-tuxcare.1.

Record
CLSA-2026-1790804788
Updated
2026-11-02
OSVCLSA-2026-1792225950 No score

TuxCare security update for @vitejs/plugin-react (11 CVEs)

TuxCare rebuilt @vitejs/plugin-react to address 11 CVEs. Fixed in 2.9.18-tuxcare.1.

Record
CLSA-2026-1792225950
Updated
2026-11-02
OSVCLSA-2026-1792225952 No score

TuxCare security update for @vitejs/plugin-react (6 CVEs)

TuxCare rebuilt @vitejs/plugin-react to address 6 CVEs. Fixed in 3.2.11-tuxcare.1.

Record
CLSA-2026-1792225952
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
vite
npm
6.2.0 up to 6.2.4
6.2.4
vite
npm
6.1.0 up to 6.1.3
6.1.3
vite
npm
6.0.0 up to 6.0.13
6.0.13
vite
npm
5.0.0 up to 5.4.16
5.4.16
vite
npm
before 4.5.11
4.5.11
vite
TuxCare:npm
From an advisory covering 6 CVEs
4.5.5-tuxcare.0 up to 4.5.5-tuxcare.1, plus listed versions
4.5.5
4.5.5-tuxcare.1
vite
TuxCare:npm
From an advisory covering 4 CVEs
5.4.14-tuxcare.0 up to 5.4.14-tuxcare.2, plus listed versions
5.4.145.4.14-tuxcare.1
5.4.14-tuxcare.2
vite
TuxCare:npm
From an advisory covering 11 CVEs
2.9.18-tuxcare.0 up to 2.9.18-tuxcare.1, plus listed versions
2.9.18
2.9.18-tuxcare.1
vite
TuxCare:npm
From an advisory covering 6 CVEs
3.2.11-tuxcare.0 up to 3.2.11-tuxcare.1, plus listed versions
3.2.11
3.2.11-tuxcare.1
vite
TuxCare:npm
From an advisory covering 16 CVEs
4.1.5-tuxcare.0 up to 4.1.5-tuxcare.1, plus listed versions
4.1.5
4.1.5-tuxcare.1
Show 5 moreShow less
Affected packages
PackageAffectedFixed
vite
TuxCare:npm
From an advisory covering 3 CVEs
5.0.12-tuxcare.0 up to 5.0.12-tuxcare.1, plus listed versions
5.0.12
5.0.12-tuxcare.1
vite
TuxCare:npm
From an advisory covering 3 CVEs
4.5.0-tuxcare.0 up to 4.5.0-tuxcare.1, plus listed versions
4.5.0
4.5.0-tuxcare.1
vite
TuxCare:npm
From an advisory covering 2 CVEs
5.4.10-tuxcare.0 up to 5.4.10-tuxcare.1, plus listed versions
5.4.10
5.4.10-tuxcare.1
@vitejs/plugin-react
TuxCare:npm
From an advisory covering 11 CVEs
2.9.18-tuxcare.0 up to 2.9.18-tuxcare.1, plus listed versions
2.9.18
2.9.18-tuxcare.1
@vitejs/plugin-react
TuxCare:npm
From an advisory covering 6 CVEs
3.2.11-tuxcare.0 up to 3.2.11-tuxcare.1, plus listed versions
3.2.11
3.2.11-tuxcare.1

Public exploits

Links only. Every CVE stores no exploit code.

Public exploits
SourceLinkDate
PoC in GitHubsunhuiHi666/CVE-2025-311252025-04-01
PoC in GitHubMuhammadWaseem29/Vitejs-exploit2025-05-03
PoC in GitHub0xgh057r3c0n/CVE-2025-311252025-05-07
PoC in GitHubharshgupptaa/Path-Transversal-CVE-2025-31125-2025-07-13
NucleiVite Development Server - Path Traversal

History

History
RecordedChangedSources
affectedOSV
exploitation, exploits
first indexedCVE List, EUVD, GitHub Advisories, CISA KEV, Nuclei, NVD, OSV, PoC in GitHub

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2025-31125 is a medium vulnerability (CVSS 5.3) in Vitejs Vite, published March 31, 2025. CISA lists it as known to be exploited, since January 22, 2026. EUVD reports exploitation since January 22, 2026. Public exploit code exists. EPSS puts the chance of exploitation in the next 30 days at 74.9%, the 99th percentile. Fixed in vite 6.2.4.

References

MoveEnter Open