GitHub Advisoryadvisory · npm

GHSA-jc85-fpwf-qm7x expr-eval does not restrict functions passed to the evaluate function

HIGH Published 2025-11-05 Modified 2025-12-09 Official page ↗
Aliases
CVE-2025-12735
Ecosystem
npm
Packages
expr-eval, expr-eval-fork
Severity
High
CVSS vector
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Weaknesses
CWE-94
Reviewed
2025-11-05

Affected packages

• npm expr-eval: <= 2.0.2 (no fix yet) • npm expr-eval-fork: < 3.0.1 → fixed in 3.0.1

Description

The expr-eval library is a JavaScript expression parser and evaluator designed to safely evaluate mathematical expressions with user-defined variables. However, due to insufficient input validation, an attacker can pass a crafted variables object into the evaluate() function and trigger arbitrary code execution.

Related

Alias · CVE (1)

  • CVE-2025-12735 The expr-eval library is a JavaScript expression parser and evaluator designed to safely evaluate mathematical expressions with… vulnerability

Weakness · CWE (1)

  • CWE-94 Improper Control of Generation of Code weakness

References