CVE-2026-137162

LOWCVSS 2.1/10EPSS 0.23%

Last modified

CVE-2026-137162 is a low-severity vulnerability rated 2.1/10 on the CVSS scale. Inefficient Algorithmic Complexity vulnerability in leandrocp mdex allows an attacker who supplies Markdown to exhaust CPU via a long run of block quote markers when auto-close is enabled. When Markdown is rendered with auto_close: true or through MDEx.stream/2, MDEx.FragmentParser checks whether the last paragraph ends in an incomplete link reference definition. If that paragraph contains >, each line's leading quote prefix is expanded by expand_quote_prefix/2 in lib/mdex/fragment_parser.ex. EPSS estimates a 0.23% chance of exploitation in the next 30 days.

Description

Inefficient Algorithmic Complexity vulnerability in leandrocp mdex allows an attacker who supplies Markdown to exhaust CPU via a long run of block quote markers when auto-close is enabled. When Markdown is rendered with auto_close: true or through MDEx.stream/2, MDEx.FragmentParser checks whether the last paragraph ends in an incomplete link reference definition. If that paragraph contains >, each line's leading quote prefix is expanded by expand_quote_prefix/2 in lib/mdex/fragment_parser.ex. That function is body-recursive and prepends each character to the prefix built so far, copying it again for every leading space, tab or >, so a line of N such bytes costs O(N²). The prefix length is not bounded. A single line of a few hundred kilobytes of > ties up a scheduler for seconds, while the same input renders in milliseconds with auto-close off. This issue affects mdex: from 0.14.2 before 0.15.0.

Metrics

Weakness Enumeration

Affected Software

Source: CNA advisory (CVE.org). NVD analysis pending.

VendorProductVersions
leandrocpmdex>= 0.14.2, < 0.15.0
leandrocpmdex>= 9a4b76802bfcd12ba34337bf3cf7d62621d0fe92, < 2c29b28cd0473c24347aa00b95d16f9ce5f9d9af

References

Timeline

Published
Last Modified
Status
Received

Frequently Asked Questions

What is CVE-2026-137162?
Inefficient Algorithmic Complexity vulnerability in leandrocp mdex allows an attacker who supplies Markdown to exhaust CPU via a long run of block quote markers when auto-close is enabled. When Markdown is rendered with auto_close: true or through MDEx.stream/2, MDEx.FragmentParser checks whether the last paragraph ends in an incomplete link reference definition. If that paragraph contains >, each line's leading quote prefix is expanded by expand_quote_prefix/2 in lib/mdex/fragment_parser.ex. That function is body-recursive and prepends each character to the prefix built so far, copying it again for every leading space, tab or >, so a line of N such bytes costs O(N²). The prefix length is not bounded. A single line of a few hundred kilobytes of > ties up a scheduler for seconds, while the same input renders in milliseconds with auto-close off. This issue affects mdex: from 0.14.2 before 0.15.0.
How severe is CVE-2026-137162?
CVE-2026-137162 has a CVSS score of 2.1/10 (LOW severity). The EPSS model estimates a 0.23% probability of exploitation in the next 30 days.
How do I fix CVE-2026-137162?
Check the vendor references and advisories linked above for patched versions and mitigation guidance. You can also run a Strix scan to test if your systems are affected.

How Strix Helps

Related CVEs from 2026

Are you affected by CVE-2026-137162?

Run a free Strix scan to check your systems for this vulnerability.

Scan your code now

Source: NVD / NIST