#VU124846 Time-of-check Time-of-use (TOCTOU) Race Condition in handlebars.js
Published: April 2, 2026
handlebars.js
The Handlebars Templating Language
Description
The vulnerability allows a remote attacker to disclose sensitive information.
The vulnerability exists due to a time-of-check time-of-use race condition in the container.lookup function in lib/handlebars/runtime.js when processing property lookups with the compat compile option enabled. A remote attacker can trigger a crafted property lookup to disclose sensitive information.
This issue affects handlebars.js when {compat: true} enables depthedLookup, and the vulnerable code validates access through lookupProperty() but then performs a separate raw property read.