CVE-2025-24963

MEDIUM EXPLOITED NUCLEI

Vitest Browser Mode - Local File Read

Title source: nuclei
STIX 2.1

Exploitation Summary

CVE-2025-24963 has been observed exploited in the wild (reported by VulnCheck KEV). EIP tracks 2 public exploits from researchers including hiteshpatra, 0xdeviner. A Nuclei detection template is also available.

AI-analyzed exploit summary This repository contains a functional exploit for CVE-2025-24963, demonstrating a local file read vulnerability in Vitest's browser mode due to improper input validation in the `__screenshot-error` handler. The exploit uses a crafted HTTP request to read arbitrary files when the server is exposed via `browser.api.host: true`.

Description

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.

Exploits (2)

nomisec WORKING POC
by hiteshpatra · poc
https://github.com/hiteshpatra/CVE-2025-24963

This repository contains a functional exploit for CVE-2025-24963, demonstrating a local file read vulnerability in Vitest's browser mode due to improper input validation in the `__screenshot-error` handler. The exploit uses a crafted HTTP request to read arbitrary files when the server is exposed via `browser.api.host: true`.

Classification
Working Poc 95%
Attack Type
Info Leak
Complexity
Trivial
Reliability
Reliable
Target: @vitest/browser (versions 2.0.4 to 2.1.8, 3.0.0 to 3.0.3)
No auth needed
Prerequisites: Vitest browser mode server exposed to network with `browser.api.host: true`
devstral-2 · analyzed Apr 17, 2026 Full analysis →
nomisec WORKING POC
by 0xdeviner · infoleak
https://github.com/0xdeviner/CVE-2025-24963

This repository contains a working proof-of-concept for CVE-2025-24963, a local file read vulnerability in Vitest's browser mode. The exploit leverages improper input validation in the `__screenshot-error` handler to read arbitrary files when the server is exposed to the network.

Classification
Working Poc 95%
Attack Type
Info Leak
Complexity
Trivial
Reliability
Reliable
Target: @vitest/browser versions 2.0.4 to 2.1.8 and 3.0.0 to 3.0.3
No auth needed
Prerequisites: Vitest browser mode enabled with `browser.api.host: true` · Network access to the Vitest server
devstral-2 · analyzed Feb 16, 2026 Full analysis →

Nuclei Templates (1)

Vitest Browser Mode - Local File Read
MEDIUMVERIFIEDby iamnoooob,rootxharsh,pdresearch

Scores

CVSS v3 5.9
EPSS 0.2364
EPSS Percentile 96.1%
Attack Vector NETWORK
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N

CISA SSVC

Vulnrichment
Exploitation poc
Automatable no
Technical Impact total

Details

VulnCheck KEV 2026-04-30
CWE
CWE-22
Status published
Products (2)
vitest/browser 2.0.4 - 2.1.9npm
vitest.dev/vitest < 2.1.9
Published Feb 04, 2025
Tracked Since Feb 18, 2026