boxscore/security
CVE · referencelatest edition

Reference page — cumulative record through Sunday, October 4, 2026 UTC. Reference pages update as the archive grows; only dated daily editions are immutable pages of record.

CVE-2026-33940

handlebars-lang handlebars.js — Handlebars.js has JavaScript Injection via AST Type Confusion when passing an object as dynamic partial
  AV  AC  PR  UI  S  C  I  A   CVSS    EPSS   %ile   KEV
   N   H   N   N  U  H  H  H    8.1   .0079   54.8     —
AFFECTED
  Product        Versions             Fixed
  handlebars.js  >= 4.0.0, < 4.7.9 –  —
TIMELINE
  Mar 24  Reserved by GitHub_M
  Mar 27  Published (CNA: GitHub_M)
  Sep 1   EXPLOIT PUBLISHED — CVE-2026-33940 (handlebars-lang handlebars.js). Public exploit reference added.
  Sep 4   EXPLOIT PUBLISHED — CVE-2026-33940 (handlebars-lang handlebars.js). Public exploit reference added.
CWE-94, CWE-843 · CNA: GitHub_M · CVSS v3.1 · 8 references · NVD status: Modified

Description

Handlebars provides the power necessary to let users build semantic templates. In versions 4.0.0 through 4.7.8, a crafted object placed in the template context can bypass all conditional guards in `resolvePartial()` and cause `invokePartial()` to return `undefined`. The Handlebars runtime then treats the unresolved partial as a source that needs to be compiled, passing the crafted object to `env.compile()`. Because the object is a valid Handlebars AST containing injected code, the generated JavaScript executes arbitrary commands on the server. The attack requires the adversary to control a value that can be returned by a dynamic partial lookup. Version 4.7.9 fixes the issue. Some workarounds are available. First, use the runtime-only build (`require('handlebars/runtime')`). Without `compile()`, the fallback compilation path in `invokePartial` is unreachable. Second, sanitize context data before rendering: Ensure no value in the context is a non-primitive object that could be passed to a dynamic partial. Third, avoid dynamic partial lookups (`{{> (lookup ...)}}`) when context data is user-controlled.

Lifecycle

Complete event history — 4 events, chronological
DateEventDetail
March 24, 2026ReservedReserved by GitHub_M
March 27, 2026PublishedPublished (CNA: GitHub_M)
September 1, 2026EXPLOIT PUBLISHEDEXPLOIT PUBLISHED — CVE-2026-33940 (handlebars-lang handlebars.js). Public exploit reference added.
September 4, 2026EXPLOIT PUBLISHEDEXPLOIT PUBLISHED — CVE-2026-33940 (handlebars-lang handlebars.js). Public exploit reference added.

Affected

Affected products and packages — 1 row
VendorProduct / PackageEcosystemVersion introducedFixed
handlebars-langhandlebars.js—>= 4.0.0, < 4.7.9—

Weaknesses

CWE-94 · CWE-843

References (8)

Related

Authoritative record: CVE-2026-33940 at cve.org

Vendors: handlebars-lang

Weaknesses: CWE-94 · CWE-843

About this page

This is a reference page, not a dated page of record. It assembles the complete lifecycle of CVE-2026-33940 from the CVE Program record, NVD enrichment, the CISA KEV catalog, EPSS, and OSV advisories. The box score's numbers (CVSS, EPSS, KEV status) are current as of Sunday, October 4, 2026 UTC and are re-derived as the archive grows; only dated daily editions are immutable pages of record. The authoritative source for this identifier is cve.org.