LiveActive security incident?Get immediate response
CVE Record

CVE-2021-32820: File disclosure in Express Handlebars

Express-handlebars is a Handlebars view engine for Express. Express-handlebars mixes pure template data with engine configuration options through the Express render API. More specifically, the layout parameter may trigger file disclosure vulnerabilities in downstream applications. This potential vulnerability is somewhat restricted in that only files with existing extentions (i.e. file.extension) can be included, files that lack an extension will have .handlebars appended to them. For complete details refer to the referenced GHSL-2021-018 report. Notes in documentation have been added to help users avoid this potential information exposure vulnerability.

UnknownCVSS not scoredNot KEV-listedUpdated
Glexia's TakeAutomated analysismoderate

Security readout for executives and security teams

Plain-English summary

This issue can expose server-side files in Express applications using express-handlebars when application code lets request data influence template engine options, especially the layout setting. It is not described as a universal remote breach; exposure depends on how the downstream app calls rendering.

Executive priority

Treat as a targeted information disclosure risk. Prioritize internet-facing Express applications using express-handlebars, especially systems handling secrets, customer data, or operational configuration files.

Technical view

express-handlebars <= 5.3.2 mixes template data with engine configuration through Express render APIs. A user-influenced layout parameter can cause unintended file inclusion and disclosure. The reported behavior is restricted to files with existing extensions; extensionless names have .handlebars appended.

Likely exposure

Most likely exposed are Node.js Express applications using express-handlebars <= 5.3.2 and passing user-controlled objects or layout values into render calls on public routes.

Exploitation context

The bundle does not show CISA KEV listing or active exploitation evidence. Exploitability is application-dependent and requires a route where attacker-controlled input can reach express-handlebars configuration options such as layout.

Researcher notes

The advisory frames this as a potential downstream vulnerability caused by unsafe option/data mixing. Evidence is incomplete for broad exploitation, CVSS scoring, and exact fixed-version behavior in the supplied bundle, so validation should focus on application render patterns.

Mitigation direction

  • Review vendor documentation and GHSL guidance for safe express-handlebars render usage.
  • Avoid passing request query, body, or params directly into render options.
  • Whitelist allowed layout names instead of accepting arbitrary layout values.
  • Upgrade express-handlebars where your dependency policy supports it.
  • Audit public routes that render Handlebars templates with request-derived data.

Validation and detection

  • Inventory applications using express-handlebars and identify versions <= 5.3.2.
  • Review res.render call sites for request-controlled objects or layout values.
  • Confirm public routes cannot influence template engine configuration options.
  • Check dependency lockfiles and software composition analysis results.
  • Document any exposed render paths and their reachable user inputs.
Prepared
Confidence
medium
Sources
7

Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.

Potential ATT&CK relevance

Conservative CVE-to-ATT&CK context

These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.

ATT&CK lookup starting points

Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.

cwe · medium confidence lookup

CWE-200: Information exposure and cloud metadata lookup

Information exposure and SSRF weaknesses can make discovery, cloud metadata, and credential material review relevant. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.

Open ATT&CK lookup
cve · low confidence lookup

CVE-2021-32820 mapping review

Open the CVE-to-ATT&CK bridge for reviewed, inferred, or future official mappings tied to this CVE.

Open ATT&CK lookup
Vulnerability profileCVE Program record
Severity
Unknown
CVSS
Not scored
Known Exploited
No
Published
Official CVE source material

CNA and ADP enrichment extracted from CVE v5

These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.

0CVSS vectors
0Timeline events
0ADP providers
6Source links

CVSS and timeline data

No CVSS vectors or timeline events were available in the normalized CVE source material.

Affected products

Products and packages named in the record

VendorProductVersion / packageStatus
express-handlebarsexpress-handlebars<= 5.3.2Listed
Weakness

CWE details

CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.

CWE-200 · source CWE mapping

Exposure of Sensitive Information to an Unauthorized Actor

Exposure of Sensitive Information to an Unauthorized Actor represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.