一、 漏洞 CVE-2025-24963 基础信息
漏洞信息
                                        # 浏览器模式在vitest中提供任意文件

## 漏洞概述
Vitest 的浏览器模式 HTTP 服务器中的 `__screenshot-error` 处理程序可以响应文件系统的任意文件。如果该服务器通过 `browser.api.host: true` 暴露在网络中,攻击者可以通过发送请求来访问任意文件内容。

## 影响版本
- 低于 2.1.9 的 2.x 版本
- 低于 3.0.4 的 3.x 版本

## 漏洞细节
`__screenshot-error` 处理程序在浏览器模式 HTTP 服务器中回应文件系统上的任意文件。该代码由提交 `2d62051` 引入。如果用户通过设置 `browser.api.host: true` 显式地将浏览器模式服务器暴露在网络中,则可能导致任意文件被访问。

## 影响
受影响的用户应升级到 2.1.9 或 3.0.4 及以上版本。目前没有已知的解决方法。
                                        
提示
尽管我们采用了先进的大模型技术,但其输出仍可能包含不准确或过时的信息。
神龙会尽力确保数据准确,但也请结合实际情况进行甄别与判断。
神龙祝您一切顺利!
漏洞标题
Browser mode serves arbitrary files in vitest
来源:美国国家漏洞数据库 NVD
漏洞描述信息
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.
来源:美国国家漏洞数据库 NVD
CVSS信息
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N
来源:美国国家漏洞数据库 NVD
漏洞类别
对路径名的限制不恰当(路径遍历)
来源:美国国家漏洞数据库 NVD
漏洞标题
Vitest 路径遍历漏洞
来源:中国国家信息安全漏洞库 CNNVD
漏洞描述信息
Vitest是Vitest开源的一个 Vite 支持的下一代测试框架。 Vitest存在路径遍历漏洞,该漏洞源于浏览器模式HTTP服务器上的__screenshot-error处理程序可响应文件系统上的任何文件。
来源:中国国家信息安全漏洞库 CNNVD
CVSS信息
N/A
来源:中国国家信息安全漏洞库 CNNVD
漏洞类别
路径遍历
来源:中国国家信息安全漏洞库 CNNVD
二、漏洞 CVE-2025-24963 的公开POC
# POC 描述 源链接 神龙链接
1 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. https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2025/CVE-2025-24963.yaml POC详情
2 None https://github.com/0xdeviner/CVE-2025-24963 POC详情
三、漏洞 CVE-2025-24963 的情报信息
  • 标题: Browser Config Reference | Vitest -- 🔗来源链接

    标签: x_refsource_MISC

  • 标题: Browser mode serves arbitrary files · Advisory · vitest-dev/vitest · GitHub -- 🔗来源链接

    标签: x_refsource_CONFIRM

  • 标题: feat(browser): allow preview and open in the editor screenshot error … · vitest-dev/vitest@2d62051 · GitHub -- 🔗来源链接

    标签: x_refsource_MISC

  • 标题: vitest/packages/browser/src/node/plugin.ts at f17918a79969d27a415f70431e08a9445b051e45 · vitest-dev/vitest · GitHub -- 🔗来源链接

    标签: x_refsource_MISC

  • https://nvd.nist.gov/vuln/detail/CVE-2025-24963
四、漏洞 CVE-2025-24963 的评论

暂无评论


发表评论