Skip to main content
← All vulnerabilities
CVE-2025-24963GHSA-8GVC-J273-4WM5

Browser mode serves arbitrary files in vitest

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 2.1.9, 3.0.4
1 proof of concept on GitHub, 1 Nuclei template
  • Exploitation: poc
  • Automatable: no
  • Technical impact: total

Summary

Vitest is a testing framework powered by Vite. The `screenshot-error` handler on the browser mode HTTP server that responds any file on the file system. Especially if the server is exposed on the network by `browser.api.host: true`, an attacker can send a request to that handler from remote to get the content of arbitrary files.This `screenshot-error` handler on the browser mode HTTP server responds any file on the file system. This code was added by commit `2d62051`. Users explicitly exposing the browser mode server to the network by `browser.api.host: true` may get any files exposed. This issue has been addressed in versions 2.1.9 and 3.0.4. Users are advised to upgrade. There are no known workarounds for this vulnerability.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: poc · Automatable: no · Technical impact: total

  3. Record last updated

Affected versions

  • vitest-dev vitest

    From 2.0.4 · fixed in 2.1.9; From 3.0.0 · fixed in 3.0.4

  • @vitest/browsernpm

    From 2.0.4 · fixed in 2.1.9

  • @vitest/browsernpm

    From 3.0.0 · fixed in 3.0.4

References 6

GitHub · vitest-dev/vitest

vitest.dev

GitHub · projectdiscovery/nuclei-templates

GitHub · hiteshpatra/CVE-2025-24963