Vitest: Code injection via unauthenticated manual mock registration
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-qxg6-89mg-rqv8 | Vitest: Code injection via unauthenticated manual mock registration |
No CVSS v4.0
No CVSS v3.0
No CVSS v2
This CVE is not in the KEV list.
Exploit prediction score: < 1% (0.336% probability within 30 days)
| Type | Values Removed | Values Added |
|---|---|---|
| Metrics |
ssvc
|
| Type | Values Removed | Values Added |
|---|---|---|
| Weaknesses | CWE-79 | |
| References |
| |
| Metrics |
threat_severity
|
threat_severity
|
| 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 2.1.0-beta.7 until 4.1.12 and 5.0.3, an unauthenticated non-browser WebSocket client that can reach a development server using interceptorPlugin can register a manual mock whose attacker-controlled url createManualModuleSource inserts unescaped into generated module source. When the developer browser loads the affected module, attacker-controlled JavaScript executes on the development-server origin. This issue is fixed in versions 4.1.12 and 5.0.3. | |
| Title | Vitest: Code injection via unauthenticated manual mock registration | |
| Weaknesses | CWE-116 CWE-306 CWE-94 |
|
| References |
|
|
| Metrics |
cvssV3_1
|