# CVE-2026-106444: Handlebars: JavaScript Injection via Unsafe Inline Embedding of Precompiled Templates

- Severity: Medium 4.7 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.33%, higher than 28% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-10-06T19:01:14.626Z
- Modified: 2026-10-08T18:00:09.713Z
- Also known as: GHSA-xw65-4hp5-5hc7
- Weaknesses: CWE-116
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

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 JavaScript files are not affected. This issue is fixed in version 4.7.10.

(As written by CVE List.)

## Affected

- handlebars-lang handlebars.js: >= 4.0.0, < 4.7.10
- handlebars (npm): from 4.0.0 before 4.7.10

## Every score

- GitHub_M: CVSS:3.1 4.7 Medium `CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N`
- GitHub: CVSS:3.1 4.7 Medium `CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N`

## References

- <https://github.com/handlebars-lang/handlebars.js/security/advisories/GHSA-xw65-4hp5-5hc7> (exploit, web)
- <https://github.com/handlebars-lang/handlebars.js/pull/2185> (web)
- <https://github.com/handlebars-lang/handlebars.js/commit/609d1b11c833c9a3e00f56f2f34d22f425446725> (web)
- <https://github.com/handlebars-lang/handlebars.js/releases/tag/v4.7.10> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-106444> (advisory)
- <https://github.com/handlebars-lang/handlebars.js> (package)

## Sources

- CVE List: [CVE-2026-106444](https://www.cve.org/CVERecord?id=CVE-2026-106444), CVE Terms of Use, modified 2026-10-06
- GitHub Advisory Database: [GHSA-xw65-4hp5-5hc7](https://github.com/advisories/GHSA-xw65-4hp5-5hc7), CC-BY-4.0, modified 2026-10-08
- NVD: [CVE-2026-106444](https://nvd.nist.gov/vuln/detail/CVE-2026-106444), Public domain, modified 2026-10-07

---

Page: https://cve.day/CVE-2026-106444 · Whole record: https://cve.day/CVE-2026-106444.json · Rebuilt by cve.day 2026-11-25T22:59:42.505Z
