Skip to main content

@vitejs/plugin-rsc CVE-2025-67489

CRITICAL
Code Injection (CWE-94)
2025-12-09 security-advisories@github.com
9.8
CVSS 3.1 · Vendor: github
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Reach dev server over network (vite --host)
  2. Delivery
    POST crafted request to /_.rsc server-function endpoint
  3. Exploit
    Inject data: URL via x-rsc-action/reference id
  4. Execution
    Unsafe dynamic import executes attacker JS as Node
  5. Impact
    Exfiltrate source/credentials or pivot internally

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Code injection prevention, sandbox exec
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Initial Access

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Requires (1) a running Vite DEVELOPMENT server using @vitejs/plugin-rsc <= 0.5.5 in an RSC application that exposes server-function endpoints (the loadServerAction/decodeReply/decodeAction request handler, e.g. the /_.rsc route), and (2) network reachability to that dev server. The vulnerable code path is the development-mode dynamic import of server/client references, which accepts attacker-controlled 'data:' URL modules. LIMITING FACTORS: it affects dev servers ONLY (production builds are not exposed); the dev server binds to localhost by default, so remote exploitation realistically requires the developer to have run 'vite --host' (or equivalent binding) exposing the port on a reachable interface; no authentication or user interaction is needed once the endpoint is reachable.

Impact

The raw CVSS 3.1 base score of 9.8 (AV:N/AC:L/PR:N/UI:N, C:H/I:H/A:H) reads as a critical, remotely-exploitable, unauthenticated RCE, and in isolation would demand emergency patching. However, this score materially overstates real-world risk because the flaw affects only the Vite DEVELOPMENT server, not production builds - a context CVSS base metrics cannot express. Contrasting signals align with this: EPSS is low at 0.81% (56th percentile), indicating no modeled likelihood of widespread opportunistic exploitation, and the CVE is NOT on CISA KEV, so there is no evidence of active exploitation. A detailed, working proof-of-concept IS published in the GitHub Security Advisory (poc.js plus a StackBlitz repro), so publicly available exploit code exists and the technical barrier to abuse is trivial. Net assessment: this is a genuine code-injection (CWE-94) RCE that should be patched promptly by developers, but it is a developer-workstation / CI-exposure risk rather than an internet-facing production threat. The dev server binds to localhost by default; the high-severity scenario requires the developer to run 'vite --host' (or otherwise expose the port) on an untrusted network. The low EPSS despite a published POC is consistent with a developer-tooling vulnerability that is hard to reach at scale, not a mass-exploitation target.

Exploit ScenarioDerived

A developer runs the RSC dev server with 'vite --host' on a shared or untrusted network. An attacker on that network sends a crafted POST to the /_.rsc server-function endpoint with an x-rsc-action header (or server-reference id) pointing at a 'data:text/javascript,...' URL, which the unsafe dynamic import loads and executes with Node.js privileges. A fully functional POC is published in the GHSA advisory, so exploitation is turnkey and the attacker gains arbitrary code execution to read files, steal environment variables/credentials, or pivot to internal services.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
Patch available 0.8% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Oct 14, 2026

Arbitrary remote code execution in @vitejs/plugin-rsc 0.5.5 and earlier lets unauthenticated network attackers run JavaScript with Node.js privileges on a running Vite development server that uses React Server Components and exposes server-function endpoints. The flaw lives in the development-mode dynamic import path used by loadServerAction, decodeReply, and decodeAction, which accepts attacker-controlled references (including data: URL modules) supplied via the x-rsc-action header and request body; a public proof-of-concept exploit exists in the GitHub Security Advisory, though EPSS rates near-term exploitation likelihood low at 0.81% (56th percentile) and it is not in CISA KEV. Impact is confined to development servers - production builds are unaffected - but risk rises sharply when developers run 'vite --host', exposing the port on all network interfaces.

RemediationAI

Upgrade @vitejs/plugin-rsc to 0.5.6, which is the vendor-released fix and adds reference allowlist validation (commit fe634b58210d0a4a146a7faae56cd71af3bb9af4; advisory GHSA-j76j-5p5g-9wfr at https://github.com/vitejs/vite-plugin-react/security/advisories/GHSA-j76j-5p5g-9wfr). Because the vulnerable code path only exists on the development server, the highest-value compensating control is network containment: do not run 'vite dev' with '--host' or any binding that exposes the port beyond localhost, and if remote access is required, place the dev server behind an authenticated reverse proxy or VPN rather than a public interface - the trade-off is added access friction for remote developers. Additionally, firewall the dev port (default 5173) to trusted source addresses and run dev servers inside an isolated container or network namespace with minimal filesystem and environment-variable exposure, since successful exploitation yields file read/write and credential exfiltration with Node.js privileges; the trade-off is reduced convenience and potential breakage of cross-service dev integrations. Disabling or removing the RSC server-function endpoint handler (the /_.rsc route) in any shared or internet-reachable environment eliminates the attack surface entirely, at the cost of the development functionality that depends on it. Rotate any environment variables, tokens, or source-repository credentials that were present in a dev server known to have been exposed, as the flaw permits data exfiltration.

Affected Packages

npm @vitejs/plugin-rsc fix: 0.5.6

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in npm

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The vulnerability is a code-injection flaw (CWE-94) in the React Server Components integration layer of the Vite plugin ecosystem. In development mode, the plugin resolves server and client references by performing dynamic imports of module identifiers derived from request data; because the reference identifier is taken directly from the 'x-rsc-action' header and the serialized multipart FormData body consumed by loadServerAction/decodeReply/decodeAction, an attacker can supply a 'data:text/javascript,...' URL that Vite's dev-time module runner happily imports and evaluates. The patch commit fe634b58210d0a4a146a7faae56cd71af3bb9af4 addresses this by introducing a 'virtual:vite-rsc/reference-validation' module and a parseReferenceValidationVirtual helper; the rsc.tsx and ssr.tsx entry points now probe that virtual module before importing a reference, and the plugin's load handler errors with "[vite-rsc] invalid reference" when the supplied id does not match a known client or server reference registered in the manager's reference meta maps. New end-to-end tests assert that bogus references such as '__invalid_reference__' produce a 500 response instead of being imported, converting what was an arbitrary-import primitive into an allowlist check.

Know when Vite gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (github) PRIMARY 9.8 CRITICAL
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
vuln.today AI 9.8 CRITICAL

Reachable dev-server endpoint accepts attacker data: URLs with no auth or interaction (AV:N/AC:L/PR:N/UI:N) yielding full Node code execution (C:H/I:H/A:H); dev-only scope is not modeled by base metrics.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (github).

CVSS VectorVendor: github

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

DescriptionCVE.org

@vitejs/plugin-rs provides React Server Components (RSC) support for Vite. Versions 0.5.5 and below are vulnerable to arbitrary remote code execution on the development server through unsafe dynamic imports in server function APIs (loadServerAction, decodeReply, decodeAction) when integrated into RSC applications that expose server function endpoints. Attackers with network access to the development server can read/modify files, exfiltrate sensitive data (source code, environment variables, credentials), or pivot to other internal services. While this affects development servers only, the risk increases when using vite --host to expose the server on all network interfaces. This issue is fixed in version 0.5.6.

Executive ViewAI

Why It Matters

@vitejs/plugin-rsc 0.5.5 and earlier carries a critical remote code execution flaw that lets a remote attacker execute arbitrary JavaScript with Node.js privileges on a running Vite development server using React Server Components. Only development-mode servers are affected - production builds are not - but developer workstations and shared development hosts frequently hold source code, API keys, cloud tokens, and database credentials, so a single exposed dev server can become a stepping stone into the wider environment. Engineering teams that run 'vite --host' or otherwise expose dev ports beyond localhost should treat this as urgent, particularly given that proof-of-concept exploit code is publicly documented.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: bind Vite dev servers to loopback only and never use 'vite --host' on untrusted or shared networks; block inbound network access to dev ports via host firewall or security group; run dev servers only in isolated containers or VMs under a least-privileged non-root Node user without access to production data or secrets; avoid placing sensitive credentials in development environments; monitor dev server logs for anomalous x-rsc-action header values and data: URL module imports; and apply the vendor fix immediately once the @vitejs/plugin-rsc advisory publishes a remediated release.

Threat Intelligence Overview

EPSS Score
0.8%
Top 44% exploitable
Prevalence
Low
niche experimental React Server Components plugin, affects dev servers only
Data Quality
4 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC No
EPSS 0.8%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact
High

Priority Score

50
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +49
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

Code Injection CRITICAL

Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

More in Vite

View all
CVE-2025-31125 MEDIUM POC
5.3 Mar 31

Vite is a frontend tooling framework for javascript. Rated medium severity (CVSS 5.3), this vulnerability is remotely ex

CVE-2025-30208 MEDIUM POC
5.3 Mar 24

Vite, a provider of frontend development tooling, has a vulnerability in versions prior to 6.2.3, 6.1.2, 6.0.12, 5.4.15,

CVE-2024-52011 HIGH POC
7.5 Jun 01

launch-editor allows users to open files with line numbers in editor from Node.js. Rated high severity (CVSS 7.5), this

CVE-2024-23331 HIGH POC
7.5 Jan 19

Vite is a frontend tooling framework for javascript. Rated high severity (CVSS 7.5), this vulnerability is remotely expl

CVE-2023-34092 HIGH POC
7.5 Jun 01

Vite provides frontend tooling. Rated high severity (CVSS 7.5), this vulnerability is remotely exploitable, no authentic

CVE-2025-46565 MEDIUM POC
6.0 May 01

Vite is a frontend tooling framework for javascript. Rated medium severity (CVSS 6.0), this vulnerability is remotely ex

CVE-2023-49293 MEDIUM POC
6.1 Dec 04

Vite is a website frontend framework. Rated medium severity (CVSS 6.1), this vulnerability is remotely exploitable, no a

CVE-2022-35204 MEDIUM POC
4.3 Aug 18

Vitejs Vite before v2.9.13 was discovered to allow attackers to perform a directory traversal via a crafted URL to the v

CVE-2025-58751 LOW POC
2.3 Sep 08

Vite is a frontend tooling framework for JavaScript. Rated low severity (CVSS 2.3), this vulnerability is remotely explo

CVE-2025-58752 LOW POC
2.3 Sep 08

Vite is a frontend tooling framework for JavaScript. Rated low severity (CVSS 2.3), this vulnerability is remotely explo

CVE-2025-24010 MEDIUM POC
6.5 Jan 20

Vite is a frontend tooling framework for javascript. Rated medium severity (CVSS 6.5), this vulnerability is remotely ex

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy