All vulnerabilities

Hex

CVE-2026-134916

Quadratic CPU consumption in MDEx Quill Delta conversion of nested block quotes

Severity
Medium 6.9
Published
30 Nov 2026
Last changed
30 Nov 2026
Added to UpHeron
30 Nov 2026
Fixed in
0.15.0
Weakness
Inefficient algorithmic complexity (CWE-407)
Attack
Needs local access · No login needed · No user action needed
Attacker can
Take it down
CVSS vector
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
Sources
CVE Program

Description

Inefficient Algorithmic Complexity vulnerability in leandrocp mdex allows an attacker who controls Markdown input to cause a denial of service through CPU exhaustion via deeply nested block quotes passed to MDEx.to_delta/2.

When converting a document to a Quill Delta, MDEx.DeltaConverter.default_convert_node/3 in lib/mdex/delta_converter.ex calls apply_block_format/2 for every MDEx.BlockQuote and MDEx.Alert node, and that function rewrites every op produced by the node's descendants. Conversion therefore costs the nesting depth times the number of ops inside, and the parser places no limit on block quote depth. A document of a few hundred kilobytes keeps a scheduler busy for minutes, while parsing and HTML rendering of the same input finish in milliseconds. The parse_time budget bounds only the native parse, not the conversion.

This issue affects mdex: from 0.8.3 before 0.15.0.

From the CVE Program.

Affected software

SoftwareAffected versions
mdexHex · osv:Hex:mdex
  • From 0.8.3 before 0.15.0

About mdex

References

  • CVE.org https://www.cve.org/CVERecord?id=CVE-2026-134916