<?xml version='1.0' encoding='UTF-8'?>
<?xml-stylesheet href="/static/style.xsl" type="text/xsl"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/" version="2.0">
  <channel>
    <title>Most recent entries from all</title>
    <link>https://db.gcve.eu</link>
    <description>Contains only the most 10 recent entries.</description>
    <docs>http://www.rssboard.org/rss-specification</docs>
    <generator>python-feedgen</generator>
    <language>en</language>
    <lastBuildDate>Thu, 22 Oct 2026 01:55:04 +0000</lastBuildDate>
    <item>
      <title>GHSA-253c-mchw-3w2r — markdown-it linkify: true has two quadratic paths, so a few hundred KB of markdown blocks the event loop for tens of se…</title>
      <link>https://db.gcve.eu/vuln/ghsa-253c-mchw-3w2r</link>
      <description>&lt;p&gt;&lt;strong&gt;Affected:&lt;/strong&gt; npm: markdown-it&lt;/p&gt;
&lt;p&gt;## Summary&lt;/p&gt;
&lt;p&gt;Two independent quadratic paths in the `linkify: true` handling. Both are in markdown-it&amp;#39;s own code rather than in linkify-it, which stays linear on both payloads.&lt;/p&gt;
&lt;p&gt;`src/rules_core/linkify.ts` calls `arrayReplaceAt` once per linkified text token, and that rebuilds the whole `children` array each time. A paragraph of N soft-broken lines is one inline token with about 2N children, so you get N rebuilds over a 2N array. Schema-less emails are what reach it. A `http://` link gets consumed by the inline rule first and never arrives as a text token, so those stay linear.&lt;/p&gt;
&lt;p&gt;`src/rules_inline/linkify.ts` runs `state.pending.match(SCHEME_RE)` at every `://` in the source. `state.pending` only gets truncated once a link is actually produced, so an unregistered scheme leaves it growing and every `://` rescans the lot.&lt;/p&gt;
&lt;p&gt;## Proof of concept&lt;/p&gt;
&lt;p&gt;Clean install of 15.0.0 from npm, `new MarkdownIt({ linkify: true }).render(payload)`, Node 24.&lt;/p&gt;
&lt;p&gt;| N | 5,000 | 10,000 | 20,000 | 40,000 |
|---|---|---|---|---|
| `&amp;#39;a@b.co\n&amp;#39;.repeat(N)`, 34KB to 273KB | 1.1s | 4.7s | 19.6s | 89s |
| `&amp;#39;a://&amp;#39;.repeat(N)`, 20KB to 156KB | 0.25s | 0.76s | 3.1s | 15.0s |&lt;/p&gt;
&lt;p&gt;Doubling the input roughly quadruples the time in both. With `linkify: false` the same inputs run in 25 to 131ms and stay flat.&lt;/p&gt;
&lt;p&gt;Controls for the first one, all at N=20000: putting every email in a single text token (`&amp;#39;a@b.co &amp;#39;`) takes 0.59s, one email per paragraph (`&amp;#39;a@b.co\n\n&amp;#39;`) takes 0.64s, and soft-broken lines with nothing linkifiable tak…&lt;/p&gt;</description>
      <content:encoded>&lt;p&gt;&lt;strong&gt;Affected:&lt;/strong&gt; npm: markdown-it&lt;/p&gt;
&lt;p&gt;## Summary&lt;/p&gt;
&lt;p&gt;Two independent quadratic paths in the `linkify: true` handling. Both are in markdown-it&amp;#39;s own code rather than in linkify-it, which stays linear on both payloads.&lt;/p&gt;
&lt;p&gt;`src/rules_core/linkify.ts` calls `arrayReplaceAt` once per linkified text token, and that rebuilds the whole `children` array each time. A paragraph of N soft-broken lines is one inline token with about 2N children, so you get N rebuilds over a 2N array. Schema-less emails are what reach it. A `http://` link gets consumed by the inline rule first and never arrives as a text token, so those stay linear.&lt;/p&gt;
&lt;p&gt;`src/rules_inline/linkify.ts` runs `state.pending.match(SCHEME_RE)` at every `://` in the source. `state.pending` only gets truncated once a link is actually produced, so an unregistered scheme leaves it growing and every `://` rescans the lot.&lt;/p&gt;
&lt;p&gt;## Proof of concept&lt;/p&gt;
&lt;p&gt;Clean install of 15.0.0 from npm, `new MarkdownIt({ linkify: true }).render(payload)`, Node 24.&lt;/p&gt;
&lt;p&gt;| N | 5,000 | 10,000 | 20,000 | 40,000 |
|---|---|---|---|---|
| `&amp;#39;a@b.co\n&amp;#39;.repeat(N)`, 34KB to 273KB | 1.1s | 4.7s | 19.6s | 89s |
| `&amp;#39;a://&amp;#39;.repeat(N)`, 20KB to 156KB | 0.25s | 0.76s | 3.1s | 15.0s |&lt;/p&gt;
&lt;p&gt;Doubling the input roughly quadruples the time in both. With `linkify: false` the same inputs run in 25 to 131ms and stay flat.&lt;/p&gt;
&lt;p&gt;Controls for the first one, all at N=20000: putting every email in a single text token (`&amp;#39;a@b.co &amp;#39;`) takes 0.59s, one email per paragraph (`&amp;#39;a@b.co\n\n&amp;#39;`) takes 0.64s, and soft-broken lines with nothing linkifiable tak…&lt;/p&gt;</content:encoded>
      <guid isPermaLink="false">https://db.gcve.eu/vuln/ghsa-253c-mchw-3w2r</guid>
    </item>
  </channel>
</rss>
