Vitest: Windows backslash traversal bypasses the @vitest/mocker redirect allowlist fix
Default status is the baseline for the product, each version can override it (e.g. patched versions marked unaffected).
| Vendor | Product | Default status | Versions | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| vitest-dev | vitest | affected |
|
|||||||||
| @vitest | mocker | affected |
|
No data.
No data.
| Vendor | Product | Versions | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Vitest.dev | Mocker |
|
||||||||||||
| Vitest.dev | Vitest |
|
| Source | ID | Title |
|---|---|---|
Github GHSA |
GHSA-xp26-3454-mjgp | Vitest: Windows backslash traversal bypasses the @vitest/mocker redirect allowlist fix |
No CVSS v4.0
No CVSS v3.0
No CVSS v2
This CVE is not in the KEV list.
Exploit prediction score: < 1% (0.542% probability within 30 days)
| Type | Values Removed | Values Added |
|---|---|---|
| Metrics |
ssvc
|
| Type | Values Removed | Values Added |
|---|---|---|
| First Time appeared |
Vitest.dev
Vitest.dev mocker Vitest.dev vitest |
|
| Vendors & Products |
Vitest.dev
Vitest.dev mocker Vitest.dev vitest |
| Type | Values Removed | Values Added |
|---|---|---|
| Description | Vitest is a Vite-native testing framework for JavaScript and TypeScript projects. From 4.1.11 until 4.1.12 and 5.0.3, isFileLoadingAllowed and the filesystem read interpret backslashes differently on Windows in packages/mocker/src/node/interceptorPlugin.ts. When a client can reach the Vite dev server on Windows and register a redirect mock containing backslash traversal, POSIX joining preserves a Windows backslash traversal that the later filesystem read interprets as a path separator, so the client can read a file outside server.fs.allow that the Vitest process can access. This issue is fixed in versions 4.1.12 and 5.0.3. | |
| Title | Vitest: Windows backslash traversal bypasses the @vitest/mocker redirect allowlist fix | |
| Weaknesses | CWE-22 | |
| References |
|
|
| Metrics |
cvssV3_1
|