{"id":"CVE-2026-47429","aliases":["CLSA-2026-1789904677","CLSA-2026-1790109523","CLSA-2026-1792160955","CLSA-2026-1792161474","CLSA-2026-1792161475","CLSA-2026-1792161577","CLSA-2026-1792161609","CLSA-2026-1792161648","CLSA-2026-1792161650","CLSA-2026-1792161662","CLSA-2026-1792161721","CLSA-2026-1792161722","CLSA-2026-1792161767","CLSA-2026-1792161768","CLSA-2026-1792161832","CLSA-2026-1792161877","CLSA-2026-1792161878","CLSA-2026-1792161943","CLSA-2026-1792161976","CLSA-2026-1792161977","CLSA-2026-1792162011","CLSA-2026-1792162035","CLSA-2026-1792162037","CLSA-2026-1792162060","CLSA-2026-1792450983","CLSA-2026-1793093026","EUVD-2026-44391","GHSA-5xrq-8626-4rwp","RHSA-2026:39058","ROOT-APP-NPM-CVE-2026-47429"],"status":"published","title":"Vitest: Arbitrary file can be read and executed when Vitest UI server is listening","description":"Vitest is a testing framework powered by Vite. Prior to 3.2.5 and 4.1.0, the Vitest UI/API server on Windows used isFileServingAllowed incorrectly for /__vitest_attachment__, allowing \\\\?\\\\..\\\\ path traversal to read files outside the project; exposed API write and rerun features such as saveTestFile and rerun could also allow arbitrary script execution. This issue is fixed in versions 3.2.5 and 4.1.0.","severity":{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-09","score":0.01028,"percentile":0.63895,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":true,"fix_available":true},"cwes":["CWE-22","CWE-862"],"published":"2026-06-01T14:09:53Z","modified":"2026-11-02T19:58:45Z","exploits":[{"source":"pocgithub","id":"az9713/cve-lite-on-pi","title":"az9713/cve-lite-on-pi","date":"2026-06-09","url":"https://github.com/az9713/cve-lite-on-pi"}],"fixes":[{"ecosystem":"npm","package":"vitest","fixed_in":["4.1.0","3.2.6"],"sources":["ghsa","osv"]},{"ecosystem":"TuxCare:npm","package":"vitest","fixed_in":["4.0.18-tuxcare.3"],"sources":["osv"]},{"ecosystem":"Root:npm","package":"vitest","fixed_in":["1.6.1-aikido.1","1.6.1-aikido.2","2.1.9-aikido.1"],"sources":["osv"]},{"ecosystem":"Root:npm","package":"@rootio/vitest","fixed_in":["1.6.1-root.io.1","1.6.1-root.io.2","2.1.9-root.io.1"],"sources":["osv"]}],"affected":[{"source":"ghsa","ecosystem":"npm","package":"vitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.0"},{"fixed":"4.1.0"}]}]},{"source":"ghsa","ecosystem":"npm","package":"vitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.2.6"}]}]},{"source":"osv","ecosystem":"TuxCare:npm","package":"vitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"]},{"source":"osv","ecosystem":"TuxCare:npm","package":"vitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/pretty-format","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/snapshot","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/snapshot","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/browser","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/browser-playwright","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/browser-preview","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/coverage-istanbul","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/coverage-v8","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/expect","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/expect","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/mocker","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/mocker","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/pretty-format","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/spy","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/spy","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/ui","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/utils","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/utils","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/web-worker","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/runner","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"4.0.18-tuxcare.0"},{"fixed":"4.0.18-tuxcare.3"}]}],"versions":["4.0.18","4.0.18-tuxcare.1","4.0.18-tuxcare.2"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/runner","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"@vitest/ws-client","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.4-tuxcare.0"},{"fixed":"3.2.4-tuxcare.2"}]}],"versions":["3.2.4","3.2.4-tuxcare.1"],"bundled":2},{"source":"osv","ecosystem":"TuxCare:npm","package":"vitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"2.1.9-tuxcare.0"},{"fixed":"2.1.9-tuxcare.1"}]}],"versions":["2.1.9"],"bundled":3},{"source":"osv","ecosystem":"TuxCare:npm","package":"vitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"2.0.5-tuxcare.0"},{"fixed":"2.0.5-tuxcare.1"}]}],"versions":["2.0.5"],"bundled":4},{"source":"osv","ecosystem":"npm","package":"vitest","ranges":[{"type":"SEMVER","events":[{"introduced":"4.0.0"},{"fixed":"4.1.0"}]}]},{"source":"osv","ecosystem":"npm","package":"vitest","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"3.2.6"}]}]},{"source":"osv","ecosystem":"Red Hat:hummingbird:1","package":"prometheus3.13","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:3.13.1-0.1.hum1"}]}],"bundled":2},{"source":"osv","ecosystem":"Root:npm","package":"vitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.1-aikido.1"},{"fixed":"1.6.1-aikido.2"},{"fixed":"2.1.9-aikido.1"}]}]},{"source":"osv","ecosystem":"Root:npm","package":"@rootio/vitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.6.1-root.io.1"},{"fixed":"1.6.1-root.io.2"},{"fixed":"2.1.9-root.io.1"}]}]}],"products":[{"vendor":"vitest-dev","product":"vitest"},{"vendor":"vitest.dev","product":"vitest"}],"references":[{"url":"https://github.com/vitest-dev/vitest/security/advisories/GHSA-5xrq-8626-4rwp","tags":["x_refsource_CONFIRM","exploit","Exploit","Mitigation","Vendor Advisory","advisory","web","article"]},{"url":"https://github.com/vitest-dev/vitest/pull/10445","tags":["x_refsource_MISC","Exploit","Issue Tracking","Patch","fix","web","article"]},{"url":"https://github.com/vitest-dev/vitest/pull/9350","tags":["x_refsource_MISC","Exploit","Issue Tracking","Patch","fix","web","article"]},{"url":"https://github.com/vitest-dev/vitest/commit/20e00ef7808de6d330c5e2fda530f686e08f1c8d","tags":["x_refsource_MISC","Patch","fix","web","article"]},{"url":"https://github.com/vitest-dev/vitest/commit/af88b1f5d82844a4761ea9a977156c98e2b14ca8","tags":["x_refsource_MISC","Patch","fix","web","article"]},{"url":"https://github.com/vitest-dev/vitest/releases/tag/v3.2.5","tags":["x_refsource_MISC","Release Notes","web","article"]},{"url":"https://github.com/vitest-dev/vitest/releases/tag/v4.1.0","tags":["x_refsource_MISC","Release Notes","web","article"]},{"url":"https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/browser/src/node/commands/fs.ts#L10-L11","tags":["web"]},{"url":"https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/browser/src/node/plugin.ts#L194-L196","tags":["web"]},{"url":"https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/browser/src/node/rpc.ts#L115-L121","tags":["web"]},{"url":"https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/ui/node/index.ts#L77","tags":["web"]},{"url":"https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/vitest/src/api/setup.ts#L103-L105","tags":["web"]},{"url":"https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/vitest/src/api/setup.ts#L119-L121","tags":["web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-47429","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-5xrq-8626-4rwp"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/47xxx/CVE-2026-47429.json","tags":["advisory"]},{"url":"https://github.com/vitest-dev/vitest","tags":["package"]},{"url":"https://access.redhat.com/errata/RHSA-2026:39058","tags":["advisory"]},{"url":"https://images.redhat.com/","tags":["article"]},{"url":"https://access.redhat.com/security/cve/CVE-2026-47428","tags":["report"]},{"url":"https://access.redhat.com/security/updates/classification/","tags":["article"]},{"url":"https://access.redhat.com/security/cve/CVE-2026-47429","tags":["report"]},{"url":"https://security.access.redhat.com/data/csaf/v2/advisories/2026/rhsa-2026_39058.json","tags":["advisory"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2500578","tags":["report"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-47428","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-47428","tags":["advisory"]},{"url":"https://github.com/vitest-dev/vitest/commit/18af98cee1830604d57f6a02bf28f8067cdffc06","tags":["article"]},{"url":"https://github.com/vitest-dev/vitest/commit/3514f9fa135c90e1c35754fc4d27c9cf351faafa","tags":["article"]},{"url":"https://github.com/vitest-dev/vitest/pull/10283","tags":["article"]},{"url":"https://github.com/vitest-dev/vitest/pull/10285","tags":["article"]},{"url":"https://github.com/vitest-dev/vitest/releases/tag/v4.1.6","tags":["article"]},{"url":"https://github.com/vitest-dev/vitest/releases/tag/v5.0.0-beta.3","tags":["article"]},{"url":"https://github.com/vitest-dev/vitest/security/advisories/GHSA-2h32-95rg-cppp","tags":["article"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2500573","tags":["report"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-47429","tags":["advisory"]}],"sources":{"cve":[{"id":"CVE-2026-47429","title":"Vitest: Arbitrary file can be read and executed when Vitest UI server is listening","description":"Vitest is a testing framework powered by Vite. Prior to 3.2.5 and 4.1.0, the Vitest UI/API server on Windows used isFileServingAllowed incorrectly for /__vitest_attachment__, allowing \\\\?\\\\..\\\\ path traversal to read files outside the project; exposed API write and rerun features such as saveTestFile and rerun could also allow arbitrary script execution. This issue is fixed in versions 3.2.5 and 4.1.0.","status":"published","published":"2026-07-14T19:28:08.688Z","modified":"2026-07-21T15:02:17.187Z","cvss":[{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical","assessor":"cna"}],"cwes":["CWE-22"],"updated_at":"2026-11-02T13:36:40.478484Z"}],"euvd":[{"id":"EUVD-2026-44391","description":"Vitest is a testing framework powered by Vite. Prior to 3.2.5 and 4.1.0, the Vitest UI/API server on Windows used isFileServingAllowed incorrectly for /__vitest_attachment__, allowing \\\\?\\\\..\\\\ path traversal to read files outside the project; exposed API write and rerun features such as saveTestFile and rerun could also allow arbitrary script execution. This issue is fixed in versions 3.2.5 and 4.1.0.","status":"published","published":"2026-07-14T19:28:08Z","modified":"2026-07-21T15:02:17Z","cvss":[{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical"}],"updated_at":"2026-11-02T18:19:47.436242Z"}],"ghsa":[{"id":"GHSA-5xrq-8626-4rwp","title":"When Vitest UI server is listening, arbitrary file can be read and executed","description":"### Summary\nArbitrary file can be read on Windows when Vitest UI server is listening, especially when exposed to the network.\n\n### Impact\nOnly users that match either of the following conditions are affected:\n\n- explicitly exposes the Vitest UI server to the network (using `--api.host` or [`api.host` config option](https://vitest.dev/config/api.html))\n- running the Vitest UI or Browser Mode on Windows\n\n### Details\nThe API handler for `/__vitest_attachment__` uses the deprecated `isFileServingAllowed` incorrectly.\nhttps://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/ui/node/index.ts#L77\nThe function expects the passed value to use `cleanUrl` after the check before file system related operation.\nBecause of this, it is possible to bypass the check by `\\\\?\\\\..\\\\`. This is not possible on Linux as Linux errors if a directory named `?` does not exist.\n\nA similar problem exists in other places as well.\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/vitest/src/api/setup.ts#L103-L105\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/vitest/src/api/setup.ts#L119-L121\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/browser/src/node/commands/fs.ts#L10-L11\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/browser/src/node/plugin.ts#L194-L196\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/browser/src/node/rpc.ts#L115-L121\n\n**That said**, this `isFileServingAllowed` check does not actually prevent the API to be abused. Since the API has rerun feature and file write feature, it's possible to run arbitrary script by writing a script as a test file using `saveTestFile` and running it using `rerun`. This means exposing the API / Vitest UI is equivalent to giving script execution access.\nOn the browser mode side, there're `readFile` / `writeFile` / `saveSnapshotFile`. So exposing the browser mode is equivalent to giving file read / write access.\n\n### PoC\n1. Run Vitest UI\n2. Get the API token by `curl http://localhost:51204/__vitest__/`\n3. Run `curl \"http://localhost:51204/__vitest_attachment__?path=C:\\\\path\\\\to\\\\project\\\\?\\\\..\\\\..\\\\secret.txt\u0026amp;contentType=text/plain\u0026amp;token=$TOKEN\"` (TOKEN is the API token)\n4. curl shows the content of `secret.txt` that is outside the project directory\n\n### Mitigations\n\nVitest now ships two configuration flags, [`allowWrite`](https://vitest.dev/config/api.html#api-allowwrite) and [`allowExec`](https://vitest.dev/config/api.html#api-allowexec), that gate the privileged operations exploited by this vulnerability. Both are disabled by default whenever the API server is bound to a non-`localhost` host, ensuring that exposing the server to the network no longer implicitly grants write or execute capabilities to remote clients.\n\nWhen these flags are disabled, the UI also enters a read-only mode: in-browser code editing and test file execution are turned off, removing the attack surface that allowed remote code execution. Many Browser Mode features are also disabled, like attachments, artifacts or snapshots. See [`browser.api`](https://vitest.dev/config/browser/api.html#api-allowwrite).\n\nUsers who require the full interactive UI on a networked host must explicitly opt in by setting `allowWrite` and/or `allowExec` to `true`.","status":"published","published":"2026-06-01T14:09:53Z","modified":"2026-08-13T18:19:30Z","cvss":[{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-22","CWE-862"],"updated_at":"2026-11-02T14:41:00.097339Z"}],"nvd":[{"id":"CVE-2026-47429","description":"Vitest is a testing framework powered by Vite. Prior to 3.2.5 and 4.1.0, the Vitest UI/API server on Windows used isFileServingAllowed incorrectly for /__vitest_attachment__, allowing \\\\?\\\\..\\\\ path traversal to read files outside the project; exposed API write and rerun features such as saveTestFile and rerun could also allow arbitrary script execution. This issue is fixed in versions 3.2.5 and 4.1.0.","status":"published","published":"2026-07-14T20:17:02.46Z","modified":"2026-10-24T21:10:00.13Z","cvss":[{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical","assessor":"secondary"},{"version":"3.1","score":5.9,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N","level":"medium","assessor":"primary"}],"cwes":["CWE-22"],"updated_at":"2026-11-02T14:12:29.879716Z"}],"osv":[{"id":"CVE-2026-47429","title":"Vitest: Arbitrary file can be read and executed when Vitest UI server is listening","description":"Vitest is a testing framework powered by Vite. Prior to 3.2.5 and 4.1.0, the Vitest UI/API server on Windows used isFileServingAllowed incorrectly for /__vitest_attachment__, allowing \\\\?\\\\..\\\\ path traversal to read files outside the project; exposed API write and rerun features such as saveTestFile and rerun could also allow arbitrary script execution. This issue is fixed in versions 3.2.5 and 4.1.0.","status":"published","published":"2026-07-14T19:28:08.688Z","modified":"2026-10-28T02:31:14.73860904Z","cvss":[{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-22"],"updated_at":"2026-11-02T15:45:06.231145Z"},{"id":"GHSA-5xrq-8626-4rwp","title":"When Vitest UI server is listening, arbitrary file can be read and executed","description":"### Summary\nArbitrary file can be read on Windows when Vitest UI server is listening, especially when exposed to the network.\n\n### Impact\nOnly users that match either of the following conditions are affected:\n\n- explicitly exposes the Vitest UI server to the network (using `--api.host` or [`api.host` config option](https://vitest.dev/config/api.html))\n- running the Vitest UI or Browser Mode on Windows\n\n### Details\nThe API handler for `/__vitest_attachment__` uses the deprecated `isFileServingAllowed` incorrectly.\nhttps://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/ui/node/index.ts#L77\nThe function expects the passed value to use `cleanUrl` after the check before file system related operation.\nBecause of this, it is possible to bypass the check by `\\\\?\\\\..\\\\`. This is not possible on Linux as Linux errors if a directory named `?` does not exist.\n\nA similar problem exists in other places as well.\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/vitest/src/api/setup.ts#L103-L105\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/vitest/src/api/setup.ts#L119-L121\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/browser/src/node/commands/fs.ts#L10-L11\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/browser/src/node/plugin.ts#L194-L196\n- https://github.com/vitest-dev/vitest/blob/eb1abf08573032a532015b999ad3501c5e89e3bb/packages/browser/src/node/rpc.ts#L115-L121\n\n**That said**, this `isFileServingAllowed` check does not actually prevent the API to be abused. Since the API has rerun feature and file write feature, it's possible to run arbitrary script by writing a script as a test file using `saveTestFile` and running it using `rerun`. This means exposing the API / Vitest UI is equivalent to giving script execution access.\nOn the browser mode side, there're `readFile` / `writeFile` / `saveSnapshotFile`. So exposing the browser mode is equivalent to giving file read / write access.\n\n### PoC\n1. Run Vitest UI\n2. Get the API token by `curl http://localhost:51204/__vitest__/`\n3. Run `curl \"http://localhost:51204/__vitest_attachment__?path=C:\\\\path\\\\to\\\\project\\\\?\\\\..\\\\..\\\\secret.txt\u0026amp;contentType=text/plain\u0026amp;token=$TOKEN\"` (TOKEN is the API token)\n4. curl shows the content of `secret.txt` that is outside the project directory\n\n### Mitigations\n\nVitest now ships two configuration flags, [`allowWrite`](https://vitest.dev/config/api.html#api-allowwrite) and [`allowExec`](https://vitest.dev/config/api.html#api-allowexec), that gate the privileged operations exploited by this vulnerability. Both are disabled by default whenever the API server is bound to a non-`localhost` host, ensuring that exposing the server to the network no longer implicitly grants write or execute capabilities to remote clients.\n\nWhen these flags are disabled, the UI also enters a read-only mode: in-browser code editing and test file execution are turned off, removing the attack surface that allowed remote code execution. Many Browser Mode features are also disabled, like attachments, artifacts or snapshots. See [`browser.api`](https://vitest.dev/config/browser/api.html#api-allowwrite).\n\nUsers who require the full interactive UI on a networked host must explicitly opt in by setting `allowWrite` and/or `allowExec` to `true`.","status":"published","published":"2026-06-01T14:09:53Z","modified":"2026-09-10T03:50:48.501520322Z","cvss":[{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical"}],"cwes":["CWE-22","CWE-862"],"updated_at":"2026-11-02T15:46:38.911014Z"},{"id":"RHSA-2026:39058","title":"Red Hat Security Advisory: Red Hat Hardened Images RPMs bug fix and enhancement update","status":"published","published":"2026-07-16T10:10:15Z","modified":"2026-09-08T10:13:55Z","cvss":[{"version":"3.1","score":8.3,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T15:53:20.491441Z"},{"id":"ROOT-APP-NPM-CVE-2026-47429","title":"CVE-2026-47429 in vitest - Patched by Root","description":"Root has patched CVE-2026-47429 in the vitest package for Root:npm. Multiple fixed versions available.","status":"published","published":"2026-08-19T09:14:51Z","modified":"2026-08-19T10:45:05.588849294Z","cvss":[{"version":"3.1","score":9.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","level":"critical"}],"updated_at":"2026-11-02T15:53:27.649662Z"},{"id":"CLSA-2026-1789904677","title":"TuxCare security update for vitest (1 CVE)","description":"TuxCare rebuilt vitest to address 1 CVE. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-09-20T11:44:37Z","modified":"2026-11-02T19:58:45.65379215Z","updated_at":"2026-11-02T20:22:37.141028Z"},{"id":"CLSA-2026-1790109523","title":"TuxCare security update for vitest (2 CVEs)","description":"TuxCare rebuilt vitest to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-09-22T20:38:43Z","modified":"2026-10-15T09:46:03.012677982Z","updated_at":"2026-11-02T15:43:48.28229Z"},{"id":"CLSA-2026-1792160955","title":"TuxCare security update for @vitest/pretty-format (2 CVEs)","description":"TuxCare rebuilt @vitest/pretty-format to address 2 CVEs. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-10-16T14:29:11Z","modified":"2026-10-16T16:30:37.331017373Z","updated_at":"2026-11-02T15:43:50.949147Z"},{"id":"CLSA-2026-1792161474","title":"TuxCare security update for @vitest/snapshot (2 CVEs)","description":"TuxCare rebuilt @vitest/snapshot to address 2 CVEs. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-10-16T14:37:54Z","modified":"2026-10-16T16:31:03.37403396Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161475","title":"TuxCare security update for @vitest/snapshot (2 CVEs)","description":"TuxCare rebuilt @vitest/snapshot to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:37:55Z","modified":"2026-10-16T16:31:03.541628734Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161577","title":"TuxCare security update for @vitest/browser (2 CVEs)","description":"TuxCare rebuilt @vitest/browser to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:39:37Z","modified":"2026-10-16T16:30:23.864861105Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161609","title":"TuxCare security update for @vitest/browser-playwright (2 CVEs)","description":"TuxCare rebuilt @vitest/browser-playwright to address 2 CVEs. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-10-16T14:40:09Z","modified":"2026-10-16T16:30:09.177138098Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161648","title":"TuxCare security update for @vitest/browser-preview (2 CVEs)","description":"TuxCare rebuilt @vitest/browser-preview to address 2 CVEs. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-10-16T14:40:48Z","modified":"2026-10-16T16:31:12.995584667Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161650","title":"TuxCare security update for @vitest/coverage-istanbul (2 CVEs)","description":"TuxCare rebuilt @vitest/coverage-istanbul to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:40:50Z","modified":"2026-10-16T16:31:13.443782639Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161662","title":"TuxCare security update for @vitest/coverage-v8 (2 CVEs)","description":"TuxCare rebuilt @vitest/coverage-v8 to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:41:02Z","modified":"2026-10-16T16:31:13.868181041Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161721","title":"TuxCare security update for @vitest/expect (2 CVEs)","description":"TuxCare rebuilt @vitest/expect to address 2 CVEs. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-10-16T14:42:01Z","modified":"2026-10-16T16:31:14.705585923Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161722","title":"TuxCare security update for @vitest/expect (2 CVEs)","description":"TuxCare rebuilt @vitest/expect to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:42:02Z","modified":"2026-10-16T16:31:14.852313498Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161767","title":"TuxCare security update for @vitest/mocker (2 CVEs)","description":"TuxCare rebuilt @vitest/mocker to address 2 CVEs. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-10-16T14:42:47Z","modified":"2026-10-16T16:31:29.283962517Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161768","title":"TuxCare security update for @vitest/mocker (2 CVEs)","description":"TuxCare rebuilt @vitest/mocker to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:42:48Z","modified":"2026-10-16T16:31:29.282860313Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161832","title":"TuxCare security update for @vitest/pretty-format (2 CVEs)","description":"TuxCare rebuilt @vitest/pretty-format to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:43:52Z","modified":"2026-10-16T16:31:15.153929801Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161877","title":"TuxCare security update for @vitest/spy (2 CVEs)","description":"TuxCare rebuilt @vitest/spy to address 2 CVEs. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-10-16T14:44:37Z","modified":"2026-10-16T16:31:17.846310475Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161878","title":"TuxCare security update for @vitest/spy (2 CVEs)","description":"TuxCare rebuilt @vitest/spy to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:44:38Z","modified":"2026-10-16T16:31:17.849060402Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161943","title":"TuxCare security update for @vitest/ui (2 CVEs)","description":"TuxCare rebuilt @vitest/ui to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:45:43Z","modified":"2026-10-16T16:31:19.15495087Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161976","title":"TuxCare security update for @vitest/utils (2 CVEs)","description":"TuxCare rebuilt @vitest/utils to address 2 CVEs. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-10-16T14:46:16Z","modified":"2026-10-16T16:31:19.90018215Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792161977","title":"TuxCare security update for @vitest/utils (2 CVEs)","description":"TuxCare rebuilt @vitest/utils to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:46:17Z","modified":"2026-10-16T16:31:20.121724449Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792162011","title":"TuxCare security update for @vitest/web-worker (2 CVEs)","description":"TuxCare rebuilt @vitest/web-worker to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:46:51Z","modified":"2026-10-16T16:31:20.55331377Z","updated_at":"2026-11-02T15:43:51.213191Z"},{"id":"CLSA-2026-1792162035","title":"TuxCare security update for @vitest/runner (2 CVEs)","description":"TuxCare rebuilt @vitest/runner to address 2 CVEs. Fixed in 4.0.18-tuxcare.3.","status":"published","published":"2026-10-16T14:47:15Z","modified":"2026-10-16T16:31:21.215089042Z","updated_at":"2026-11-02T15:43:51.466048Z"},{"id":"CLSA-2026-1792162037","title":"TuxCare security update for @vitest/runner (2 CVEs)","description":"TuxCare rebuilt @vitest/runner to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:47:17Z","modified":"2026-10-16T16:31:41.619395714Z","updated_at":"2026-11-02T15:43:51.466048Z"},{"id":"CLSA-2026-1792162060","title":"TuxCare security update for @vitest/ws-client (2 CVEs)","description":"TuxCare rebuilt @vitest/ws-client to address 2 CVEs. Fixed in 3.2.4-tuxcare.2.","status":"published","published":"2026-10-16T14:47:40Z","modified":"2026-10-16T16:31:21.56187339Z","updated_at":"2026-11-02T15:43:51.466048Z"},{"id":"CLSA-2026-1792450983","title":"TuxCare security update for vitest (3 CVEs)","description":"TuxCare rebuilt vitest to address 3 CVEs. Fixed in 2.1.9-tuxcare.1.","status":"published","published":"2026-10-19T23:03:03Z","modified":"2026-10-20T01:45:09.158676317Z","updated_at":"2026-11-02T15:43:54.378946Z"},{"id":"CLSA-2026-1793093026","title":"TuxCare security update for vitest (4 CVEs)","description":"TuxCare rebuilt vitest to address 4 CVEs. Fixed in 2.0.5-tuxcare.1.","status":"published","published":"2026-10-27T09:23:46Z","modified":"2026-10-27T13:30:02.665565012Z","updated_at":"2026-11-02T15:43:55.34846Z"}]}}
