#VU124840 Code Injection in handlebars.js - CVE-2026-33940

 

#VU124840 Code Injection in handlebars.js - CVE-2026-33940

Published: April 2, 2026


Vulnerability identifier: #VU124840
Vulnerability risk: High
CVSSv4.0: 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/E:U/U:Amber
CVE-ID: CVE-2026-33940
CWE-ID: CWE-94
Exploitation vector: Remote access
Exploit availability: No public exploit available
Vulnerable software:
handlebars.js
Software vendor:
The Handlebars Templating Language

Description

The vulnerability allows a remote attacker to execute arbitrary code.

The vulnerability exists due to improper control of code generation caused by type confusion in dynamic partial handling in lib/handlebars/runtime.js when processing a dynamic partial lookup that returns a crafted object from the template context. A remote attacker can supply a crafted object as the looked-up dynamic partial value to execute arbitrary code.

The issue affects server-side rendering scenarios in which user-controlled context data can be returned by a dynamic partial lookup, such as {{> (lookup . "key")}}. Exploitation requires control over a value returned by the dynamic partial lookup.


Remediation

Install security update from vendor's website.

External links