Skip to main content

Snarkdown CVE-2026-141601

| EUVDEUVD-2026-140781 MEDIUM
Inefficient Algorithmic Complexity (CWE-407)
2026-12-02 VulnCheck GHSA-g7pj-cv79-vpp8
6.9
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Submit crafted Markdown with many links
  2. Exploit
    Trigger quadratic link rescanning in parse()
  3. Impact
    Block event loop and deny service

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V2 - Validation and Business Logic Algorithmic complexity limits
Exploitation Conditions

Requires that the host application pass attacker-controllable Markdown to snarkdown's parse() in src/index.js; the specific trigger is input containing many links or deeply nested '[' brackets, which forces repeated rescans of the full accumulated HTML output (quadratic cost). No special snarkdown configuration, authentication, or user interaction is needed (PR:N/UI:N). What LIMITS real impact: the denial of service matters only where parsing runs server-side and synchronously (Node.js), where blocking the single event loop denies service to all clients; in purely client-side/browser use the hang is confined to the submitting user. Affected versions are snarkdown through 2.0.0; updating to the patched release (PR #118) is the fix.

Impact

Signals point to a genuine but bounded issue. The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N) shows a network-reachable, low-complexity, unauthenticated trigger, but the only impact is availability at Low (VA:L) with no confidentiality or integrity effect - consistent with CWE-407 algorithmic complexity rather than code execution, so the 6.9/Medium score is driven by ease of reach, not blast radius. It is NOT in CISA KEV and no EPSS score was supplied, so exploitation probability cannot be quantified from the input; there is no confirmed public exploit, only a vendor advisory and the vulnerable source line. The vuln.today decision label is 'this_month' (not act_now/emergency), and a vendor patch exists, so this is a plan-and-patch item rather than a drop-everything emergency. A key caveat: the real-world impact depends entirely on deployment - if an application feeds attacker-controlled Markdown to snarkdown's parse() synchronously on a Node.js server, one request can stall the event loop and deny service to all users; purely client-side use only hangs the attacker's own browser tab, which materially lowers risk. This limiting factor is not captured by the raw CVSS number and should drive prioritization.

Exploit ScenarioDerived

An application exposes a feature that renders user-supplied Markdown with snarkdown (e.g. comments, profiles, chat) and calls parse() on the request path. An attacker submits a single payload packed with many links or deeply nested '[' brackets; because each closing link triggers a rescan of the entire accumulated output, processing time grows quadratically and blocks the Node.js event loop, stalling the whole service. No public working exploit is identified, but the vulnerable code path and the fix are documented in the vendor PR.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.7% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Dec 02, 2026

Quadratic-time link resolution in Snarkdown through 2.0.0 lets unauthenticated attackers block the JavaScript event loop by supplying crafted Markdown containing many links or deeply nested '[' brackets, which forces the parser to rescan the entire accumulated HTML output on every closing bracket. The impact is availability-only (CVSS 3.1: AV:N/AC:L/PR:N/UI:N/A:L; CVSS 4.0 base 6.9) and is bounded in practice: it matters chiefly where parse() runs server-side and synchronously under Node.js, since a stalled event loop denies service to every client, whereas in purely browser-based use the hang is confined to the user who submitted the input. No public exploit code was identified at time of analysis, and the vendor has published an upstream fix in pull request #118.

RemediationAI

Apply the upstream fix in pull request #118 (https://github.com/developit/snarkdown/pull/118), which converts link href resolution from a repeated whole-buffer rewrite into a single deferred pass; the input data confirms the patch is available from the vendor but does not confirm a tagged release number, so verify that the deployed package actually contains the PR before treating the dependency as fixed. Where patching must be staged, limit exposure by not calling parse() synchronously on attacker-controlled input inside a Node.js main event loop - move parsing into a worker thread or child process with a wall-clock timeout so a pathological document cannot stall the process serving other clients, at the cost of added latency and IPC complexity. Alternatively, reject or truncate input whose link count or '[' nesting depth exceeds the application's legitimate maximum before parsing; this is cheap but will refuse unusually link-heavy legitimate documents. Confirm dependency state against the advisory at https://www.vulncheck.com/advisories/snarkdown-through-2.0.0-denial-of-service-via-quadratic-link-resolution.

Affected VersionsENISA

snarkdown 0 ≤2.0.0

Affected Packages

euvd snarkdown no fix

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

Snarkdown is a small dependency-free JavaScript Markdown-to-HTML parser distributed via npm by developit (CPE cpe:2.3:a:developit:snarkdown). The flaw is in parse() in src/index.js, where each resolved link previously rewrote the whole output buffer via out.replace('<a>', ...) on every closing ']' - the exact line referenced in the advisory (src/index.js#L86 of the 2.0.0 tag). Because that rewrite scans the entire accumulated HTML string each time, cost grows quadratically with the number of links or nested brackets in the input, matching CWE-407 (Inefficient Algorithmic Complexity). The upstream patch replaces the repeated rewrite with offset bookkeeping: an emit() helper records the position of every '<a>' marker as output is appended, a left-to-right pointer consumes those offsets to defer href substitution, and a single final merge pass fills in the links, preserving the original 'first unresolved <a> wins' semantics while making resolution linear. The trigger requires only that a host application pass attacker-controllable Markdown into parse(); no special configuration, credentials, or user interaction is involved.

Know when Snarkdown 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

Vendor (VulnCheck) PRIMARY 6.9 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N
vuln.today AI 5.3 MEDIUM

Unauthenticated network-supplied Markdown triggers quadratic parsing with no privileges or interaction (AV:N/AC:L/PR:N/UI:N); only partial, recoverable availability loss (A:L), no C/I impact.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
Low
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

DescriptionCVE.org

Snarkdown through 2.0.0 contains a denial of service vulnerability in parse() in src/index.js that rescans the entire accumulated HTML output for each link. Attackers can supply crafted Markdown with many links or deeply nested '[' brackets to cause quadratic processing time, blocking the JavaScript event loop.

Threat Intelligence Overview

EPSS Score
0.7%
Top 47% exploitable
Prevalence
Medium
small but known npm Markdown library, moderate real-world usage
Social Media
1
Sightings
Data Quality
5 sources
Confidence: Medium

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.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.7%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact· derived
Medium

Priority Score

35
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +34
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy