BaselineWatch
Desk

CVE-2026-4800

9.8 critical exploit ×2 SSVC exploitation: none Modified

The fix for CVE-2021-23337 added validation for the variable option in _.template but did not apply the same validation to options.imports key names, and both paths flow into the same Function() constructor sink. When an application passes untrusted input as options.imports key names, an attacker can inject default-parameter expressions that execute arbitrary code at template compilation time. Additionally, _.template uses assignInWith to merge imports, which enumerates inherited properties via for..in, so if Object.prototype has been polluted by another vector the polluted keys are copied into the imports object and passed to Function(). The issue is fixed in 4.18.1 for lodash, lodash-es, lodash-amd, and lodash.template. As a workaround, do not pass untrusted input as key names in options.imports; use only developer-controlled, static key names.

Fix

Nothing published yet: no patch, vendor advisory or mitigation reference on NVD, no vendor advisory in the News for this CVE, not in CISA's KEV, no fixed package version. BaselineWatch does not guess at one.

Public exploits 2

Each line links to the index that lists it, never to exploit code. Exploit-DB's "verified" and a Metasploit rank of good or better count as verified; a PoC-in-GitHub entry is a repository's claim.

Change history 1

  1. First seenCVSS 9.8 · lodashNVD modified 2026-10-15 07:18

Affected (CPE criteria) 4

  • cpe:2.3:a:lodash:lodash:*:*:*:*:*:node.js:*:*
  • cpe:2.3:a:lodash:lodash-amd:*:*:*:*:*:node.js:*:*
  • cpe:2.3:a:lodash:lodash-es:*:*:*:*:*:node.js:*:*
  • cpe:2.3:a:lodash:lodash.template:*:*:*:*:*:node.js:*:*

References 80