p PatchFirst

PatchFirst · Aktuelle Sicherheitslücken

Sicherheitslücken in node-handlebars

In den letzten 30 Tagen veröffentlichte Sicherheitslücken für node-handlebars: 3. Davon im KEV-Katalog: 0.

Sicherheitslücken filtern
Filter zurücksetzen

Sicherheitslücken: 14

  1. CVE-2026-106446

    Kritisch · CVSS 9.8EPSS 0,79%Keine Korrektur veröffentlicht

    Handlebars: JavaScript Injection via AST Type Confusion in compile (Program.blockParams)

    Handlebars provides the power necessary to let users build semantic templates. From 4.0.0 until 4.7.10, Handlebars.compile() and Handlebars.precompile() accept pre-parsed AST objects while validating only selected PathExpression, NumberLiteral, and BooleanLiteral values. This issue bypasses the AST validation introduced in version 4.7.9 for CVE-2026-33937. An attacker who can supply an object instead of a template string can place JavaScript expressions in unchecked values such as Program.blockParams.length, a non-PathExpression parameter depth, a non-string StringLiteral.value, or a non-string PathExpression.original. The compiler emits thos

    Veröffentlicht Aktualisiert
  2. CVE-2026-106445

    Kritisch · CVSS 9.2EPSS 0,59%Öffentlicher ExploitKeine Korrektur veröffentlicht

    Handlebars: JavaScript Injection via Own Property Check Bypass

    Handlebars provides the power necessary to let users build semantic templates. From 3.0.0 until 4.7.10, Handlebars lookupProperty returns Function.prototype.constructor before applying the prototype-access deny list because constructor is an own property of Function.prototype. When an attacker can render a controlled template with allowProtoMethodsByDefault enabled and an accessible function in the template context, the template can traverse from that function through its prototype to Function.prototype and then obtain the Function constructor through the own-property bypass. This permits attacker-controlled JavaScript to execute with the ser

    Veröffentlicht Aktualisiert
  3. CVE-2026-106444

    Mittel · CVSS 4.7EPSS 0,29%Keine Korrektur veröffentlicht

    Handlebars: JavaScript Injection via Unsafe Inline Embedding of Precompiled Templates

    Handlebars provides the power necessary to let users build semantic templates. From 4.0.0 until 4.7.10, Handlebars.precompile() uses quotedString() in lib/handlebars/compiler/code-gen.js to emit static template text into generated JavaScript without escaping sequences that terminate an enclosing HTML script element. When an application precompiles attacker-controlled template text and embeds the generated source directly in an inline script element, a closing script delimiter can end the element and cause following attacker-controlled markup to be parsed and executed. Ordinary server-side rendering and precompiled templates served as external

    Veröffentlicht Aktualisiert
  4. CVE-2026-33941

    Hoch · CVSS 8.3EPSS 0,3%Keine Korrektur veröffentlicht

    Handlebars.js has JavaScript Injection in CLI Precompiler via Unescaped Names and Options

    Handlebars provides the power necessary to let users build semantic templates. In versions 4.0.0 through 4.7.8, the Handlebars CLI precompiler (`bin/handlebars` / `lib/precompiler.js`) concatenates user-controlled strings — template file names and several CLI options — directly into the JavaScript it emits, without any escaping or sanitization. An attacker who can influence template filenames or CLI arguments can inject arbitrary JavaScript that executes when the generated bundle is loaded in Node.js or a browser. Version 4.7.9 fixes the issue. Some workarounds are available. First, validate all CLI inputs before invoking the precompiler. Rej

    Veröffentlicht Aktualisiert
  5. CVE-2026-33940

    Hoch · CVSS 8.1EPSS 0,71%Keine Korrektur veröffentlicht

    Handlebars.js has JavaScript Injection via AST Type Confusion when passing an object as dynamic partial

    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 looku

    Veröffentlicht Aktualisiert
  6. CVE-2026-33939

    Hoch · CVSS 7.5EPSS 0,63%Keine Korrektur veröffentlicht

    Handlebars.js has Denial of Service via Malformed Decorator Syntax in Template Compilation

    Handlebars provides the power necessary to let users build semantic templates. In versions 4.0.0 through 4.7.8, when a Handlebars template contains decorator syntax referencing an unregistered decorator (e.g. `{{*n}}`), the compiled template calls `lookupProperty(decorators, "n")`, which returns `undefined`. The runtime then immediately invokes the result as a function, causing an unhandled `TypeError: ... is not a function` that crashes the Node.js process. Any application that compiles user-supplied templates without wrapping the call in a `try/catch` is vulnerable to a single-request Denial of Service. Version 4.7.9 fixes the issue. Some w

    Veröffentlicht Aktualisiert
  7. CVE-2026-33938

    Hoch · CVSS 8.1EPSS 0,72%Keine Korrektur veröffentlicht

    Handlebars.js has JavaScript Injection via AST Type Confusion by tampering @partial-block

    Handlebars provides the power necessary to let users build semantic templates. In versions 4.0.0 through 4.7.8, the `@partial-block` special variable is stored in the template data context and is reachable and mutable from within a template via helpers that accept arbitrary objects. When a helper overwrites `@partial-block` with a crafted Handlebars AST, a subsequent invocation of `{{> @partial-block}}` compiles and executes that AST, enabling arbitrary JavaScript execution on the server. Version 4.7.9 fixes the issue. Some workarounds are available. First, use the runtime-only build (`require('handlebars/runtime')`). The `compile()` method i

    Veröffentlicht Aktualisiert
  8. CVE-2026-33937

    Kritisch · CVSS 9.8EPSS 1,91%Keine Korrektur veröffentlicht

    Handlebars.js has JavaScript Injection via AST Type Confusion

    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 `str

    Veröffentlicht Aktualisiert
  9. CVE-2026-33916

    Mittel · CVSS 4.7EPSS 0,28%Keine Korrektur veröffentlicht

    Handlebars.js has Prototype Pollution Leading to XSS through Partial Template Injection

    Handlebars provides the power necessary to let users build semantic templates. In versions 4.0.0 through 4.7.8, `resolvePartial()` in the Handlebars runtime resolves partial names via a plain property lookup on `options.partials` without guarding against prototype-chain traversal. When `Object.prototype` has been polluted with a string value whose key matches a partial reference in a template, the polluted string is used as the partial body and rendered without HTML escaping, resulting in reflected or stored XSS. Version 4.7.9 fixes the issue. Some workarounds are available. Apply `Object.freeze(Object.prototype)` early in application startup

    Veröffentlicht Aktualisiert
  10. CVE-2019-20920

    Hoch · CVSS 8.1EPSS 3,15%Keine Korrektur veröffentlicht

    CVE-2019-20920

    Handlebars before 3.0.8 and 4.x before 4.5.3 is vulnerable to Arbitrary Code Execution. The lookup helper fails to properly validate templates, allowing attackers to submit templates that execute arbitrary JavaScript. This can be used to run arbitrary code on a server processing Handlebars templates or in a victim's browser (effectively serving as XSS).

    Veröffentlicht Aktualisiert
  11. CVE-2019-19919

    Kritisch · CVSS 9.8EPSS 7,07%Keine Korrektur veröffentlicht

    CVE-2019-19919

    Versions of handlebars prior to 4.3.0 are vulnerable to Prototype Pollution leading to Remote Code Execution. Templates may alter an Object's __proto__ and __defineGetter__ properties, which may allow an attacker to execute arbitrary code through crafted payloads.

    Veröffentlicht Aktualisiert

Prüfen Sie Ihren Server

Gleichen Sie Ihren installierten Stack und seine Versionen mit den aktuellen Sicherheitsmeldungen ab.

Prüfen Sie Ihren Server →