← Back to CVE Explorer

CVE-2025-12735

Full vulnerability record from the local CVENow database.

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 context object or use MEMBER of the context object into the evaluate() function and trigger arbitrary code execution.

Severity
CRITICAL
CVSS score
9.8 (v3.1)
Vulnerability status
Analyzed
Source identifier
Published
2025-11-05 01:15:33.313000
Last modified
2026-10-18 21:10:00.120000
View original CVE JSON
{
  "id": "CVE-2025-12735",
  "sourceIdentifier": "[email protected]",
  "published": "2025-11-05T01:15:33.313",
  "lastModified": "2026-10-18T21:10:00.120",
  "vulnStatus": "Analyzed",
  "cveTags": [],
  "descriptions": [
    {
      "lang": "en",
      "value": "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 context object or use MEMBER of the context object into the evaluate() function and trigger arbitrary code execution."
    },
    {
      "lang": "es",
      "value": "La biblioteca expr-eval es un analizador y evaluador de expresiones JavaScript diseñado para evaluar de forma segura expresiones matemáticas con variables definidas por el usuario. Sin embargo, debido a una validación de entrada insuficiente, un atacante puede pasar un objeto de contexto manipulado o usar MEMBER del objeto de contexto en la función evaluate() y desencadenar la ejecución de código arbitrario."
    }
  ],
  "affected": [
    {
      "source": "[email protected]",
      "affectedData": [
        {
          "vendor": "silentmatt",
          "product": "expr-eval",
          "versions": [
            {
              "version": "0",
              "lessThanOrEqual": "2.0.2",
              "versionType": "semver",
              "status": "affected"
            }
          ]
        },
        {
          "vendor": "expr-eval-fork",
          "product": "expr-eval-fork",
          "versions": [
            {
              "version": "0",
              "lessThanOrEqual": "3.0.0",
              "versionType": "semver",
              "status": "affected"
            }
          ]
        }
      ]
    }
  ],
  "metrics": {
    "cvssMetricV31": [
      {
        "source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
        "type": "Secondary",
        "cvssData": {
          "version": "3.1",
          "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
          "baseScore": 9.8,
          "baseSeverity": "CRITICAL",
          "attackVector": "NETWORK",
          "attackComplexity": "LOW",
          "privilegesRequired": "NONE",
          "userInteraction": "NONE",
          "scope": "UNCHANGED",
          "confidentialityImpact": "HIGH",
          "integrityImpact": "HIGH",
          "availabilityImpact": "HIGH"
        },
        "exploitabilityScore": 3.9,
        "impactScore": 5.9
      }
    ],
    "ssvcV203": [
      {
        "source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
        "ssvcData": {
          "timestamp": "2025-11-10T14:06:48.027568Z",
          "id": "CVE-2025-12735",
          "options": [
            {
              "exploitation": "poc"
            },
            {
              "automatable": "yes"
            },
            {
              "technicalImpact": "total"
            }
          ],
          "role": "CISA Coordinator",
          "version": "2.0.3"
        }
      }
    ]
  },
  "weaknesses": [
    {
      "source": "[email protected]",
      "type": "Primary",
      "description": [
        {
          "lang": "en",
          "value": "CWE-94"
        }
      ]
    }
  ],
  "configurations": [
    {
      "nodes": [
        {
          "operator": "OR",
          "negate": false,
          "cpeMatch": [
            {
              "vulnerable": true,
              "criteria": "cpe:2.3:a:jorenbroekema:javascript_expression_evaluator:3.0.0:*:*:*:*:node.js:*:*",
              "matchCriteriaId": "CDE513F1-E3F7-4FA9-BD2B-D310CA8853BD"
            },
            {
              "vulnerable": true,
              "criteria": "cpe:2.3:a:silentmatt:javascript_expression_evaluator:*:*:*:*:*:node.js:*:*",
              "versionEndIncluding": "2.0.2",
              "matchCriteriaId": "3236DF0B-3012-4193-82D6-9D73D24D723F"
            }
          ]
        }
      ]
    }
  ],
  "references": [
    {
      "url": "https://github.com/advisories/GHSA-jc85-fpwf-qm7x",
      "source": "[email protected]",
      "tags": [
        "Third Party Advisory"
      ]
    },
    {
      "url": "https://github.com/jorenbroekema/expr-eval",
      "source": "[email protected]",
      "tags": [
        "Product"
      ]
    },
    {
      "url": "https://github.com/silentmatt/expr-eval",
      "source": "[email protected]",
      "tags": [
        "Product"
      ]
    },
    {
      "url": "https://github.com/silentmatt/expr-eval/pull/288",
      "source": "[email protected]",
      "tags": [
        "Issue Tracking",
        "Patch"
      ]
    },
    {
      "url": "https://kb.cert.org/vuls/id/263614",
      "source": "[email protected]",
      "tags": [
        "Third Party Advisory"
      ]
    },
    {
      "url": "https://www.npmjs.com/package/expr-eval",
      "source": "[email protected]",
      "tags": [
        "Product"
      ]
    },
    {
      "url": "https://www.npmjs.com/package/expr-eval-fork",
      "source": "[email protected]",
      "tags": [
        "Product"
      ]
    },
    {
      "url": "https://www.kb.cert.org/vuls/id/263614",
      "source": "af854a3a-2127-422b-91ae-364da2661108",
      "tags": [
        "Third Party Advisory"
      ]
    },
    {
      "url": "https://github.com/jorenbroekema/expr-eval/blob/460b820ba01c5aca6c5d84a7d4f1fa5d1913c67b/test/security.js",
      "source": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
      "tags": [
        "Product"
      ]
    }
  ]
}