PatchSiren

PatchSiren cyber security CVE debrief

CVE-2026-112945 vitejs CVE debrief

A cross-origin script execution vulnerability exists in Vite when using custom middleware. An attacker can load scripts from a page served by the dev server by accessing a malicious site while the dev server is running. This issue affects applications that use Vite in middleware mode, read trusted HTML, and pass the browser's unchanged request URL to the transform.

Vendor
vitejs
Product
vite
CVSS
LOW 2.1
CISA KEV
Not listed in stored evidence
Original CVE published
2026-10-21
Original CVE updated
2026-10-21
Advisory published
2026-10-21
Advisory updated
2026-10-21

Who should care

Defenders responsible for Vite configurations, especially those using middleware mode or custom app types, should assess their exposure and verify their configurations to prevent exploitation.

Why it matters

Defenders should prioritize verifying their Vite configurations, especially those using middleware mode or custom app types, and ensure they are using a version of Vite that addresses this issue to prevent cross-origin script execution.

  • Verify Vite configurations to prevent cross-origin script execution
  • Update affected applications to a version of Vite that addresses this issue
  • Review and adjust middleware mode or custom app type configurations

Technical summary

The vulnerability exists in Vite when using custom middleware. An attacker can load scripts from a page served by the dev server by accessing a malicious site while the dev server is running. This issue affects applications that use Vite in middleware mode, read trusted HTML, and pass the browser's unchanged request URL to the transform. Defenders should prioritize verifying their Vite configurations, especially those using middleware mode or custom app types, and ensure they are using a version of Vite that addresses this issue to prevent cross-origin script execution.

Defensive priority

Defenders should prioritize verifying their Vite configurations, especially those using middleware mode or custom app types, and ensure they are using a version of Vite that addresses this issue.

Recommended defensive actions

  • Verify Vite configurations, especially those using middleware mode or custom app types
  • Ensure usage of a version of Vite that addresses this issue
  • Review and update affected applications to prevent exploitation
  • Review compensating controls for exposed systems while remediation is scheduled and verified
  • Check relevant monitoring, detection, and logs for exposed assets that need extra review
  • Track exceptions, retest remediated assets, and close the item only after evidence is documented
  • Confirm whether affected product deployments exist in managed environments and assign an owner for follow-up

Evidence notes

The vulnerability details are based on the provided source item from osv_dev and references from the Vite project. The affected configurations and versions are documented in the source item and related references.

Sources and references

Verified primary and authoritative sources

  • CVE-2026-112945 CVE Program record

    Publisher, destination, and source semantics verified

    URL: https://www.cve.org/CVERecord?id=CVE-2026-112945

    CVE Program - Official CVE Program record with source-provided CVE metadata.

  • CVE-2026-112945 NVD vulnerability detail

    Publisher, destination, and source semantics verified

    URL: https://nvd.nist.gov/vuln/detail/CVE-2026-112945

    NIST National Vulnerability Database - Official NIST NVD detail page and source-specific vulnerability assessment.

Supplemental references

  • Vite: Cross origin script execution through Vite custom middleware

    Unverified legacy reference

    URL: https://storage.googleapis.com/osv-vulnerabilities/npm/GHSA-9jrq-w75r-8gcw.json

    osv_dev

  • Source reference

    Unverified legacy reference

    URL: https://github.com/vitejs/vite/security/advisories/GHSA-9jrq-w75r-8gcw

    Supplemental source

  • Source reference

    Unverified legacy reference

    URL: https://github.com/vitejs/vite/pull/23653

    Supplemental source

  • Source reference

    Unverified legacy reference

    URL: https://github.com/vitejs/vite/commit/7dafd8e56f152403a3230608fa4005273c2e9e17

    Supplemental source

  • Source reference

    Unverified legacy reference

    URL: https://github.com/vitejs/vite

    Supplemental source

Methodology and review provenance

AI-assisted synthesis based on stored public vulnerability evidence. System validation, approval state, and publication status do not by themselves establish human review of this revision. PatchSiren helps prioritize defensive review and does not prove exposure or remediation on any system.