CVE-2025-13204: expr-eval prototype pollution

CVE-2025-13204 · Severity: high · CVSS 7.3 · Published 2025-11-14

expr-eval is a popular JavaScript library for safely evaluating mathematical and logical expressions. A prototype pollution vulnerability allows attackers with access to the eval interface to manipulate JavaScript's prototype chain and achieve arbitrary code execution, potentially compromising systems that rely on this library for expression evaluation.

Vendors: npm, Silentmatt.

Quick answers

Is CVE-2025-13204 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2025-13204 being exploited in the wild.
How severe is CVE-2025-13204?
High severity, with a CVSS score of 7.3, published 14 November 2025.
Which products and versions are affected?
expr-eval-fork (npm) SEMVER:introduced=0,fixed=2.0.2.
Is there a fix for CVE-2025-13204?
Yes. expr-eval-fork (npm): upgrade to 2.0.2 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2025-13204 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2025-13204?
Check whether you run expr-eval-fork (npm) or Silentmatt Javascript Expression Evaluator at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • expr-eval-fork (npm): upgrade to 2.0.2 or later
    npm install expr-eval-fork@2.0.2

Technical details

expr-eval is vulnerable to prototype pollution (CWE-1321), a vulnerability in JavaScript's prototype-based inheritance model. An attacker with access to the expression evaluation interface can inject specially crafted payloads that manipulate the __proto__, prototype, or constructor properties to pollute the global object prototype. This enables arbitrary code execution in the context of the application. The vulnerability affects all versions of expr-eval up to and including 2.0.2, and is fixed in expr-eval-fork 2.0.2. The attack requires network access to the eval interface but no authentication, and the fix involves adding explicit checks to reject variable names matching /^__proto__|prototype|constructor$/.

Affected products

  • expr-eval up to 2.0.2

Identifiers

  • CVE-2025-13204
  • GHSA-8gw3-rxh4-v6jx

Timeline

  • 2025-11-14: disclosed
  • 2025-11-17: patched: Fixed in expr-eval-fork 2.0.2

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.