<Vulnerability name="CVE-2026-53633">
    <DocumentDistribution xml:lang="en">Copyright © 2012 Red Hat, Inc. All rights reserved.</DocumentDistribution>
    <ThreatSeverity>Important</ThreatSeverity>
    <PublicDate>2026-07-14T19:35:42</PublicDate>
    <Bugzilla id="2500586" url="https://bugzilla.redhat.com/show_bug.cgi?id=2500586" xml:lang="en:us">
@vitest/browser: vite-plus: Vitest: Remote code execution via exposed Chrome DevTools Protocol API
    </Bugzilla>
    <CVSS3 status="draft">
        <CVSS3BaseScore>8.1</CVSS3BaseScore>
        <CVSS3ScoringVector>CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H</CVSS3ScoringVector>
    </CVSS3>
    <CWE>CWE-94</CWE>
    <Details xml:lang="en:us" source="Mitre">
Vitest is a testing framework powered by Vite. From 3.0.0 until 3.2.5, 4.1.8, and 5.0.0-beta.4, Vitest Browser Mode exposed a cdp() API that forwarded raw Chrome DevTools Protocol methods without being gated by allowWrite or allowExec, allowing a remote client with exposed browser API metadata to use CDP Page.setDownloadBehavior and Runtime.evaluate to overwrite vite.config.ts and execute attacker-controlled Node.js code. This issue is fixed in versions 3.2.5, 4.1.8, and 5.0.0-beta.
    </Details>
    <Details xml:lang="en:us" source="Red Hat">
A flaw was found in Vitest Browser Mode, a component of the Vitest testing framework. The cdp() API exposed raw Chrome DevTools Protocol (CDP) methods without proper security restrictions. This vulnerability allows a remote attacker, with access to browser API metadata, to leverage CDP functions like Page.setDownloadBehavior and Runtime.evaluate. This can lead to overwriting configuration files and executing arbitrary Node.js code, resulting in remote code execution.
    </Details>
    <Statement xml:lang="en:us">
Red Hat has assessed this flaw against its shipping products. The vulnerability requires Vitest Browser Mode (the @vitest/browser package) to be installed AND explicitly enabled (browser.enabled: true), paired with a CDP-capable browser provider such as Playwright Chromium, an actively running test session, and the Browser Mode API server exposed on a network-reachable interface (--browser.api.host=0.0.0.0). It does not affect the core `vitest` test runner used without Browser Mode. Only one Red Hat shipping product, Red Hat Trusted Artifact Signer (RHTAS) console UI, lists @vitest/browser as a development dependency, used solely to run its own component test suite. Red Hat has confirmed that this product's test configuration does not enable Browser Mode (browser.enabled is not set to true), no CI invocation passes the required --browser flag, no CDP-capable provider package is installed, and the @vitest/browser package is excluded from the final shipped container image (present only in a discarded multi-stage build layer). No Red Hat product installs, enables, or exposes Vitest Browser Mode's CDP proxy in production.
    </Statement>
    <Mitigation xml:lang="en:us">
No mitigation is required for Red Hat shipping products, as Vitest Browser Mode and its CDP proxy feature are not enabled or reachable in any Red Hat product's build, test, or runtime configuration. Development teams that do enable Vitest Browser Mode with a CDP-capable provider (Playwright or WebdriverIO) should avoid exposing the Browser Mode API server to untrusted networks (do not set --browser.api.host=0.0.0.0 or equivalent) and should upgrade to @vitest/browser 3.2.5, 4.1.8, 5.0.0-beta.4, or later, and vite-plus 0.1.24 or later.
    </Mitigation>
    <PackageState cpe="cpe:/a:redhat:trusted_artifact_signer:1">
        <ProductName>Red Hat Trusted Artifact Signer</ProductName>
        <FixState>Not affected</FixState>
        <PackageName>rhtas/rhtas-console-ui-rhel9</PackageName>
    </PackageState>
    <References xml:lang="en:us">
https://www.cve.org/CVERecord?id=CVE-2026-53633
https://nvd.nist.gov/vuln/detail/CVE-2026-53633
https://github.com/vitest-dev/vitest/commit/385a1aefd4c2bfa5e7d58bf7c6834c929969f2c7
https://github.com/vitest-dev/vitest/commit/63e3b2eee4d58da56786a6333f517b9b492528c7
https://github.com/vitest-dev/vitest/commit/e4067b3b150005fd42cf75f994300119245806b9
https://github.com/vitest-dev/vitest/pull/10444
https://github.com/vitest-dev/vitest/pull/10450
https://github.com/vitest-dev/vitest/pull/10456
https://github.com/vitest-dev/vitest/releases/tag/v3.2.5
https://github.com/vitest-dev/vitest/releases/tag/v4.1.8
https://github.com/vitest-dev/vitest/releases/tag/v5.0.0-beta.4
https://github.com/vitest-dev/vitest/security/advisories/GHSA-g8mr-85jm-7xhm
    </References>
</Vulnerability>