CVE-2026-41311
Received Received - Intake
Memory Exhaustion in LiquidJS via Circular Block References

Publication date: 2026-05-09

Last updated on: 2026-05-09

Assigner: GitHub, Inc.

Description
LiquidJS is a Shopify / GitHub Pages compatible template engine in pure JavaScript. Prior to version 10.25.7, a circular block reference in {% layout %} / {% block %} causes an infinite recursive loop, consuming all available memory (~4GB) and crashing the Node.js process with FATAL ERROR: JavaScript heap out of memory. This allows any user who can submit a Liquid template to perform a Denial of Service attack. This issue has been patched in version 10.25.7.
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-05-09
Last Modified
2026-05-09
Generated
2026-05-09
AI Q&A
2026-05-09
EPSS Evaluated
N/A
NVD
EUVD
Affected Vendors & Products
Showing 2 associated CPEs
Vendor Product Version / Range
harttle liquidjs to 10.25.7 (exc)
harttle liquidjs 10.25.7
Helpful Resources
Exploitability
CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-674 The product does not properly control the amount of recursion that takes place, consuming excessive resources, such as allocated memory or the program stack.
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?

CVE-2026-41311 is a Denial of Service (DoS) vulnerability in the LiquidJS library affecting versions 10.25.2 and earlier.

The issue arises from a circular block reference in the {% layout %} and {% block %} tags, which creates an infinite recursive loop during template rendering.

This loop consumes excessive memory (up to approximately 4GB) and crashes the Node.js process with a "JavaScript heap out of memory" error.

The vulnerability occurs when a block with the same name is nested inside another block of the same name in a child template.

Any user who can submit a Liquid template can exploit this vulnerability without authentication or special configuration.


How can this vulnerability impact me? :

This vulnerability can cause a complete Denial of Service by crashing the Node.js process due to memory exhaustion.

It consumes all available memory (around 4GB), leading to a fatal error and service disruption.

Applications that accept user-provided Liquid templates, such as CMS platforms, email template builders, or static site generators, are particularly vulnerable.

The attack requires no privileges or user interaction, making it easy for any user submitting templates to cause service outages.


How can this vulnerability be detected on my network or system? Can you suggest some commands?

This vulnerability can be detected by monitoring for crashes of the Node.js process accompanied by a "JavaScript heap out of memory" error, which indicates excessive memory consumption caused by infinite recursive loops in LiquidJS templates.

Specifically, detection involves identifying if any submitted Liquid templates contain circular block references where a block with the same name is nested inside another block of the same name, triggering the recursion.

Commands to help detect this issue could include monitoring Node.js process logs for memory errors and using tools to analyze template submissions for nested blocks with identical names.

  • Check Node.js process logs for the error message: "FATAL ERROR: JavaScript heap out of memory".
  • Use process monitoring commands like `top`, `htop`, or `ps` to observe unusually high memory usage by Node.js processes.
  • If possible, scan submitted Liquid templates for nested {% block %} tags with the same name inside each other, which can be done with custom scripts or template validation tools.

What immediate steps should I take to mitigate this vulnerability?

The immediate mitigation step is to upgrade the LiquidJS library to version 10.25.7 or later, where this vulnerability has been patched.

Until the upgrade can be applied, restrict or validate user-submitted Liquid templates to prevent circular block references that cause infinite recursion.

Additionally, monitor Node.js processes for memory usage and crashes to quickly detect exploitation attempts.


How does this vulnerability affect compliance with common standards and regulations (like GDPR, HIPAA)?:

CVE-2026-41311 is a Denial of Service (DoS) vulnerability in the LiquidJS library that allows any user who can submit a Liquid template to crash the Node.js process by causing an infinite recursive loop and memory exhaustion.

While the vulnerability severely impacts availability by enabling service disruption, there is no direct information provided about the exposure or compromise of personal data or sensitive information.

Therefore, the vulnerability primarily affects system availability, which could indirectly impact compliance with standards like GDPR or HIPAA if the affected service is critical for processing or protecting personal or health data.

However, no explicit details are given about data breaches or confidentiality impacts that would directly violate these regulations.


Ask Our AI Assistant
Need more information? Ask your question to get an AI reply (Powered by our expertise)
0/70
EPSS Chart