LiveActive security incident?Get immediate response
CVE Record

CVE-2026-12866: All versions of the package expr-eval are vulnerable to Code Execution via the toJSFunction() API.

All versions of the package expr-eval are vulnerable to Code Execution via the toJSFunction() API. An attacker can execute arbitrary JavaScript by supplying crafted expressions that are compiled into native code using new Function(). Because user-controlled expressions are transformed directly into executable JavaScript, attackers can escape the intended expression sandbox and run arbitrary code within the application's context.

CriticalCVSS 9.8Not KEV-listedUpdated
Glexia's TakeAutomated analysiscritical

Security readout for executives and security teams

Plain-English summary

expr-eval can turn attacker-controlled expressions into arbitrary JavaScript when an application uses toJSFunction(). Successful exploitation could let an unauthenticated remote attacker act with the application’s permissions, potentially exposing data, changing information, or disrupting service. Risk depends on whether untrusted input reaches this API.

Executive priority

Treat as urgent where internet-facing or otherwise untrusted input reaches toJSFunction(). Prioritize rapid exposure tracing and containment because reported impact spans confidentiality, integrity, and availability. Systems carrying the dependency without that data flow require investigation, not automatic assumptions of compromise.

Technical view

CVE-2026-12866 is a CWE-94 code-injection vulnerability. Crafted expressions passed through toJSFunction() are compiled with new Function(), allowing escape from the intended expression sandbox and execution within the application context. The supplied record reports all expr-eval versions and the org.webjars.npm packaging as affected, with CVSS 3.1 score 9.8.

Likely exposure

Highest exposure exists where direct or transitive expr-eval usage sends user-controlled expressions to toJSFunction(), especially through remotely reachable functionality. Merely installing the package does not establish exploitability. Both the npm package and its WebJars distribution should be inventoried.

Exploitation context

The supplied bundle does not identify known active exploitation, and the CVE is not marked as CISA KEV. Exploitation is described as remote, low complexity, unauthenticated, and requiring no user interaction, but only when an application exposes the vulnerable data flow.

Researcher notes

The core evidence links risk to toJSFunction() and new Function(). The bundle reports all versions affected but provides no confirmed patched version, formal vendor mitigation, or evidence of exploitation in the wild. Validate reachability and input control before classifying an installed dependency as exploitable.

Mitigation direction

  • Identify direct and transitive expr-eval and org.webjars.npm:expr-eval dependencies.
  • Stop passing untrusted or externally influenced expressions to toJSFunction().
  • Disable affected functionality where the unsafe data flow cannot be removed immediately.
  • Check maintainer and package-distributor guidance for an approved fix or replacement.
  • Do not assume a routine version upgrade resolves an all-versions advisory.

Validation and detection

  • Search application code and dependencies for expr-eval and its WebJars packaging.
  • Locate every toJSFunction() call and trace expression inputs to their origin.
  • Confirm whether any affected input is reachable without authentication or user interaction.
  • Verify mitigations prevent untrusted expressions from reaching native JavaScript compilation.
  • Retest affected features after remediation without using offensive payloads.
Prepared
Confidence
medium
Sources
6

Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.

Potential ATT&CK relevance

Conservative CVE-to-ATT&CK context

These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.

ATT&CK lookup starting points

Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.

cwe · medium confidence lookup

CWE-94: Code execution behavior lookup

Code execution and unsafe deserialization weaknesses often justify reviewing execution behavior and process telemetry. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.

Open ATT&CK lookup
description · low confidence lookup

Execution behavior lookup

The CVE wording references code or command execution, so execution technique review may help defensive triage. This is a Glexia inferred lookup path, not an official MITRE, ATT&CK, or CVE Program mapping.

Open ATT&CK lookup
cve · low confidence lookup

CVE-2026-12866 mapping review

Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.

Open ATT&CK lookup
Vulnerability profileCVE Program record
Severity
Critical
CVSS
9.8 (3.1)
Known Exploited
No
Published

Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Official CVE source material

CNA and ADP enrichment extracted from CVE v5

These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.

2CVSS vectors
3Timeline events
1ADP providers
5Source links

SSVC decision data

CISA-ADPCISA Coordinator
Timestamp
Version
2.0.3
Exploitation: pocAutomatable: yesTechnical Impact: total

CVSS vector scores

2 official scores

We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.

ScoreVersionSeverityVectorExploitImpactSource
9.8CVSS 3.1CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H3.95.9snyk
9.2CVSS 4.0CriticalCVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:Nsnyk

Vulnerability scoring details

Base CVSS 4.0 score

9.2Critical
CVSS 4.0 vector shape for CVE-2026-12866Attack VectorAttack ComplexityAttack RequirementsPrivileges RequiredUser InteractionVS ConfidentialityVS IntegrityVS AvailabilitySS ConfidentialitySS IntegritySS Availability

Vector: CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Attack Vector
NetworkAdjacentLocalPhysical
Attack Complexity
LowHigh
Attack Requirements
NonePresent
Privileges Required
NoneLowHigh
User Interaction
NonePassiveActive
VS Confidentiality
HighLowNone
VS Integrity
HighLowNone
VS Availability
HighLowNone
SS Confidentiality
HighLowNone
SS Integrity
HighLowNone
SS Availability
HighLowNone

Vulnerability timeline

Timeline events are normalized from CVE metadata, CNA source timelines, ADP timelines, and KEV metadata when present.

  1. CVE reservedCVE Program

    The CVE ID was reserved by the assigning CNA.

  2. CVE publishedCVE Program

    The CVE record was published.

  3. CVE updatedCVE Program

    The CVE record metadata indicates this as the latest update time.

ADP provider summaries

CISA-ADPCISA ADP Vulnrichment
other:ssvc
Affected products

Products and packages named in the record

VendorProductVersion / packageStatus
n/aexpr-eval0Listed
n/aorg.webjars.npm:expr-eval0Listed
Weakness

CWE details

CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.

CWE-94 · source CWE mapping

Improper Control of Generation of Code ('Code Injection')

Improper Control of Generation of Code ('Code Injection') represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.