Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSubmit crafted Markdown to streaming endpoint
-
DeliveryHTML block of N openers plus N unmatched closers
-
Exploitclose_html_tag re-scans unbounded tag list per closer
-
ExecutionO(N²) work in FragmentParser
-
PersistBEAM scheduler CPU exhausted
-
Impactdenial of service
Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V2 - Validation and Business Logic Algorithmic complexity limits
|
| Exploitation Conditions | Requires that the application invoke the streaming entry point MDEx.stream/2 on attacker-controlled Markdown; the per-HTML-block tag tracking runs regardless of the auto_close option or the render-unsafe setting, so no special configuration enables it. Affected versions are mdex 0.14.0 up to (not including) 0.15.0. Significant LIMITING factors: only the streaming API is vulnerable - MDEx.to_html/1 and other non-streaming entry points are explicitly NOT affected - so an application that never exposes stream/2 to untrusted input is not at risk, and the only complete fix per the vendor is upgrading to 0.15.0. Practical attack cost is low: about 270 KB of crafted input sustains tens of seconds of scheduler CPU. |
| Impact | This is a denial-of-service (availability) issue, not the information disclosure its tag suggests: CWE-407 algorithmic complexity with CVSS 4.0 impact VC:N/VI:N/VA:H confirms CPU exhaustion only, no confidentiality or integrity impact. The vendor vector is AV:L/AC:L/AT:N/PR:N/UI:N (6.9, medium) and the vuln.today decision label is 'this_month' - a real but non-emergency priority. A key signal conflict exists on attack vector: the vendor chose AV:L, yet the described trigger is 'an attacker who controls Markdown passed to MDEx.stream/2', which in the common deployment (a web application streaming untrusted user-submitted Markdown) is reachable over the network - so AV:N is arguably more accurate and the effective exposure depends on whether untrusted Markdown reaches stream/2 remotely; verify against your own usage. EPSS is not provided, KEV status is not listed (treat as not KEV), and no PoC or exploit reference is present - only the fix commits and the EEF/erlef advisory. The upside for defenders: exploitation is contained to the streaming API; MDEx.to_html/1 and other non-streaming entry points are explicitly unaffected, and the flaw is independent of the auto_close and render-unsafe options, so there is no configuration-based mitigation short of updating. Overall this is a low-cost, high-reliability DoS against a niche Elixir library - meaningful for apps that stream attacker-controlled Markdown, low concern otherwise. |
| Exploit ScenarioDerived | An application calls MDEx.stream/2 on Markdown supplied by an untrusted user. The attacker submits a single HTML block containing N opening tags followed by N unmatched closing tags; each unmatched closer re-scans the unbounded open-tag list, producing O(N²) work so that roughly 270 KB of input ties up a BEAM scheduler for tens of seconds. No public exploit code is identified at time of analysis, but the quadratic trigger is fully described in the fix commit and trivially reproducible. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Nov 30, 2026
CPU exhaustion in the Elixir Markdown library MDEx 0.14.x lets unauthenticated remote attackers burn scheduler time by streaming crafted HTML through MDEx.stream/2. Roughly 270 KB of Markdown consisting of N opening tags followed by N unmatched closing tags drives the tag-tracking routine into O(N²) work and keeps a BEAM scheduler busy for tens of seconds per request, and the flaw fires regardless of the auto_close option or the render-unsafe setting. Only the streaming entry point is affected - MDEx.to_html/1 and the other non-streaming functions are explicitly not vulnerable - so exposure depends on whether an application feeds untrusted Markdown to stream/2. This is a denial-of-service issue (CWE-407, availability-only impact); no public exploit has been identified at time of analysis, and MDEx 0.15.0 is the vendor's complete fix.
RemediationAI
Upgrade MDEx to 0.15.0, which is the vendor's complete fix and the version that carries the rewritten fragment-parser context tracking (upstream commits 2c29b28cd0473c24347aa00b95d16f9ce5f9d9af and a88793cb0fc5caf75bf878b92c64d36817824765). Because the per-HTML-block tracking runs regardless of the auto_close option and the render unsafe setting, no configuration workaround exists inside the vulnerable release; the vendor states that updating is the only complete fix. As a compensating control, avoid passing attacker-controlled Markdown to MDEx.stream/2 - route untrusted input through MDEx.to_html/1 or another non-streaming entry point, which are not affected, at the cost of losing incremental/chunked rendering for that input path. Where streaming must be retained for untrusted content, cap request and document size and rate-limit the producing endpoint; note that this only raises the bar, since roughly 270 KB of crafted input is enough to occupy a scheduler for tens of seconds, so size limits must be set well below that threshold and are not a substitute for the upgrade. Segmentation or isolating the Markdown-rendering workload onto dedicated BEAM nodes limits collateral scheduling pressure but does not remove the O(N²) cost itself.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
MDEx is an Elixir Markdown library that exposes both a one-shot HTML renderer (MDEx.to_html/1) and an incremental streaming API (MDEx.stream/2). To cope with fragments split across chunk boundaries, the streaming path maintains an HTML context in MDEx.FragmentParser.continue_html_context/2 (lib/mdex/fragment_parser.ex): every non-void opening tag is pushed onto an unbounded list, and close_html_tag/2 resolves a closer by scanning that list with Enum.split_while/2 until it finds a matching opener. A closing tag with no matching opener leaves the list untouched, so each subsequent unmatched closer re-walks the entire accumulated stack - an HTML block of N openers plus N unmatched closers costs O(N²). Because the tracking runs on every HTML block and every inline HTML literal, it is not gated by the auto_close option or the render unsafe setting; no configuration toggle disables it. CWE-407 (Inefficient Algorithmic Complexity) is the correct root-cause class, and the CVSS 4.0 impact metrics (VC:N/VI:N/VA:H) confirm availability-only damage: no confidentiality or integrity effect, which contradicts the misleading 'Information Disclosure' tag on this record. The upstream fix restructures each context entry as {tag, open_tags} so the set of currently open tags is available in a map and a closer without a matching opener returns immediately instead of walking the stack; the same commit batch also removes several unrelated quadratic regex constructs (paragraph-label line splitting, tilde fence handling, quote-prefix expansion, and link-opener filtering) that shared the same complexity profile.
Know when Elixir gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
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
Untrusted Markdown typically reaches stream/2 over the network (AV:N vs vendor AV:L), needs no auth or interaction (PR:N/UI:N), is trivially triggered (AC:L), and only exhausts CPU (A:H, C/I:N).
Primary rating from Vendor (6b3ad84c-e1a6-4bf7-a703-f496b71e49db).
CVSS VectorVendor: 6b3ad84c-e1a6-4bf7-a703-f496b71e49db
Lifecycle Timeline
1DescriptionCVE.org
Inefficient Algorithmic Complexity vulnerability in leandrocp mdex allows an attacker who controls Markdown passed to MDEx.stream/2 to exhaust CPU via unmatched HTML closing tags.
MDEx.stream/2 tracks open HTML tags with MDEx.FragmentParser.continue_html_context/2 in lib/mdex/fragment_parser.ex. Every non-void opening tag is pushed onto an unbounded list, and close_html_tag/2 scans the whole list for each closing tag. A closer with no matching opener leaves the list unchanged, so the next closer scans it again. An HTML block of N openers followed by N unmatched closers therefore costs O(N²), and about 270 KB of input keeps a scheduler busy for tens of seconds. The tracking runs on every HTML block and inline HTML literal regardless of the auto_close option and the render unsafe setting. MDEx.to_html/1 and the other non-streaming entry points are not affected.
This issue affects mdex: from 0.14.0 before 0.15.0.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.
Unbounded recursion in the Elixir `protobuf` Hex package (versions >= 0.8.0, < 0.16.1) lets unauthenticated remote attac
Remote code execution in the Elixir Flop pagination library affects versions 0.8.0 through 0.26.6, 0.27.0 through 0.27.2
Improper JWT signature verification in Dashbit's nimble_zta (0.1.2 up to but not including 0.1.3) lets an unauthenticate
Session-swapping authentication bypass in the Elixir library AshAuthentication (versions 4.10.0 before 4.15.0 and 5.0.0-
Account takeover in AshAuthentication (Elixir/Ash) 4.14.0 through 4.14.x and 5.0.0-rc.10 through 5.0.0-rc.13 lets unauth
Authentication bypass in the Elixir library ash_authentication lets an attacker who operates one federated identity-prov
Server-Side Request Forgery protection bypass in the Elixir safeurl library (versions 0.1.0 and later) allows unauthenti
Arbitrary code execution in applications running the Elixir db_connection library 1.1.0 through 2.10.2 is possible when
Unauthenticated remote CPU exhaustion in mtrudel Bandit's HTTP/2 server (versions before 1.14.0) is achievable by holdin
Unbounded per-connection memory and CPU growth in the Elixir Bandit HTTP/2 server (0.3.6 up to 1.14.0) lets an unauthent
Unauthenticated remote denial of service in the Elixir HTTP server Bandit (mtrudel/bandit) from 0.1.0 before 1.14.0 lets
Unauthenticated remote attackers can consume disproportionate server CPU on Bandit (mtrudel/bandit, Elixir/Erlang) by se
EUVD-2026-139639
GHSA-6843-mw9g-x99r
NVD
CVE.org
EPSS
Exploit-DB