Arbitrary Code Injection Affecting lodash-es package, versions <4.18.1


Severity

Recommended
0.0
high
0
10

CVSS assessment by Snyk's Security Team. Learn more

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Arbitrary Code Injection vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-JS-LODASHES-15869627
  • published1 Apr 2026
  • disclosed31 Mar 2026
  • creditYuki Shiroi, Mundur, dolevmiz1

Introduced: 31 Mar 2026

NewCVE-2026-4800  (opens in a new tab)
CWE-94  (opens in a new tab)

How to fix?

Upgrade lodash-es to version 4.18.1 or higher.

Overview

Affected versions of this package are vulnerable to Arbitrary Code Injection due the improper validation of options.imports key names in _.template. An attacker can execute arbitrary code at template compilation time by injecting malicious expressions. If Object.prototype has been polluted, inherited properties may also be copied into the imports object and executed.

Notes:

  1. Version 4.18.0 was intended to fix this vulnerability but it got deprecated due to introducing a breaking functionality issue.

  2. This issue is due to the incomplete fix for CVE-2021-23337.

CVSS Base Scores

version 4.0
version 3.1