9.8

CVE-2026-33937: handlebars-lang handlebars.js Code Injection

CVSS: 9.8v3.1CriticalModified
AliasesUBUNTU-CVE-2026-33937DEBIAN-CVE-2026-33937CGA-22qg-f499-9xx7
Published 27-03-2026Last modified 04-09-2026

Vulnerability summary

CVE-2026-33937 is a critical (CVSS 9.8) Code Injection vulnerability in handlebars-lang handlebars.js. EPSS estimates a 1.74% chance of exploitation in the next 30 days, higher than 77.3% of scored vulnerabilities. 1 public exploit is recorded.

Overall risk
70/100
0100
High · default modelHow is this calculated?
CVSS score
9.8/10
010
Critical · v3.1 (CVE.org)
EPSS score
1.74%
0%100%
Low · +0.03 pp in 30 days
KEVNot listedIn no KEV catalog
RansomwareNone recordedNo known use recorded
Public exploits1github

Advisory lineage

Upstream 0 · Downstream 0 · Related 1

Timeline

  1. 27-03-2026
    PublishedVulnerability first disclosed.
  2. 04-09-2026
    Last modifiedVulnerability information updated.

Description

Handlebars provides the power necessary to let users build semantic templates. In versions 4.0.0 through 4.7.8, `Handlebars.compile()` accepts a pre-parsed AST object in addition to a template string. The `value` field of a `NumberLiteral` AST node is emitted directly into the generated JavaScript without quoting or sanitization. An attacker who can supply a crafted AST to `compile()` can therefore inject and execute arbitrary JavaScript, leading to Remote Code Execution on the server. Version 4.7.9 fixes the issue. Some workarounds are available. Validate input type before calling `Handlebars.compile()`; ensure the argument is always a `string`, never a plain object or JSON-deserialized value. Use the Handlebars runtime-only build (`handlebars/runtime`) on the server if templates are pre-compiled at build time; `compile()` will be unavailable.

CVSS metrics

7 scores · 7 sources · 1 version

EPSS trend

Probability

1.74%

Chance of exploitation in the next 30 days

Percentile

77%

Versus all other CVEs

30-day change

+0.03 pp

From 1.70% on 18-09-2026

18-09-202618-10-2026
EPSS score
1.74%

Known exploited

Compare KEV catalogs

Not in any of the 3 tracked catalogs.

Public exploits

1 found
  • githubUnverified

    Handlebars.Js

    Maturity: poc

Weaknesses

CWE · root cause

Affected systems

Chainguard62 products
  • gitlab-rails-ce-18.1< 18.1.6-r14
  • gitlab-rails-ce-18.10All versions (No fix recorded)
  • gitlab-rails-ce-18.11< 18.11.6-r2
  • gitlab-rails-ce-18.5All versions (No fix recorded)
  • gitlab-rails-ce-18.6All versions (No fix recorded)
Wolfi11 products
  • jupyter-base-notebook< 7.6.3-r2
  • lerna< 9.0.7-r2
  • nextcloud-server-32< 32.0.12-r1
  • opensearch-dashboards-3< 3.5.0-r12
  • prism< 5.14.3-r13
Debian1 product
  • node-handlebarsAll versions (No fix recorded) | < 3:4.7.9-1
Handlebars-lang1 product
Handlebarsjs1 product
Npm1 product
  • handlebars≥ 4.0.0, < 4.7.9
Ubuntu1 product
  • node-handlebarsAll versions (No fix recorded)

7 vendors · 78 products

References

14 links
Show all 14 references