CWE-407
Allowed-with-ReviewInefficient Algorithmic Complexity
Abstraction: Class · Status: Incomplete
An algorithm in a product has an inefficient worst-case computational complexity that may be detrimental to system performance and can be triggered by an attacker, typically using crafted manipulations that ensure that the worst case is being reached.
584 vulnerabilities reference this CWE, most recent first.
GHSA-JFM3-95JQ-Q3RF
Vulnerability from github – Published: 2026-08-06 20:40 – Updated: 2026-08-06 20:42Impact
The Footnote extension records one backref per footnote reference and then appends the entire backref list for every footnote definition block in the document, without ever de-duplicating or removing repeated definitions of the same label (GatherFootnotesListener, populated by NumberFootnotesListener). A document that references a single label N times and also supplies N duplicate [^a]: definitions of that label therefore produces N × N FootnoteBackref nodes, so output size, parse time, and peak memory are all O(N²).
Reaching the vulnerable path requires FootnoteExtension to be registered on the Environment. This is opt-in, but is a commonly enabled GFM-style feature; no other non-default configuration is required. An unauthenticated attacker can expand a ~10 KB request into a ~62 MB HTML response, ~3 s of CPU, and ~440 MB of peak memory — enough to OOM-kill a default 128 MB PHP worker and deny service. Availability impact only; no confidentiality or integrity effect. The Footnote extension was introduced in 1.5.0 (May 2020) with this backref logic present from the first commit, so all releases from 1.5.0 onward (including every 2.x through 2.8.x) are affected.
Workarounds
There is no library-level option to cap the number of footnotes, references, or definitions, so no configuration switch prevents the amplification. Integrators who cannot upgrade should:
- Disable the Footnote extension for untrusted input, or
- Enforce a strict input-size limit before conversion — but note this is a weak control here, since the ~10 KB payload that already triggers the 62 MB / ~440 MB blowup is well within typical request-body limits, so any cap must be aggressively small to help.
Upgrading to the patched release is the recommended remediation.
{
"affected": [
{
"package": {
"ecosystem": "Packagist",
"name": "league/commonmark"
},
"ranges": [
{
"events": [
{
"introduced": "1.5.0"
},
{
"fixed": "2.9.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [],
"database_specific": {
"cwe_ids": [
"CWE-407"
],
"github_reviewed": true,
"github_reviewed_at": "2026-08-06T20:40:53Z",
"nvd_published_at": null,
"severity": "HIGH"
},
"details": "### Impact\n\nThe Footnote extension records one backref per footnote *reference* and then appends the **entire** backref list for **every** footnote *definition* block in the document, without ever de-duplicating or removing repeated definitions of the same label (`GatherFootnotesListener`, populated by `NumberFootnotesListener`). A document that references a single label N times and also supplies N duplicate `[^a]:` definitions of that label therefore produces **N \u00d7 N** `FootnoteBackref` nodes, so output size, parse time, and peak memory are all **O(N\u00b2)**.\n\nReaching the vulnerable path requires `FootnoteExtension` to be registered on the `Environment`. This is opt-in, but is a commonly enabled GFM-style feature; no other non-default configuration is required. An unauthenticated attacker can expand a **~10 KB** request into a **~62 MB** HTML response, **~3 s** of CPU, and **~440 MB** of peak memory \u2014 enough to OOM-kill a default 128 MB PHP worker and deny service. Availability impact only; no confidentiality or integrity effect. **The Footnote extension was introduced in 1.5.0 (May 2020) with this backref logic present from the first commit, so all releases from 1.5.0 onward (including every 2.x through 2.8.x) are affected.**\n\n### Workarounds\n\nThere is no library-level option to cap the number of footnotes, references, or definitions, so no configuration switch prevents the amplification. Integrators who cannot upgrade should:\n\n- **Disable the Footnote extension** for untrusted input, or\n- **Enforce a strict input-size limit before conversion** \u2014 but note this is a weak control here, since the ~10 KB payload that already triggers the 62 MB / ~440 MB blowup is well within typical request-body limits, so any cap must be aggressively small to help.\n\nUpgrading to the patched release is the recommended remediation.",
"id": "GHSA-jfm3-95jq-q3rf",
"modified": "2026-08-06T20:42:11Z",
"published": "2026-08-06T20:40:53Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/thephpleague/commonmark/security/advisories/GHSA-jfm3-95jq-q3rf"
},
{
"type": "WEB",
"url": "https://github.com/thephpleague/commonmark/commit/66028124a17ba193da7b11cc3dfda92df21bfbf4"
},
{
"type": "PACKAGE",
"url": "https://github.com/thephpleague/commonmark"
},
{
"type": "WEB",
"url": "https://github.com/thephpleague/commonmark/releases/tag/2.9.0"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
],
"summary": "league/commonmark: Denial of service via duplicate footnote definitions"
}
GHSA-JG6J-874M-WGJJ
Vulnerability from github – Published: 2026-06-03 18:33 – Updated: 2026-11-10 15:32unicodedata.normalize() can take excessive CPU time when processing specially crafted Unicode input containing long runs of combining characters with alternating Canonical Combining Class values. This affects all normalization forms.
{
"affected": [],
"aliases": [
"CVE-2026-3276"
],
"database_specific": {
"cwe_ids": [
"CWE-407"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-06-03T16:16:29Z",
"severity": "MODERATE"
},
"details": "unicodedata.normalize() can take excessive CPU time when processing\nspecially crafted Unicode input containing long runs of combining characters\nwith alternating Canonical Combining Class values.\nThis affects all normalization forms.",
"id": "GHSA-jg6j-874m-wgjj",
"modified": "2026-11-10T15:32:43Z",
"published": "2026-06-03T18:33:09Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-3276"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/issues/149079"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/pull/149080"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/commit/6b505d1f41f8f3ea0fe5a4786d3a8fff1875cfc0"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/commit/90748760d38ca3ac5fc6788a69becab905c95598"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/commit/991224b1e8311c85f198f6dd8208bf8cff7fc26f"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/commit/ba785b88add96acbf403d65cb157fb2743a33a32"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/commit/c5512bd7c1dc28055660565275012766941d3066"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/commit/d3ab945af25b28dfe13ac6cb40c124a01b33ce1f"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/commit/db744c0776c1d5dd11aaa70eff2a6993c408bacc"
},
{
"type": "WEB",
"url": "https://github.com/python/cpython/commit/e322a1857084d521f79f45181b776f62e6acfc2c"
},
{
"type": "WEB",
"url": "https://cert-portal.siemens.com/productcert/html/ssa-457936.html"
},
{
"type": "WEB",
"url": "https://mail.python.org/archives/list/security-announce@python.org/thread/PP5HB4K7727OBBM76KA2ILID76K3OZGZ"
},
{
"type": "WEB",
"url": "http://www.openwall.com/lists/oss-security/2026/06/03/15"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X",
"type": "CVSS_V4"
}
]
}
GHSA-JG86-V3JV-HRPM
Vulnerability from github – Published: 2026-10-21 21:11 – Updated: 2026-10-21 21:11============================================================================
Quadratic-time DoS in PDF save_all (PdfParser.next_object_id)
Location: src/PIL/PdfParser.py:629 in next_object_id()
Commit: a707c6b21c313880d0771e54965d142dd42358b6
============================================================================
Pillow's PDF writer takes time proportional to the square of the number of frames when it saves a multi-frame image as a multi-page PDF. Anyone who can get an application to convert their uploaded image this way can tie up a worker at full CPU for minutes with a small file. A 240 KB animated image takes about 70 seconds, a 720 KB one an estimated 10 minutes, and a 125-byte animated PNG that merely declares a large frame count triggers the same slowdown with no upper bound short of 2³¹ frames. Memory stays under 100 MB and the decompression-bomb limit never applies.
The cause is PdfParser.next_object_id() in src/PIL/PdfParser.py, which finds the next free id by computing max(self.xref_table.keys()). XrefTable.keys() rebuilds three sets over every id reserved so far on each call. PdfImagePlugin._save() calls it three times (four for palette images with transparency) per frame, for n_frames frames, before any page is written. That makes the id-reservation loop alone O(N²). Because n_frames is taken from the file before any frame is seeked, APNG's acTL count drives the loop even when the frames don't exist. In that case the save raises OSError only after the full delay.
The precondition is that the application calls im.save(..., "PDF", save_all=True) on the attacker's file; Image.open() and load() alone do not reach this code. The attached reproducer shows 4× the frames costing about 11× the CPU for a valid GIF and about 16× for a fixed 125-byte APNG. The behaviour was introduced in 6207b44ab1ff (2018-01-18) and first shipped in Pillow 5.1.0. A small patch that tracks the highest id in XrefTable makes the save linear.
Details
Saving a multi-frame image as a multi-page PDF (im.save(fp, "PDF", save_all=True)) costs CPU time proportional to the square of the frame count, independent of pixel content, because every object id the PDF writer reserves is found by rebuilding and scanning the set of all ids reserved so far.
A 1×1-pixel animated GIF made of N identical 15-byte frames (built by the reproducer) gives, on a 2-CPU container with the stock build at this commit (absolute timings vary by machine; the growth rate does not):
| frames | GIF size | im.save(BytesIO(), "PDF", save_all=True) |
peak RSS |
|---|---|---|---|
| 2 000 | 30 KB | 1.1 s | |
| 8 000 | 120 KB | 14.7 s | |
| 16 000 | 240 KB | 70 s | 60 MB |
| 32 000 | 480 KB | 262 s | 95 MB |
| 48 000 | 720 KB | still running at 120 s (extrapolated ≈ 10 min) |
Each doubling of the input roughly quadruples the time. cProfile of the 8 000-frame save attributes 13.5 s of 17.6 s to 24 003 calls of PdfParser.next_object_id (8.9 s inside XrefTable.keys, 3.9 s inside max); encoding and writing the 8 000 pages is the remaining ~4 s and scales linearly.
The per-page id reservation loop runs before any page is written:
# src/PIL/PdfImagePlugin.py:247-259 (_save)
for im in ims:
im_number_of_pages = 1
if save_all:
im_number_of_pages = getattr(im, "n_frames", 1)
…
for i in range(im_number_of_pages):
image_refs.append(existing_pdf.next_object_id(0))
if im.mode == "P" and "transparency" in im.info:
image_refs.append(existing_pdf.next_object_id(0))
page_refs.append(existing_pdf.next_object_id(0))
contents_refs.append(existing_pdf.next_object_id(0))
n_frames comes straight from the file (for GIF it is the number of image blocks; the GIF plugin counts them by walking block headers, which is cheap). The frames do not even have to exist: the loop runs on n_frames before any frame is seeked, and for APNG n_frames is the num_frames value declared in the acTL chunk, rejected only if it is 0 or above 0x80000000 (src/PIL/PngImagePlugin.py:716-720). A 125-byte APNG declaring 8 000 frames therefore costs the same ~10–13 s as the 120 KB GIF, and more without bound as the declared count grows. Each of the 3 (or 4, for P images with transparency) calls per frame lands here:
# src/PIL/PdfParser.py:626-634
def next_object_id(self, offset: int | None = None) -> IndirectReference:
try:
# TODO: support reuse of deleted objects
reference = IndirectReference(max(self.xref_table.keys()) + 1, 0)
except ValueError:
reference = IndirectReference(1, 0)
if offset is not None:
self.xref_table[reference.object_id] = (offset, 0)
return reference
# src/PIL/PdfParser.py:175-178 (XrefTable)
def keys(self) -> set[int]:
return (
set(self.existing_entries.keys()) - set(self.deleted_entries.keys())
) | set(self.new_entries.keys())
_save passes offset=0, so every reserved id is inserted into xref_table.new_entries. The k-th call therefore materialises three sets covering all k−1 previous ids, computes a difference and a union, and then max() scans the result — O(k) work to produce the integer k. Summed over 3N calls this is O(N²): for 48 000 frames, 144 002 calls over sets growing to 144 002 elements, on the order of 10¹⁰ set-element operations, all spent before _write_image is reached for the first frame. Nothing on this path consults MAX_IMAGE_PIXELS (the frames are 1×1) and nothing raises; for the GIF the save eventually completes and produces a valid PDF, and for the declared-only APNG it raises OSError only once the id loop has finished and the first missing frame is seeked.
This reservation scheme was introduced in 6207b44ab1ff ("issue #2959: support appending to existing PDFs", 2018-01-18) and first shipped in Pillow 5.1.0; before it, the writer numbered objects arithmetically.
For contrast, write_obj(ref, …) with an already-reserved ref (src/PIL/PdfParser.py:548-555) only does a dict store, which is why the page-writing phase that follows is linear; the super-linear cost is entirely in how the next free id is computed.
Impact
The precondition is that the application saves the attacker's image as PDF with save_all=True; Image.open() and load() alone do not reach this code. An application that converts uploaded images to PDF this way — the documented way to get one page per frame from animated GIF/APNG/WebP or multi-page TIFF input — can have a worker held at 100 % CPU for about 10 minutes by a 720 KB GIF, about 4½ minutes by a 480 KB one, with the cost continuing to grow quadratically with upload size. With APNG the file size does not matter at all: a 125-byte file declaring N frames in acTL drives the same quadratic loop, up to the 2³¹ cap. The attacker controls only the file bytes; no unusual dimensions, modes or options are needed, memory use stays under 100 MB so memory limits do not intervene, and the decompression-bomb guard is not applicable. The consequence is denial of service of the process performing the conversion. Single-image PDF saves, and save_all saves of images with tens or hundreds of frames, are unaffected in practice.
This is the same family as earlier accidentally-quadratic parsing issues fixed in Pillow (e.g. CVE-2021-28677, EPS readline), but on the PDF writer side, reached only through a save rather than on open, and driven by frame count rather than by line structure.
Reproducing
repro is a single Python script. Run it with the Python that has Pillow installed (./repro). It uses under 100 MB of RAM and writes no files.
Input. Two kinds of file are built in memory, each with 2 000 and 8 000 frames:
gif(n): a valid animated GIF — aGIF89aheader with a 1×1 logical screen and a 2-colour global palette, thenncopies of one 15-byte frame (a 1×1 image descriptor plus the LZW data for one pixel), then the trailer (30 and 120 KB). The only unusual thing about it is how many frames it has.apng(n): a 125-byte APNG — a 1×1 greyscaleIHDR, anacTLchunk declaringnframes, onefcTL, oneIDATandIEND. Only the first frame exists; the othern − 1are merely declared.
Action. Each file goes through what an upload-to-PDF converter would do: Image.open(BytesIO(data)), then im.save(BytesIO(), "PDF", save_all=True), timed with time.process_time(). For the APNG the save raises OSError once the writer tries to seek to the second frame; that happens after the id-reservation loop has run for all n declared frames, so the exception is caught and the CPU time up to it is recorded.
Expected output (stock build at this commit):
GIF frames= 2000 file= 30020 B save CPU= 1.03s result=ok
GIF frames= 8000 file=120020 B save CPU= 11.68s result=ok
GIF: 4x frames -> 11.3x CPU (linear ~4x, quadratic ~16x)
APNG frames= 2000 file= 125 B save CPU= 0.65s result=OSError(Truncated File Read)
APNG frames= 8000 file= 125 B save CPU= 10.48s result=OSError(Truncated File Read)
APNG: 4x frames -> 16.1x CPU (linear ~4x, quadratic ~16x)
BUG
A linear save would take about 4× as long for 4× the frames; here the GIF save grows ~11× and the APNG save ~16×, the latter with the file size fixed at 125 bytes. The script prints BUG when the save CPU for either format grows at least 8× for 4× the frames (twice the linear expectation), otherwise OK. Extending the same curve gives the figures in the table above: about 70 s at 16 000 frames (240 KB GIF), and about 10 minutes for a 720 KB file.
With the attached patch applied, the GIF save takes 0.32 s / 1.20 s (3.7×) and the APNG save 0.01 s / 0.03 s, and the script prints OK.
Suggested fix
Make next_object_id() O(1) by tracking the highest object id ever stored in XrefTable instead of rebuilding the key set on every call. The attached patch does this in src/PIL/PdfParser.py:
--- a/src/PIL/PdfParser.py
+++ b/src/PIL/PdfParser.py
@@ class XrefTable:
self.deleted_entries = {0: 65536} # object ID => generation
self.reading_finished = False
+ self.max_object_id = 0 # highest object ID ever stored, deleted or not
def __setitem__(self, key: int, value: tuple[int, int]) -> None:
if self.reading_finished:
self.new_entries[key] = value
else:
self.existing_entries[key] = value
+ if key > self.max_object_id:
+ self.max_object_id = key
if key in self.deleted_entries:
del self.deleted_entries[key]
@@ class PdfParser:
def next_object_id(self, offset: int | None = None) -> IndirectReference:
- try:
- # TODO: support reuse of deleted objects
- reference = IndirectReference(max(self.xref_table.keys()) + 1, 0)
- except ValueError:
- reference = IndirectReference(1, 0)
+ # TODO: support reuse of deleted objects
+ reference = IndirectReference(self.xref_table.max_object_id + 1, 0)
if offset is not None:
self.xref_table[reference.object_id] = (offset, 0)
return reference
existing_entries is only ever populated through __setitem__ (from read_xref_table / read_prev_trailer), so the counter also covers ids read from an existing file in append=True mode. The one behavioural difference: when the highest-numbered existing object has just been deleted (del_root() / rewrite_pages() in append mode), the current code hands that id out again with generation 0, whereas the patch moves on to the next unused id — the more conservative choice for an xref table, and the one the existing TODO: support reuse of deleted objects comment points at. With the patch applied and Pillow rebuilt, the 16 000-frame save drops from ~70 s to ~2.5 s, fresh PDF output is unchanged, Tests/test_file_pdf.py and Tests/test_pdfparser.py pass, and the reproducer prints OK.
An alternative limited to the writer would be to reserve the 3 × number_of_pages ids in PdfImagePlugin._save() arithmetically from a single next_object_id() call, but fixing the allocator also covers write_obj(None, …) callers.
The patch does not address a separate, linear issue: PdfImagePlugin._save() still trusts n_frames before any frame is decoded, so a tiny file whose format reports a declared-only frame count (APNG acTL up to 2³¹) still makes it loop 3 × n_frames times before the first failing seek. Reserving ids per successfully seeked frame, or validating n_frames in such plugins, would close that.
The patch
Track the highest object ID in XrefTable so PdfParser.next_object_id() is O(1) instead of rebuilding and scanning the key set
Applies to src/PIL/PdfParser.py at the commit above.
diff --git a/src/PIL/PdfParser.py b/src/PIL/PdfParser.py
index 672557190..82ebfb867 100644
--- a/src/PIL/PdfParser.py
+++ b/src/PIL/PdfParser.py
@@ -133,12 +133,15 @@ class XrefTable:
) # object ID => (offset, generation)
self.deleted_entries = {0: 65536} # object ID => generation
self.reading_finished = False
+ self.max_object_id = 0 # highest object ID ever stored, deleted or not
def __setitem__(self, key: int, value: tuple[int, int]) -> None:
if self.reading_finished:
self.new_entries[key] = value
else:
self.existing_entries[key] = value
+ if key > self.max_object_id:
+ self.max_object_id = key
if key in self.deleted_entries:
del self.deleted_entries[key]
@@ -624,11 +627,8 @@ class PdfParser:
self.orig_pages = self.pages[:]
def next_object_id(self, offset: int | None = None) -> IndirectReference:
- try:
- # TODO: support reuse of deleted objects
- reference = IndirectReference(max(self.xref_table.keys()) + 1, 0)
- except ValueError:
- reference = IndirectReference(1, 0)
+ # TODO: support reuse of deleted objects
+ reference = IndirectReference(self.xref_table.max_object_id + 1, 0)
if offset is not None:
self.xref_table[reference.object_id] = (offset, 0)
return reference
The reproducer
Reproducer —repro, 1,791 bytes (click to open)
Its last line is `BUG` when the issue triggers and `OK` when it does not. Re-run on a clean build of that commit it printed `BUG`.
#!/usr/bin/env python3
# PDF save_all is O(frames^2): PdfParser.next_object_id() does max(XrefTable.keys()),
# and keys() rebuilds sets of every id reserved so far, 3 calls per frame.
# (a) valid 1x1 animated GIF, 15 bytes/frame; (b) 125-byte APNG whose acTL merely
# *declares* N frames - ids are reserved for all N before the first seek fails.
import io, struct, time, zlib
from PIL import Image
def gif(n):
return (b"GIF89a\x01\x00\x01\x00\x80\x00\x00\x00\x00\x00\xff\xff\xff"
+ b"\x2c\x00\x00\x00\x00\x01\x00\x01\x00\x00\x02\x02\x44\x01\x00" * n + b"\x3b")
def apng(n):
def chunk(t, d):
return struct.pack(">I", len(d)) + t + d + struct.pack(">I", zlib.crc32(t + d))
return (b"\x89PNG\r\n\x1a\n"
+ chunk(b"IHDR", struct.pack(">IIBBBBB", 1, 1, 8, 0, 0, 0, 0))
+ chunk(b"acTL", struct.pack(">II", n, 0))
+ chunk(b"fcTL", struct.pack(">IIIIIHHBB", 0, 1, 1, 0, 0, 1, 1, 0, 0))
+ chunk(b"IDAT", zlib.compress(b"\x00\x00")) + chunk(b"IEND", b""))
def save_pdf(data):
im = Image.open(io.BytesIO(data))
t = time.process_time()
try:
im.save(io.BytesIO(), "PDF", save_all=True)
res = "ok"
except OSError as e: # APNG: frames don't exist, fails *after* the id loop
res = f"OSError({e})"
return time.process_time() - t, res
bug = False
for name, make in (("GIF", gif), ("APNG", apng)):
t = {}
for n in (2000, 8000):
data = make(n)
t[n], res = save_pdf(data)
print(f"{name:4} frames={n:5} file={len(data):6} B save CPU={t[n]:6.2f}s result={res}")
growth = t[8000] / t[2000]
print(f"{name}: 4x frames -> {growth:.1f}x CPU (linear ~4x, quadratic ~16x)")
if growth >= 8:
bug = True
print("BUG" if bug else "OK")
{
"affected": [
{
"package": {
"ecosystem": "PyPI",
"name": "Pillow"
},
"ranges": [
{
"events": [
{
"introduced": "5.1.0"
},
{
"fixed": "13.0.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-112894"
],
"database_specific": {
"cwe_ids": [
"CWE-407"
],
"github_reviewed": true,
"github_reviewed_at": "2026-10-21T21:11:44Z",
"nvd_published_at": "2026-10-19T22:17:09Z",
"severity": "HIGH"
},
"details": "```\n============================================================================\nQuadratic-time DoS in PDF save_all (PdfParser.next_object_id)\nLocation: src/PIL/PdfParser.py:629 in next_object_id()\nCommit: a707c6b21c313880d0771e54965d142dd42358b6\n============================================================================\n```\n\nPillow\u0027s PDF writer takes time proportional to the square of the number of frames when it saves a multi-frame image as a multi-page PDF. Anyone who can get an application to convert their uploaded image this way can tie up a worker at full CPU for minutes with a small file. A 240 KB animated image takes about 70 seconds, a 720 KB one an estimated 10 minutes, and a 125-byte animated PNG that merely *declares* a large frame count triggers the same slowdown with no upper bound short of 2\u00b3\u00b9 frames. Memory stays under 100 MB and the decompression-bomb limit never applies.\n\nThe cause is `PdfParser.next_object_id()` in `src/PIL/PdfParser.py`, which finds the next free id by computing `max(self.xref_table.keys())`. `XrefTable.keys()` rebuilds three sets over every id reserved so far on each call. `PdfImagePlugin._save()` calls it three times (four for palette images with transparency) per frame, for `n_frames` frames, before any page is written. That makes the id-reservation loop alone O(N\u00b2). Because `n_frames` is taken from the file before any frame is seeked, APNG\u0027s `acTL` count drives the loop even when the frames don\u0027t exist. In that case the save raises `OSError` only after the full delay.\n\nThe precondition is that the application calls `im.save(..., \"PDF\", save_all=True)` on the attacker\u0027s file; `Image.open()` and `load()` alone do not reach this code. The attached reproducer shows 4\u00d7 the frames costing about 11\u00d7 the CPU for a valid GIF and about 16\u00d7 for a fixed 125-byte APNG. The behaviour was introduced in `6207b44ab1ff` (2018-01-18) and first shipped in Pillow 5.1.0. A small patch that tracks the highest id in `XrefTable` makes the save linear.\n\n## Details\n\nSaving a multi-frame image as a multi-page PDF (`im.save(fp, \"PDF\", save_all=True)`) costs CPU time proportional to the square of the frame count, independent of pixel content, because every object id the PDF writer reserves is found by rebuilding and scanning the set of all ids reserved so far.\n\nA 1\u00d71-pixel animated GIF made of N identical 15-byte frames (built by the reproducer) gives, on a 2-CPU container with the stock build at this commit (absolute timings vary by machine; the growth rate does not):\n\n| frames | GIF size | `im.save(BytesIO(), \"PDF\", save_all=True)` | peak RSS |\n|---|---|---|---|\n| 2 000 | 30 KB | 1.1 s | |\n| 8 000 | 120 KB | 14.7 s | |\n| 16 000 | 240 KB | 70 s | 60 MB |\n| 32 000 | 480 KB | 262 s | 95 MB |\n| 48 000 | 720 KB | still running at 120 s (extrapolated \u2248 10 min) | |\n\nEach doubling of the input roughly quadruples the time. `cProfile` of the 8 000-frame save attributes 13.5 s of 17.6 s to 24 003 calls of `PdfParser.next_object_id` (8.9 s inside `XrefTable.keys`, 3.9 s inside `max`); encoding and writing the 8 000 pages is the remaining ~4 s and scales linearly.\n\nThe per-page id reservation loop runs before any page is written:\n\n```python\n# src/PIL/PdfImagePlugin.py:247-259 (_save)\n for im in ims:\n im_number_of_pages = 1\n if save_all:\n im_number_of_pages = getattr(im, \"n_frames\", 1)\n \u2026\n for i in range(im_number_of_pages):\n image_refs.append(existing_pdf.next_object_id(0))\n if im.mode == \"P\" and \"transparency\" in im.info:\n image_refs.append(existing_pdf.next_object_id(0))\n\n page_refs.append(existing_pdf.next_object_id(0))\n contents_refs.append(existing_pdf.next_object_id(0))\n```\n\n`n_frames` comes straight from the file (for GIF it is the number of image blocks; the GIF plugin counts them by walking block headers, which is cheap). The frames do not even have to exist: the loop runs on `n_frames` before any frame is seeked, and for APNG `n_frames` is the `num_frames` value declared in the `acTL` chunk, rejected only if it is 0 or above `0x80000000` (`src/PIL/PngImagePlugin.py:716-720`). A 125-byte APNG declaring 8 000 frames therefore costs the same ~10\u201313 s as the 120 KB GIF, and more without bound as the declared count grows. Each of the 3 (or 4, for `P` images with transparency) calls per frame lands here:\n\n```python\n# src/PIL/PdfParser.py:626-634\n def next_object_id(self, offset: int | None = None) -\u003e IndirectReference:\n try:\n # TODO: support reuse of deleted objects\n reference = IndirectReference(max(self.xref_table.keys()) + 1, 0)\n except ValueError:\n reference = IndirectReference(1, 0)\n if offset is not None:\n self.xref_table[reference.object_id] = (offset, 0)\n return reference\n\n# src/PIL/PdfParser.py:175-178 (XrefTable)\n def keys(self) -\u003e set[int]:\n return (\n set(self.existing_entries.keys()) - set(self.deleted_entries.keys())\n ) | set(self.new_entries.keys())\n```\n\n`_save` passes `offset=0`, so every reserved id is inserted into `xref_table.new_entries`. The k-th call therefore materialises three sets covering all k\u22121 previous ids, computes a difference and a union, and then `max()` scans the result \u2014 O(k) work to produce the integer k. Summed over 3N calls this is O(N\u00b2): for 48 000 frames, 144 002 calls over sets growing to 144 002 elements, on the order of 10\u00b9\u2070 set-element operations, all spent before `_write_image` is reached for the first frame. Nothing on this path consults `MAX_IMAGE_PIXELS` (the frames are 1\u00d71) and nothing raises; for the GIF the save eventually completes and produces a valid PDF, and for the declared-only APNG it raises `OSError` only once the id loop has finished and the first missing frame is seeked.\n\nThis reservation scheme was introduced in `6207b44ab1ff` (\"issue #2959: support appending to existing PDFs\", 2018-01-18) and first shipped in Pillow 5.1.0; before it, the writer numbered objects arithmetically.\n\nFor contrast, `write_obj(ref, \u2026)` with an already-reserved `ref` (`src/PIL/PdfParser.py:548-555`) only does a dict store, which is why the page-writing phase that follows is linear; the super-linear cost is entirely in how the next free id is computed.\n\n## Impact\n\nThe precondition is that the application saves the attacker\u0027s image as PDF with `save_all=True`; `Image.open()` and `load()` alone do not reach this code. An application that converts uploaded images to PDF this way \u2014 the documented way to get one page per frame from animated GIF/APNG/WebP or multi-page TIFF input \u2014 can have a worker held at 100 % CPU for about 10 minutes by a 720 KB GIF, about 4\u00bd minutes by a 480 KB one, with the cost continuing to grow quadratically with upload size. With APNG the file size does not matter at all: a 125-byte file declaring N frames in `acTL` drives the same quadratic loop, up to the 2\u00b3\u00b9 cap. The attacker controls only the file bytes; no unusual dimensions, modes or options are needed, memory use stays under 100 MB so memory limits do not intervene, and the decompression-bomb guard is not applicable. The consequence is denial of service of the process performing the conversion. Single-image PDF saves, and `save_all` saves of images with tens or hundreds of frames, are unaffected in practice.\n\nThis is the same family as earlier accidentally-quadratic parsing issues fixed in Pillow (e.g. CVE-2021-28677, EPS `readline`), but on the PDF *writer* side, reached only through a save rather than on open, and driven by frame count rather than by line structure.\n\n## Reproducing\n\n`repro` is a single Python script. Run it with the Python that has Pillow installed (`./repro`). It uses under 100 MB of RAM and writes no files.\n\n**Input.** Two kinds of file are built in memory, each with 2 000 and 8 000 frames:\n\n- `gif(n)`: a valid animated GIF \u2014 a `GIF89a` header with a 1\u00d71 logical screen and a 2-colour global palette, then `n` copies of one 15-byte frame (a 1\u00d71 image descriptor plus the LZW data for one pixel), then the trailer (30 and 120 KB). The only unusual thing about it is how many frames it has.\n- `apng(n)`: a 125-byte APNG \u2014 a 1\u00d71 greyscale `IHDR`, an `acTL` chunk declaring `n` frames, one `fcTL`, one `IDAT` and `IEND`. Only the first frame exists; the other `n \u2212 1` are merely declared.\n\n**Action.** Each file goes through what an upload-to-PDF converter would do: `Image.open(BytesIO(data))`, then `im.save(BytesIO(), \"PDF\", save_all=True)`, timed with `time.process_time()`. For the APNG the save raises `OSError` once the writer tries to seek to the second frame; that happens after the id-reservation loop has run for all `n` declared frames, so the exception is caught and the CPU time up to it is recorded.\n\n**Expected output** (stock build at this commit):\n\n```\nGIF frames= 2000 file= 30020 B save CPU= 1.03s result=ok\nGIF frames= 8000 file=120020 B save CPU= 11.68s result=ok\nGIF: 4x frames -\u003e 11.3x CPU (linear ~4x, quadratic ~16x)\nAPNG frames= 2000 file= 125 B save CPU= 0.65s result=OSError(Truncated File Read)\nAPNG frames= 8000 file= 125 B save CPU= 10.48s result=OSError(Truncated File Read)\nAPNG: 4x frames -\u003e 16.1x CPU (linear ~4x, quadratic ~16x)\nBUG\n```\n\nA linear save would take about 4\u00d7 as long for 4\u00d7 the frames; here the GIF save grows ~11\u00d7 and the APNG save ~16\u00d7, the latter with the file size fixed at 125 bytes. The script prints `BUG` when the save CPU for either format grows at least 8\u00d7 for 4\u00d7 the frames (twice the linear expectation), otherwise `OK`. Extending the same curve gives the figures in the table above: about 70 s at 16 000 frames (240 KB GIF), and about 10 minutes for a 720 KB file.\n\nWith the attached patch applied, the GIF save takes 0.32 s / 1.20 s (3.7\u00d7) and the APNG save 0.01 s / 0.03 s, and the script prints `OK`.\n\n## Suggested fix\n\nMake `next_object_id()` O(1) by tracking the highest object id ever stored in `XrefTable` instead of rebuilding the key set on every call. The attached patch does this in `src/PIL/PdfParser.py`:\n\n```diff\n--- a/src/PIL/PdfParser.py\n+++ b/src/PIL/PdfParser.py\n@@ class XrefTable:\n self.deleted_entries = {0: 65536} # object ID =\u003e generation\n self.reading_finished = False\n+ self.max_object_id = 0 # highest object ID ever stored, deleted or not\n\n def __setitem__(self, key: int, value: tuple[int, int]) -\u003e None:\n if self.reading_finished:\n self.new_entries[key] = value\n else:\n self.existing_entries[key] = value\n+ if key \u003e self.max_object_id:\n+ self.max_object_id = key\n if key in self.deleted_entries:\n del self.deleted_entries[key]\n@@ class PdfParser:\n def next_object_id(self, offset: int | None = None) -\u003e IndirectReference:\n- try:\n- # TODO: support reuse of deleted objects\n- reference = IndirectReference(max(self.xref_table.keys()) + 1, 0)\n- except ValueError:\n- reference = IndirectReference(1, 0)\n+ # TODO: support reuse of deleted objects\n+ reference = IndirectReference(self.xref_table.max_object_id + 1, 0)\n if offset is not None:\n self.xref_table[reference.object_id] = (offset, 0)\n return reference\n```\n\n`existing_entries` is only ever populated through `__setitem__` (from `read_xref_table` / `read_prev_trailer`), so the counter also covers ids read from an existing file in `append=True` mode. The one behavioural difference: when the highest-numbered existing object has just been deleted (`del_root()` / `rewrite_pages()` in append mode), the current code hands that id out again with generation 0, whereas the patch moves on to the next unused id \u2014 the more conservative choice for an xref table, and the one the existing `TODO: support reuse of deleted objects` comment points at. With the patch applied and Pillow rebuilt, the 16 000-frame save drops from ~70 s to ~2.5 s, fresh PDF output is unchanged, `Tests/test_file_pdf.py` and `Tests/test_pdfparser.py` pass, and the reproducer prints `OK`.\n\nAn alternative limited to the writer would be to reserve the `3 \u00d7 number_of_pages` ids in `PdfImagePlugin._save()` arithmetically from a single `next_object_id()` call, but fixing the allocator also covers `write_obj(None, \u2026)` callers.\n\nThe patch does not address a separate, linear issue: `PdfImagePlugin._save()` still trusts `n_frames` before any frame is decoded, so a tiny file whose format reports a declared-only frame count (APNG `acTL` up to 2\u00b3\u00b9) still makes it loop `3 \u00d7 n_frames` times before the first failing seek. Reserving ids per successfully seeked frame, or validating `n_frames` in such plugins, would close that.\n\n## The patch\n\nTrack the highest object ID in XrefTable so PdfParser.next_object_id() is O(1) instead of rebuilding and scanning the key set\n\nApplies to `src/PIL/PdfParser.py` at the commit above.\n\n```diff\ndiff --git a/src/PIL/PdfParser.py b/src/PIL/PdfParser.py\nindex 672557190..82ebfb867 100644\n--- a/src/PIL/PdfParser.py\n+++ b/src/PIL/PdfParser.py\n@@ -133,12 +133,15 @@ class XrefTable:\n ) # object ID =\u003e (offset, generation)\n self.deleted_entries = {0: 65536} # object ID =\u003e generation\n self.reading_finished = False\n+ self.max_object_id = 0 # highest object ID ever stored, deleted or not\n \n def __setitem__(self, key: int, value: tuple[int, int]) -\u003e None:\n if self.reading_finished:\n self.new_entries[key] = value\n else:\n self.existing_entries[key] = value\n+ if key \u003e self.max_object_id:\n+ self.max_object_id = key\n if key in self.deleted_entries:\n del self.deleted_entries[key]\n \n@@ -624,11 +627,8 @@ class PdfParser:\n self.orig_pages = self.pages[:]\n \n def next_object_id(self, offset: int | None = None) -\u003e IndirectReference:\n- try:\n- # TODO: support reuse of deleted objects\n- reference = IndirectReference(max(self.xref_table.keys()) + 1, 0)\n- except ValueError:\n- reference = IndirectReference(1, 0)\n+ # TODO: support reuse of deleted objects\n+ reference = IndirectReference(self.xref_table.max_object_id + 1, 0)\n if offset is not None:\n self.xref_table[reference.object_id] = (offset, 0)\n return reference\n```\n\n## The reproducer\n\n\u003cdetails\u003e\n\u003csummary\u003eReproducer \u2014 \u003ccode\u003erepro\u003c/code\u003e, 1,791 bytes (click to open)\u003c/summary\u003e\n\nIts last line is `BUG` when the issue triggers and `OK` when it does not. Re-run on a clean build of that commit it printed `BUG`.\n\n```python\n#!/usr/bin/env python3\n# PDF save_all is O(frames^2): PdfParser.next_object_id() does max(XrefTable.keys()),\n# and keys() rebuilds sets of every id reserved so far, 3 calls per frame.\n# (a) valid 1x1 animated GIF, 15 bytes/frame; (b) 125-byte APNG whose acTL merely\n# *declares* N frames - ids are reserved for all N before the first seek fails.\nimport io, struct, time, zlib\nfrom PIL import Image\n\ndef gif(n):\n return (b\"GIF89a\\x01\\x00\\x01\\x00\\x80\\x00\\x00\\x00\\x00\\x00\\xff\\xff\\xff\"\n + b\"\\x2c\\x00\\x00\\x00\\x00\\x01\\x00\\x01\\x00\\x00\\x02\\x02\\x44\\x01\\x00\" * n + b\"\\x3b\")\n\ndef apng(n):\n def chunk(t, d):\n return struct.pack(\"\u003eI\", len(d)) + t + d + struct.pack(\"\u003eI\", zlib.crc32(t + d))\n return (b\"\\x89PNG\\r\\n\\x1a\\n\"\n + chunk(b\"IHDR\", struct.pack(\"\u003eIIBBBBB\", 1, 1, 8, 0, 0, 0, 0))\n + chunk(b\"acTL\", struct.pack(\"\u003eII\", n, 0))\n + chunk(b\"fcTL\", struct.pack(\"\u003eIIIIIHHBB\", 0, 1, 1, 0, 0, 1, 1, 0, 0))\n + chunk(b\"IDAT\", zlib.compress(b\"\\x00\\x00\")) + chunk(b\"IEND\", b\"\"))\n\ndef save_pdf(data):\n im = Image.open(io.BytesIO(data))\n t = time.process_time()\n try:\n im.save(io.BytesIO(), \"PDF\", save_all=True)\n res = \"ok\"\n except OSError as e: # APNG: frames don\u0027t exist, fails *after* the id loop\n res = f\"OSError({e})\"\n return time.process_time() - t, res\n\nbug = False\nfor name, make in ((\"GIF\", gif), (\"APNG\", apng)):\n t = {}\n for n in (2000, 8000):\n data = make(n)\n t[n], res = save_pdf(data)\n print(f\"{name:4} frames={n:5} file={len(data):6} B save CPU={t[n]:6.2f}s result={res}\")\n growth = t[8000] / t[2000]\n print(f\"{name}: 4x frames -\u003e {growth:.1f}x CPU (linear ~4x, quadratic ~16x)\")\n if growth \u003e= 8:\n bug = True\nprint(\"BUG\" if bug else \"OK\")\n```\n\u003c/details\u003e\n\n---",
"id": "GHSA-jg86-v3jv-hrpm",
"modified": "2026-10-21T21:11:44Z",
"published": "2026-10-21T21:11:44Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/python-pillow/Pillow/security/advisories/GHSA-jg86-v3jv-hrpm"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-112894"
},
{
"type": "WEB",
"url": "https://github.com/python-pillow/Pillow/commit/f6a852555f1a1bdff7781abf25f1a3b8bd6ce6cb"
},
{
"type": "PACKAGE",
"url": "https://github.com/python-pillow/Pillow"
},
{
"type": "WEB",
"url": "https://github.com/python-pillow/Pillow/releases/tag/13.0.0"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N",
"type": "CVSS_V4"
}
],
"summary": "Pillow: Quadratic-time DoS in PDF save_all (PdfParser.next_object_id)"
}
GHSA-JJ87-HC4R-JWFW
Vulnerability from github – Published: 2026-10-22 15:49 – Updated: 2026-10-22 15:49Summary
FlexAssembler, the custom-container assembler shipped in the stream-json package (src/core/utils/flex-assembler.js, re-exported at stream-json/utils/flex-assembler.js and stream-json/web/utils/flex-assembler.js), compiles a string or RegExp path filter into a matcher that runs keyStack.join(separator) on every container start. Because the key stack grows one entry per open object or array with no depth bound, a JSON document nested to depth D drives D container-start tokens that each perform an O(D) join, for O(D^2) total CPU on the single-threaded event loop. An unauthenticated party who can supply JSON bytes to a pipeline that uses a FlexAssembler with a string or RegExp rule filter can stall the process with a small input: roughly 96 KB (depth 16000) blocks the event loop for over a second, and the cost grows quadratically.
Root Cause
FlexAssembler reconstructs JavaScript values from the parser token stream and supports custom containers selected by path-matching rules. When a rule filter is a string or RegExp, compileFilter returns a matcher that computes the joined path from the full key stack before making any match decision. That join is O(current depth), and it is invoked unconditionally for every rule on every container start. The key stack that feeds the join has no depth cap. The package does have a depth guard (maxDepth), but it exists only in the unrelated filter base state machine and never executes on the FlexAssembler code path, so nested input is unbounded here.
src/core/utils/flex-assembler.js
compileFilter (lines 5-21): string branch computes `path.join(separator)` (line 10)
before the `=== filter || startsWith(...)` comparison; RegExp branch computes
`filter.test(path.join(separator))` (line 17). The join runs first, unconditionally.
FlexAssembler._matchRule (lines 160-166): calls `rule.filter(this.keyStack)` for every
rule; invoked from startObject (line 184) and startArray (line 197) on every
container start.
FlexAssembler._pushState (lines 168-176): pushes one entry onto `keyStack` per open
container with no depth bound.
Impact
An attacker who can deliver JSON to a pipeline whose FlexAssembler is configured with a string or RegExp rule filter (a documented, tested, first-class option: Filter = string | RegExp | FilterFunction) can cause quadratic CPU consumption. The join runs regardless of whether the rule ultimately matches, so no attacker knowledge of the schema is required beyond nesting depth, which the attacker fully controls. The demonstrated capability is an availability impact: a small crafted document blocks the Node.js event loop, stalling all concurrent work on the process. There is no confidentiality or integrity impact. A consumer that uses only a function filter or no rules is not affected, which narrows the vulnerable population but does not raise attack complexity once such a configuration is in use.
Proof of Concept
Node.js and the published stream-json@3.6.0 package. Drive a FlexAssembler configured with a string rule filter, comparing against a function filter as a negative control.
- Install
stream-json@3.6.0. - Construct a deeply nested object token stream (or equivalently parse a document like
'{"k":'repeated D times, a1, then'}'repeated D times, throughparser/parserStream). - Feed it to a
FlexAssemblerwhoseobjectRulescontains a rule with a stringfilter. - Observe wall-clock time scaling as roughly 4x per doubling of D (quadratic), while a function-filter configuration stays flat.
import FlexAssembler from 'stream-json/utils/flex-assembler.js';
function run(filter, D) {
const asm = new FlexAssembler(filter ? {objectRules: [{filter, create: () => ({})}]} : undefined);
const t = performance.now();
asm.startObject();
for (let i = 0; i < D; i++) { asm.keyValue('k'); asm.startObject(); }
return performance.now() - t;
}
for (const D of [4000, 8000, 16000, 32000]) console.log('string', D, run('k', D).toFixed(1), 'ms');
for (const D of [4000, 8000, 16000, 32000]) console.log('function(control)', D, run(p => p.length > 0, D).toFixed(1), 'ms');
string filter (path.join per token): function filter (negative control, no join):
D=4000 91.9 ms D=4000 1.6 ms
D=8000 341.9 ms D=8000 0.9 ms
D=16000 1359.2 ms (~4x per doubling) D=16000 1.7 ms (flat)
D=32000 5430.0 ms (= O(D^2)) D=32000 2.6 ms
End to end through a real parserStream, roughly 96 KB (depth 16000) of attacker-supplied JSON stalls the event loop for over 1.3 seconds.
Attack Chain
- Exposure: The attacker supplies JSON bytes to a service pipeline that assembles values with a
FlexAssemblerconfigured with a string or RegExp rule filter;FlexAssembleris a documented submodule of the published package on both the Node and Web Streams surfaces. - Control: The attacker controls the JSON bytes and therefore the nesting depth D, which directly controls the key stack length.
- Path: Each
{or[emitsstartObject/startArray, which push ontokeyStackand call_matchRule, which calls the compiled filter with the current key stack. - Guard: There is no depth or size cap on this path; the only
maxDepthguard in the package lives in the filter base state machine and never runs inFlexAssembler. - Primitive: For each of the D container starts, the compiled string/RegExp filter runs an O(D)
joinbefore any match decision, for O(D^2) total CPU. - Result: The single-threaded event loop stalls, denying service to all concurrent work on the process; a small input scales quadratically to sustained unavailability.
Bypass Evidence
This is a novel finding on a code path that no prior fix protects, so there is no guard to bypass on the FlexAssembler path. The relevant prior fix is the maxDepth cap published as part of the remediation for CVE-2026-71429 (GHSA-528h-pc64-c93x), which addressed the analogous O(depth^2) behavior in the pick/ignore/filter/replace filters. That fix was placed only in src/core/filters/filter-base.js; src/core/utils/flex-assembler.js neither imports nor invokes it, so the guard never executes here. A search for maxDepth across src/ returns only the filter base file and its type declaration, and flex-assembler.js imports only {none} from stream-chain/core. Attempts to refute the finding all failed: the join was confirmed to run unconditionally before the match comparison in both the string and RegExp branches; a function-filter negative control stayed flat while the string filter scaled at 4x per doubling, isolating the join as the quadratic cause; and the behavior was reproduced both by driving FlexAssembler directly and end to end through a real parser pipeline. This is not the same issue as the JSONC comment re-scan advisory (GHSA-hqr4-qq8f-hg3x) or the Assembler prototype pollution advisory (GHSA-mjw6-4jj6-33hc), which involve different components, mechanisms, and impact classes.
Affected Versions
Ecosystem: npmPackage: stream-jsonConfirmed affected range: >= 2.0.0, <= 3.6.0Latest release checked: 3.6.0 (npm registry latest)Fix status: not fixed
FlexAssembler was introduced in 2.0.0; the 1.x line has no such component. The vulnerable compileFilter join branches, the uncapped key stack, and the absence of any depth guard are present and effectively identical across the 2.0.0 through 3.6.0 releases, including the current registry latest (3.6.0). No fixed release exists: the depth cap shipped for the related filter issue does not touch FlexAssembler, so every release in the range is affected and a future release remains affected until a FlexAssembler-side bound ships.
Suggested Fix
Enforce a nesting depth bound on the FlexAssembler assembly path, mirroring the maxDepth guard already used by the filter base state machine, so that pathologically deep input is rejected before it drives quadratic work. Alternatively, or in addition, eliminate the per-container full-stack join in compileFilter by maintaining the joined path incrementally (append the new segment on push, truncate on pop) or by comparing the key stack against the filter with a prefix walk that is O(1) amortized per container start rather than O(depth). Any fix must cover both the string and RegExp filter branches and both the object and array rule paths, on both the Node and Web Streams surfaces. As an interim mitigation without a code change, consumers can use function filters (which do not perform the join) or impose an upstream input size or depth limit before the parser.
Reported by zx (GitHub: @manus-pi).
Maintainer note on scope
The attack vector is local — stream-json's documented input is data the user owns (dumps, exports, logs, configuration you wrote); it is not designed for JSON from the open internet, and the docs say so. The crafted document reaches the vulnerable component as a buffer, so AV:L gives 6.2, the same vector and score as GHSA-528h-pc64-c93x and GHSA-hqr4-qq8f-hg3x. FlexAssembler now takes a maxDepth option, default 1024, which throws a RangeError before any rule is matched; Infinity opts out, and once rules are configured the cap covers containers of both kinds, because a rule's path state is kept at every level whatever kind it matches. A follow-up went past what the advisory needed and removed the per-check join entirely — a string filter keeps prefix-match state per level, a RegExp an accumulated path, a function filter the parts array it already received — so deeply nested input is linear now rather than merely capped.
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 3.6.0"
},
"package": {
"ecosystem": "npm",
"name": "stream-json"
},
"ranges": [
{
"events": [
{
"introduced": "2.0.0"
},
{
"fixed": "3.7.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-114129"
],
"database_specific": {
"cwe_ids": [
"CWE-407"
],
"github_reviewed": true,
"github_reviewed_at": "2026-10-22T15:49:54Z",
"nvd_published_at": "2026-10-21T18:17:25Z",
"severity": "MODERATE"
},
"details": "## Summary\n\n`FlexAssembler`, the custom-container assembler shipped in the `stream-json` package (`src/core/utils/flex-assembler.js`, re-exported at `stream-json/utils/flex-assembler.js` and `stream-json/web/utils/flex-assembler.js`), compiles a string or RegExp path `filter` into a matcher that runs `keyStack.join(separator)` on every container start. Because the key stack grows one entry per open object or array with no depth bound, a JSON document nested to depth D drives D container-start tokens that each perform an O(D) join, for O(D^2) total CPU on the single-threaded event loop. An unauthenticated party who can supply JSON bytes to a pipeline that uses a `FlexAssembler` with a string or RegExp rule filter can stall the process with a small input: roughly 96 KB (depth 16000) blocks the event loop for over a second, and the cost grows quadratically.\n\n## Root Cause\n\n`FlexAssembler` reconstructs JavaScript values from the parser token stream and supports custom containers selected by path-matching rules. When a rule `filter` is a string or RegExp, `compileFilter` returns a matcher that computes the joined path from the full key stack before making any match decision. That join is O(current depth), and it is invoked unconditionally for every rule on every container start. The key stack that feeds the join has no depth cap. The package does have a depth guard (`maxDepth`), but it exists only in the unrelated filter base state machine and never executes on the `FlexAssembler` code path, so nested input is unbounded here.\n\n```text\nsrc/core/utils/flex-assembler.js\n compileFilter (lines 5-21): string branch computes `path.join(separator)` (line 10)\n before the `=== filter || startsWith(...)` comparison; RegExp branch computes\n `filter.test(path.join(separator))` (line 17). The join runs first, unconditionally.\n FlexAssembler._matchRule (lines 160-166): calls `rule.filter(this.keyStack)` for every\n rule; invoked from startObject (line 184) and startArray (line 197) on every\n container start.\n FlexAssembler._pushState (lines 168-176): pushes one entry onto `keyStack` per open\n container with no depth bound.\n```\n\n## Impact\n\nAn attacker who can deliver JSON to a pipeline whose `FlexAssembler` is configured with a string or RegExp rule filter (a documented, tested, first-class option: `Filter = string | RegExp | FilterFunction`) can cause quadratic CPU consumption. The join runs regardless of whether the rule ultimately matches, so no attacker knowledge of the schema is required beyond nesting depth, which the attacker fully controls. The demonstrated capability is an availability impact: a small crafted document blocks the Node.js event loop, stalling all concurrent work on the process. There is no confidentiality or integrity impact. A consumer that uses only a function filter or no rules is not affected, which narrows the vulnerable population but does not raise attack complexity once such a configuration is in use.\n\n## Proof of Concept\n\n`Node.js and the published stream-json@3.6.0 package. Drive a FlexAssembler configured with a string rule filter, comparing against a function filter as a negative control.`\n\n1. Install `stream-json@3.6.0`.\n2. Construct a deeply nested object token stream (or equivalently parse a document like `\u0027{\"k\":\u0027` repeated D times, a `1`, then `\u0027}\u0027` repeated D times, through `parser`/`parserStream`).\n3. Feed it to a `FlexAssembler` whose `objectRules` contains a rule with a string `filter`.\n4. Observe wall-clock time scaling as roughly 4x per doubling of D (quadratic), while a function-filter configuration stays flat.\n\n```js\nimport FlexAssembler from \u0027stream-json/utils/flex-assembler.js\u0027;\n\nfunction run(filter, D) {\n const asm = new FlexAssembler(filter ? {objectRules: [{filter, create: () =\u003e ({})}]} : undefined);\n const t = performance.now();\n asm.startObject();\n for (let i = 0; i \u003c D; i++) { asm.keyValue(\u0027k\u0027); asm.startObject(); }\n return performance.now() - t;\n}\n\nfor (const D of [4000, 8000, 16000, 32000]) console.log(\u0027string\u0027, D, run(\u0027k\u0027, D).toFixed(1), \u0027ms\u0027);\nfor (const D of [4000, 8000, 16000, 32000]) console.log(\u0027function(control)\u0027, D, run(p =\u003e p.length \u003e 0, D).toFixed(1), \u0027ms\u0027);\n```\n\n```text\nstring filter (path.join per token): function filter (negative control, no join):\n D=4000 91.9 ms D=4000 1.6 ms\n D=8000 341.9 ms D=8000 0.9 ms\n D=16000 1359.2 ms (~4x per doubling) D=16000 1.7 ms (flat)\n D=32000 5430.0 ms (= O(D^2)) D=32000 2.6 ms\n```\n\nEnd to end through a real `parserStream`, roughly 96 KB (depth 16000) of attacker-supplied JSON stalls the event loop for over 1.3 seconds.\n\n## Attack Chain\n\n1. **Exposure:** The attacker supplies JSON bytes to a service pipeline that assembles values with a `FlexAssembler` configured with a string or RegExp rule filter; `FlexAssembler` is a documented submodule of the published package on both the Node and Web Streams surfaces.\n2. **Control:** The attacker controls the JSON bytes and therefore the nesting depth D, which directly controls the key stack length.\n3. **Path:** Each `{` or `[` emits `startObject`/`startArray`, which push onto `keyStack` and call `_matchRule`, which calls the compiled filter with the current key stack.\n4. **Guard:** There is no depth or size cap on this path; the only `maxDepth` guard in the package lives in the filter base state machine and never runs in `FlexAssembler`.\n5. **Primitive:** For each of the D container starts, the compiled string/RegExp filter runs an O(D) `join` before any match decision, for O(D^2) total CPU.\n6. **Result:** The single-threaded event loop stalls, denying service to all concurrent work on the process; a small input scales quadratically to sustained unavailability.\n\n## Bypass Evidence\n\nThis is a novel finding on a code path that no prior fix protects, so there is no guard to bypass on the `FlexAssembler` path. The relevant prior fix is the `maxDepth` cap published as part of the remediation for CVE-2026-71429 (GHSA-528h-pc64-c93x), which addressed the analogous O(depth^2) behavior in the `pick`/`ignore`/`filter`/`replace` filters. That fix was placed only in `src/core/filters/filter-base.js`; `src/core/utils/flex-assembler.js` neither imports nor invokes it, so the guard never executes here. A search for `maxDepth` across `src/` returns only the filter base file and its type declaration, and `flex-assembler.js` imports only `{none}` from `stream-chain/core`. Attempts to refute the finding all failed: the join was confirmed to run unconditionally before the match comparison in both the string and RegExp branches; a function-filter negative control stayed flat while the string filter scaled at 4x per doubling, isolating the join as the quadratic cause; and the behavior was reproduced both by driving `FlexAssembler` directly and end to end through a real parser pipeline. This is not the same issue as the JSONC comment re-scan advisory (GHSA-hqr4-qq8f-hg3x) or the Assembler prototype pollution advisory (GHSA-mjw6-4jj6-33hc), which involve different components, mechanisms, and impact classes.\n\n## Affected Versions\n\n- `Ecosystem: npm`\n- `Package: stream-json`\n- `Confirmed affected range: \u003e= 2.0.0, \u003c= 3.6.0`\n- `Latest release checked: 3.6.0 (npm registry latest)`\n- `Fix status: not fixed`\n\n`FlexAssembler` was introduced in 2.0.0; the 1.x line has no such component. The vulnerable `compileFilter` join branches, the uncapped key stack, and the absence of any depth guard are present and effectively identical across the 2.0.0 through 3.6.0 releases, including the current registry `latest` (3.6.0). No fixed release exists: the depth cap shipped for the related filter issue does not touch `FlexAssembler`, so every release in the range is affected and a future release remains affected until a `FlexAssembler`-side bound ships.\n\n## Suggested Fix\n\nEnforce a nesting depth bound on the `FlexAssembler` assembly path, mirroring the `maxDepth` guard already used by the filter base state machine, so that pathologically deep input is rejected before it drives quadratic work. Alternatively, or in addition, eliminate the per-container full-stack `join` in `compileFilter` by maintaining the joined path incrementally (append the new segment on push, truncate on pop) or by comparing the key stack against the filter with a prefix walk that is O(1) amortized per container start rather than O(depth). Any fix must cover both the string and RegExp filter branches and both the object and array rule paths, on both the Node and Web Streams surfaces. As an interim mitigation without a code change, consumers can use function filters (which do not perform the join) or impose an upstream input size or depth limit before the parser.\n\n---\n\nReported by zx (GitHub: @manus-pi).\n\n---\n\n# Maintainer note on scope\n\nThe attack vector is local \u0026mdash; stream-json\u0027s documented input is data the user owns (dumps, exports, logs, configuration you wrote); it is not designed for JSON from the open internet, and the docs say so. The crafted document reaches the vulnerable component as a buffer, so `AV:L` gives 6.2, the same vector and score as GHSA-528h-pc64-c93x and GHSA-hqr4-qq8f-hg3x. `FlexAssembler` now takes a `maxDepth` option, default `1024`, which throws a `RangeError` before any rule is matched; `Infinity` opts out, and once rules are configured the cap covers containers of both kinds, because a rule\u0027s path state is kept at every level whatever kind it matches. A follow-up went past what the advisory needed and removed the per-check join entirely \u0026mdash; a string filter keeps prefix-match state per level, a RegExp an accumulated path, a function filter the parts array it already received \u0026mdash; so deeply nested input is linear now rather than merely capped.",
"id": "GHSA-jj87-hc4r-jwfw",
"modified": "2026-10-22T15:49:54Z",
"published": "2026-10-22T15:49:54Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/uhop/stream-json/security/advisories/GHSA-jj87-hc4r-jwfw"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-114129"
},
{
"type": "WEB",
"url": "https://github.com/uhop/stream-json/commit/1929fd80495d45b47e8f8cb1d4e132f915aef012"
},
{
"type": "WEB",
"url": "https://github.com/uhop/stream-json/commit/c06c9a3c02adef89543e26ecebb45837cb284512"
},
{
"type": "PACKAGE",
"url": "https://github.com/uhop/stream-json"
},
{
"type": "WEB",
"url": "https://github.com/uhop/stream-json/releases/tag/3.7.0"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
],
"summary": "stream-json: FlexAssembler string/RegExp path filters join the full key stack per container start, giving O(depth^2) CPU denial of service"
}
GHSA-JJV6-8J6V-6J52
Vulnerability from github – Published: 2026-09-01 20:21 – Updated: 2026-09-01 20:21Impact
Two first-party extensions contain quadratic parsing paths. Both ship with the library but must be explicitly registered on the Environment; neither is included in CommonMarkConverter, GithubFlavoredMarkdownConverter, or GithubFlavoredMarkdownExtension. Applications that do not register SmartPunctExtension or AttributesExtension are not affected by this advisory.
1. SmartPunctExtension — quote replacement recopies the whole text node (affected from 2.0.0).
ReplaceUnpairedQuotesListener converts each unpaired Quote node back to a Text node and merges it into its neighbours via AdjacentTextMerger. The merge reads the left node's literal into a local variable, appends to that variable, and writes it back — and because the read aliases the node's string, every append copies the entire accumulated literal rather than only the bytes added. The listener runs this once per surviving unpaired quote against the same continuously growing text node, so the same buffer is fully re-copied a linear number of times.
A 1.2 MB document of alternating text segments and apostrophes takes 34.9 seconds to convert, against 0.069 seconds for the same input with the extension not registered.
Hardened configuration makes this worse rather than better: QuoteParser appends the Quote node to the AST before pushing it onto the delimiter stack, so max_delimiters_per_line removes the quote-pairing work while leaving every node the listener must process.
2. AttributesExtension — block-level attribute runs re-scan their siblings (affected from 1.5.0).
AttributesListener::findTargetAndDirection() walks the entire remaining sibling chain for every block-level Attributes node whose target is the following node. The backward half of that walk returns immediately for such nodes, and the forward half stops only at a sibling that is not itself an attributes node — which a contiguous run never provides — so a run of k nodes costs k(k-1)/2 steps.
An input placing each {#a} on its own line, with a single reference definition to keep the run contiguous, takes 28.4 seconds at 16,000 attribute blocks while producing zero bytes of output.
This is the block-level counterpart of GHSA-g2gp-3wwq-f4ph, patched in 2.9.0. That fix is incomplete: the early break it introduced is guarded on the node being an AttributesInline, so block-level Attributes nodes still re-scan. Applications that upgraded to 2.9.0 specifically to address GHSA-g2gp-3wwq-f4ph remain exposed to this variant.
3. AttributesExtension — class lists are rebuilt on every merge (affected from 1.5.0).
AttributesHelper::mergeAttributes() round-trips the accumulated class list through explode and implode on each merge. An #id attribute assigns a scalar and skips the branch entirely, but a .class attribute appends to an array which is then imploded to a string, written to the target node, and read back on the next iteration — so the ith merge pays a cost proportional to i three separate times.
{.c} repeated 32,000 times takes 33.5 seconds, against 0.26 seconds for byte-identical input using {#a} — a 130x gap that widens with input size. Both the inline and the block-level attribute paths are affected.
Overall impact. An unauthenticated attacker who can submit Markdown to an affected application can consume disproportionate CPU time with a comparatively small request, occupying PHP workers and preventing legitimate requests from completing. The impact is limited to availability: no data is disclosed, rendered output is unchanged, and no rendering restriction is bypassed.
No library-level configuration gates any of these paths. For the Attributes extension in particular, neither the attributes/allow allow-list nor the on* event-handler hardening added in 2.7.0 has any effect, because the expensive work happens while parsing and resolving the AST, before any attribute filtering or rendering takes place.
Patches
The issues are patched in 2.9.1 and later:
- Adjacent text merging now appends in place instead of reading, modifying, and writing back the whole literal, so a merge costs only the bytes added. This fixes the defect for every caller, not only the SmartPunct listener.
AttributesListenernow records the runs it has already walked, so each contiguous run of block-level attribute nodes is scanned once rather than once per node.- Accumulated class lists no longer pass through
mergeAttributes()repeatedly; the listener holds pending attributes and joins them in a single pass.
The SmartPunct path affects 2.0.0 through 2.9.0. The Attributes paths affect 1.5.0 through 2.9.0, including releases that already contain the 2.9.0 fix for GHSA-g2gp-3wwq-f4ph. The 1.x release line is no longer supported, so its users must upgrade to 2.9.1 or later.
Workarounds
If you cannot upgrade immediately:
- Do not register
SmartPunctExtensionorAttributesExtensionwhen converting untrusted Markdown. This fully removes the affected paths. - If either extension is required, impose a strict maximum input length before conversion. Because the cost is quadratic, even a modest cap must be small to meaningfully bound worst-case CPU time.
Restricting conversion to trusted users, applying strict execution-time limits, and rate-limiting requests reduce exposure but are not substitutes for upgrading. Configuration options including attributes/allow, max_delimiters_per_line, max_nesting_level, html_input, and allow_unsafe_links do not mitigate these issues.
{
"affected": [
{
"package": {
"ecosystem": "Packagist",
"name": "league/commonmark"
},
"ranges": [
{
"events": [
{
"introduced": "1.5.0"
},
{
"fixed": "2.9.1"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [],
"database_specific": {
"cwe_ids": [
"CWE-1050",
"CWE-407"
],
"github_reviewed": true,
"github_reviewed_at": "2026-09-01T20:21:45Z",
"nvd_published_at": null,
"severity": "HIGH"
},
"details": "### Impact\n\nTwo first-party extensions contain quadratic parsing paths. Both ship with the library but must be explicitly registered on the `Environment`; neither is included in `CommonMarkConverter`, `GithubFlavoredMarkdownConverter`, or `GithubFlavoredMarkdownExtension`. **Applications that do not register `SmartPunctExtension` or `AttributesExtension` are not affected by this advisory.**\n\n**1. `SmartPunctExtension` \u2014 quote replacement recopies the whole text node (affected from 2.0.0).**\n\n`ReplaceUnpairedQuotesListener` converts each unpaired `Quote` node back to a `Text` node and merges it into its neighbours via `AdjacentTextMerger`. The merge reads the left node\u0027s literal into a local variable, appends to that variable, and writes it back \u2014 and because the read aliases the node\u0027s string, every append copies the entire accumulated literal rather than only the bytes added. The listener runs this once per surviving unpaired quote against the same continuously growing text node, so the same buffer is fully re-copied a linear number of times.\n\nA 1.2 MB document of alternating text segments and apostrophes takes 34.9 seconds to convert, against 0.069 seconds for the same input with the extension not registered.\n\nHardened configuration makes this *worse* rather than better: `QuoteParser` appends the `Quote` node to the AST before pushing it onto the delimiter stack, so `max_delimiters_per_line` removes the quote-pairing work while leaving every node the listener must process.\n\n**2. `AttributesExtension` \u2014 block-level attribute runs re-scan their siblings (affected from 1.5.0).**\n\n`AttributesListener::findTargetAndDirection()` walks the entire remaining sibling chain for every block-level `Attributes` node whose target is the following node. The backward half of that walk returns immediately for such nodes, and the forward half stops only at a sibling that is not itself an attributes node \u2014 which a contiguous run never provides \u2014 so a run of k nodes costs k(k-1)/2 steps.\n\nAn input placing each `{#a}` on its own line, with a single reference definition to keep the run contiguous, takes 28.4 seconds at 16,000 attribute blocks while producing **zero bytes of output**.\n\nThis is the block-level counterpart of GHSA-g2gp-3wwq-f4ph, patched in 2.9.0. **That fix is incomplete:** the early break it introduced is guarded on the node being an `AttributesInline`, so block-level `Attributes` nodes still re-scan. Applications that upgraded to 2.9.0 specifically to address GHSA-g2gp-3wwq-f4ph remain exposed to this variant.\n\n**3. `AttributesExtension` \u2014 class lists are rebuilt on every merge (affected from 1.5.0).**\n\n`AttributesHelper::mergeAttributes()` round-trips the accumulated class list through `explode` and `implode` on each merge. An `#id` attribute assigns a scalar and skips the branch entirely, but a `.class` attribute appends to an array which is then imploded to a string, written to the target node, and read back on the next iteration \u2014 so the *i*th merge pays a cost proportional to *i* three separate times.\n\n`{.c}` repeated 32,000 times takes 33.5 seconds, against 0.26 seconds for byte-identical input using `{#a}` \u2014 a 130x gap that widens with input size. Both the inline and the block-level attribute paths are affected.\n\n**Overall impact.** An unauthenticated attacker who can submit Markdown to an affected application can consume disproportionate CPU time with a comparatively small request, occupying PHP workers and preventing legitimate requests from completing. The impact is limited to availability: no data is disclosed, rendered output is unchanged, and no rendering restriction is bypassed.\n\nNo library-level configuration gates any of these paths. For the Attributes extension in particular, neither the `attributes/allow` allow-list nor the `on*` event-handler hardening added in 2.7.0 has any effect, because the expensive work happens while parsing and resolving the AST, before any attribute filtering or rendering takes place.\n\n### Patches\n\nThe issues are patched in `2.9.1` and later:\n\n- Adjacent text merging now appends in place instead of reading, modifying, and writing back the whole literal, so a merge costs only the bytes added. This fixes the defect for every caller, not only the SmartPunct listener.\n- `AttributesListener` now records the runs it has already walked, so each contiguous run of block-level attribute nodes is scanned once rather than once per node.\n- Accumulated class lists no longer pass through `mergeAttributes()` repeatedly; the listener holds pending attributes and joins them in a single pass.\n\nThe SmartPunct path affects `2.0.0` through `2.9.0`. The Attributes paths affect `1.5.0` through `2.9.0`, including releases that already contain the 2.9.0 fix for GHSA-g2gp-3wwq-f4ph. The 1.x release line is no longer supported, so its users must upgrade to `2.9.1` or later.\n\n### Workarounds\n\nIf you cannot upgrade immediately:\n\n- **Do not register `SmartPunctExtension` or `AttributesExtension`** when converting untrusted Markdown. This fully removes the affected paths.\n- If either extension is required, **impose a strict maximum input length before conversion**. Because the cost is quadratic, even a modest cap must be small to meaningfully bound worst-case CPU time.\n\nRestricting conversion to trusted users, applying strict execution-time limits, and rate-limiting requests reduce exposure but are not substitutes for upgrading. Configuration options including `attributes/allow`, `max_delimiters_per_line`, `max_nesting_level`, `html_input`, and `allow_unsafe_links` do not mitigate these issues.",
"id": "GHSA-jjv6-8j6v-6j52",
"modified": "2026-09-01T20:21:45Z",
"published": "2026-09-01T20:21:45Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/thephpleague/commonmark/security/advisories/GHSA-jjv6-8j6v-6j52"
},
{
"type": "WEB",
"url": "https://github.com/thephpleague/commonmark/commit/04a5d11ef6bf2d0b927310810d6a2a85d3c184b9"
},
{
"type": "WEB",
"url": "https://github.com/thephpleague/commonmark/commit/2f611b599c51661b005dc45c16ceaa547546e687"
},
{
"type": "PACKAGE",
"url": "https://github.com/thephpleague/commonmark"
},
{
"type": "WEB",
"url": "https://github.com/thephpleague/commonmark/releases/tag/2.9.1"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
],
"summary": "league/commonmark: Denial of service in the SmartPunct and Attributes extensions"
}
GHSA-JQ2X-C3X3-GV8C
Vulnerability from github – Published: 2026-10-28 18:32 – Updated: 2026-11-05 21:34MIME::Words versions before 5.521 for Perl allow memory exhaustion via repeated "=?" sequences in decode_mimewords.
For each "=?" that does not start a complete encoded word, decode_mimewords appends an error message containing the whole input string to $@. A boundary of 8,000 "=?" pairs (16,000 bytes) adds 8,000 copies of itself to $@, about 128 MB.
From version 5.518, MIME::Parser decodes every multipart boundary this way, so a remote sender can exhaust the memory of the parsing process with one Content-Type header.
{
"affected": [],
"aliases": [
"CVE-2026-116270"
],
"database_specific": {
"cwe_ids": [
"CWE-407"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-10-28T18:17:13Z",
"severity": "HIGH"
},
"details": "MIME::Words versions before 5.521 for Perl allow memory exhaustion via repeated \"=?\" sequences in decode_mimewords.\n\nFor each \"=?\" that does not start a complete encoded word, decode_mimewords appends an error message containing the whole input string to $@. A boundary of 8,000 \"=?\" pairs (16,000 bytes) adds 8,000 copies of itself to $@, about 128 MB.\n\nFrom version 5.518, MIME::Parser decodes every multipart boundary this way, so a remote sender can exhaust the memory of the parsing process with one Content-Type header.",
"id": "GHSA-jq2x-c3x3-gv8c",
"modified": "2026-11-05T21:34:42Z",
"published": "2026-10-28T18:32:13Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-116270"
},
{
"type": "WEB",
"url": "https://metacpan.org/release/DSKOLL/MIME-tools-5.521/changes"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-JR96-GVGH-J3R4
Vulnerability from github – Published: 2026-10-23 20:54 – Updated: 2026-10-23 20:54Impact
An attacker who uses this vulnerability can craft a PDF which leads to long runtimes. This requires cross-reference streams with repeated malformed cross-reference streams.
Patches
This has been fixed in pypdf==6.21.2.
Workarounds
If you cannot upgrade yet, consider applying the changes from PR #4240.
Notes
This is a follow-up to https://github.com/py-pdf/pypdf/security/advisories/GHSA-55h5-xmcq-c37v, which had the side-effect of still loading the whole stream again despite the cache being present.
{
"affected": [
{
"package": {
"ecosystem": "PyPI",
"name": "pypdf"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "6.21.2"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-115585"
],
"database_specific": {
"cwe_ids": [
"CWE-400",
"CWE-407"
],
"github_reviewed": true,
"github_reviewed_at": "2026-10-23T20:54:27Z",
"nvd_published_at": null,
"severity": "HIGH"
},
"details": "### Impact\n\nAn attacker who uses this vulnerability can craft a PDF which leads to long runtimes. This requires cross-reference streams with repeated malformed cross-reference streams.\n\n### Patches\n\nThis has been fixed in [pypdf==6.21.2](https://github.com/py-pdf/pypdf/releases/tag/6.21.2).\n\n### Workarounds\n\nIf you cannot upgrade yet, consider applying the changes from PR [#4240](https://github.com/py-pdf/pypdf/pull/4240).\n\n### Notes\n\nThis is a follow-up to https://github.com/py-pdf/pypdf/security/advisories/GHSA-55h5-xmcq-c37v, which had the side-effect of still loading the whole stream again despite the cache being present.",
"id": "GHSA-jr96-gvgh-j3r4",
"modified": "2026-10-23T20:54:27Z",
"published": "2026-10-23T20:54:27Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/security/advisories/GHSA-jr96-gvgh-j3r4"
},
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/pull/4240"
},
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/commit/68a0e5046cc9e14a6c24a21a713f3c7fbde18b4b"
},
{
"type": "PACKAGE",
"url": "https://github.com/py-pdf/pypdf"
},
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/releases/tag/6.21.2"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N",
"type": "CVSS_V4"
}
],
"summary": "pypdf: Possible long runtimes for repeated malformed cross-reference entries (Follow-up)"
}
GHSA-JRM6-H9CQ-8GQW
Vulnerability from github – Published: 2023-06-30 22:17 – Updated: 2023-06-30 22:17Impact
An attacker who uses this vulnerability can craft a PDF which leads to unexpected long runtime. This quadratic runtime blocks the current process and can utilize a single core of the CPU by 100%. It does not affect memory usage.
Patches
https://github.com/py-pdf/pypdf/pull/808
Workarounds
Is there a way for users to fix or remediate the vulnerability without upgrading?
References
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 1.27.8"
},
"package": {
"ecosystem": "PyPI",
"name": "PyPDF2"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.27.9"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2023-36810"
],
"database_specific": {
"cwe_ids": [
"CWE-407"
],
"github_reviewed": true,
"github_reviewed_at": "2023-06-30T22:17:52Z",
"nvd_published_at": "2023-06-30T19:15:09Z",
"severity": "MODERATE"
},
"details": "### Impact\nAn attacker who uses this vulnerability can craft a PDF which leads to unexpected long runtime.\nThis quadratic runtime blocks the current process and can utilize a single core of the CPU by 100%. It does not affect memory usage.\n\n### Patches\nhttps://github.com/py-pdf/pypdf/pull/808\n\n### Workarounds\n_Is there a way for users to fix or remediate the vulnerability without upgrading?_\n\n### References\n* [PyPDF2 PR #808](https://github.com/py-pdf/pypdf/pull/808)\n* [PyPDF2 Issue #582](https://github.com/py-pdf/pypdf/issues/582)",
"id": "GHSA-jrm6-h9cq-8gqw",
"modified": "2023-06-30T22:17:52Z",
"published": "2023-06-30T22:17:52Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/security/advisories/GHSA-jrm6-h9cq-8gqw"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-36810"
},
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/issues/582"
},
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/pull/808"
},
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/commit/c6c56f550bb384e05f0139c796ba1308837d6373"
},
{
"type": "PACKAGE",
"url": "https://github.com/py-pdf/pypdf"
},
{
"type": "WEB",
"url": "https://lists.debian.org/debian-lts-announce/2023/07/msg00019.html"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
],
"summary": "PyPDF2 quadratic runtime with malformed PDF missing xref marker"
}
GHSA-JW7Q-GVRG-4VJ3
Vulnerability from github – Published: 2026-10-01 15:06 – Updated: 2026-10-01 15:06Impact
An attacker who uses this vulnerability can craft a PDF which leads to long runtimes. This requires a partially malformed /FlateDecode stream, where the byte-by-byte decompression is used.
Patches
This has been fixed in pypdf==6.18.1.
Workarounds
If you cannot upgrade yet, consider applying the changes from PR #4073.
{
"affected": [
{
"package": {
"ecosystem": "PyPI",
"name": "pypdf"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "6.18.1"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-102997"
],
"database_specific": {
"cwe_ids": [
"CWE-400",
"CWE-407"
],
"github_reviewed": true,
"github_reviewed_at": "2026-10-01T15:06:33Z",
"nvd_published_at": "2026-09-30T21:17:07Z",
"severity": "HIGH"
},
"details": "### Impact\n\nAn attacker who uses this vulnerability can craft a PDF which leads to long runtimes. This requires a partially malformed `/FlateDecode` stream, where the byte-by-byte decompression is used.\n\n### Patches\n\nThis has been fixed in [pypdf==6.18.1](https://github.com/py-pdf/pypdf/releases/tag/6.18.1).\n\n### Workarounds\n\nIf you cannot upgrade yet, consider applying the changes from PR [#4073](https://github.com/py-pdf/pypdf/pull/4073).",
"id": "GHSA-jw7q-gvrg-4vj3",
"modified": "2026-10-01T15:06:34Z",
"published": "2026-10-01T15:06:33Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/security/advisories/GHSA-jw7q-gvrg-4vj3"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-102997"
},
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/pull/4073"
},
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/commit/d9d38cf99b115deb562d3b68f36c33027bc04f79"
},
{
"type": "PACKAGE",
"url": "https://github.com/py-pdf/pypdf"
},
{
"type": "WEB",
"url": "https://github.com/py-pdf/pypdf/releases/tag/6.18.1"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N",
"type": "CVSS_V4"
}
],
"summary": "pypdf: Possible long runtimes for partially malformed FlateDecode streams (Follow-up)"
}
GHSA-M28H-PJ36-4364
Vulnerability from github – Published: 2026-11-10 23:08 – Updated: 2026-11-10 23:08Executive summary
Microsoft is releasing this security advisory to provide information about a vulnerability in ASP.NET Core. This advisory provides guidance on updating affected applications and components.
Minimal API validation repeatedly copies a growing validation-error dictionary, allowing attacker-controlled collections to trigger quadratic CPU work after the client disconnects.
Announcement
Announcement for this issue can be found at https://github.com/dotnet/announcements/issues/505
CVSS Details
- Version: 3.1
- Severity: High
- Score: 7.5 (base score)
- Vector:
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H/E:U/RL:O/RC:C - Weakness: CWE-407
Affected Platforms
- Platforms: Windows, Linux, macOS
- Architectures: All
Affected Packages
The tables list affected version ranges and fixed package versions. Runtime and standalone deliveries are listed separately.
.NET 11.0 - affected runtime packages
| Package | Affected version | Patched version |
|---|---|---|
| Microsoft.AspNetCore.App.Runtime.linux-arm | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.linux-arm64 | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.linux-musl-arm | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.linux-musl-arm64 | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.linux-musl-x64 | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.linux-x64 | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.osx-arm64 | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.osx-x64 | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.win-arm64 | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.win-x64 | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
| Microsoft.AspNetCore.App.Runtime.win-x86 | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
Standalone validation delivery
| Package | Affected version | Patched version |
|---|---|---|
| Microsoft.Extensions.Validation | >= 11.0.0-rc.1.26425.128, <= 11.0.0-rc.3.26522.148 | 11.0.0 |
Advisory FAQ
How do I know if I am affected?
Check the deployed runtime and application package versions against the affected ranges above. Self-contained applications include their own runtime; updating a machine-wide runtime does not replace it.
How do I fix the issue?
Install the applicable runtime or update each independently referenced package to the fixed version above. Restart applications. Rebuild and redeploy self-contained applications; updating a machine-wide runtime does not replace their embedded runtime. An SDK update alone does not update an application's standalone package references.
Other Information
Reporting Security Issues
If you have found a potential security issue in a supported version of .NET, please report it to the Microsoft Security Response Center (MSRC) via the MSRC Researcher Portal. Further information can be found in the MSRC Report an Issue FAQ.
Security reports made through MSRC may qualify for the Microsoft .NET Bounty. Details of the Microsoft .NET Bounty Program including terms and conditions are at https://aka.ms/corebounty.
Support
You can ask questions about this issue on GitHub in the .NET GitHub organization. The main repos are located at https://github.com/dotnet/runtime. The Announcements repo (https://github.com/dotnet/Announcements) will contain this bulletin as an issue and will include a link to a discussion issue. You can ask questions in the linked discussion issue.
Disclaimer
The information provided in this advisory is provided "as is" without warranty of any kind. Microsoft disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. In no event shall Microsoft Corporation or its suppliers be liable for any damages whatsoever including direct, indirect, incidental, consequential, loss of business profits or special damages, even if Microsoft Corporation or its suppliers have been advised of the possibility of such damages. Some states do not allow the exclusion or limitation of liability for consequential or incidental damages so the foregoing limitation may not apply.
External Links
Acknowledgements
- Alejandro Pacheco
- Artur Stetsko
Revisions
V1.0 (November 10, 2026): Advisory published.
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.linux-arm"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.linux-arm64"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.linux-musl-arm"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.linux-musl-arm64"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.linux-musl-x64"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.linux-x64"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.osx-arm64"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.osx-x64"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.win-arm64"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.win-x64"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.AspNetCore.App.Runtime.win-x86"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 11.0.0-rc.3.26522.148"
},
"package": {
"ecosystem": "NuGet",
"name": "Microsoft.Extensions.Validation"
},
"ranges": [
{
"events": [
{
"introduced": "11.0.0-rc.1.26425.128"
},
{
"fixed": "11.0.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-118749"
],
"database_specific": {
"cwe_ids": [
"CWE-407"
],
"github_reviewed": true,
"github_reviewed_at": "2026-11-10T23:08:34Z",
"nvd_published_at": "2026-11-10T19:19:51Z",
"severity": "MODERATE"
},
"details": "## Executive summary\n\nMicrosoft is releasing this security advisory to provide information about a vulnerability in ASP.NET Core. This advisory provides guidance on updating affected applications and components.\n\nMinimal API validation repeatedly copies a growing validation-error dictionary, allowing attacker-controlled collections to trigger quadratic CPU work after the client disconnects.\n\n## Announcement\n\nAnnouncement for this issue can be found at https://github.com/dotnet/announcements/issues/505\n\n## CVSS Details\n\n- **Version:** 3.1\n- **Severity:** High\n- **Score:** 7.5 (base score)\n- **Vector:** `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H/E:U/RL:O/RC:C`\n- **Weakness:** CWE-407\n\n## Affected Platforms\n\n- **Platforms:** Windows, Linux, macOS\n- **Architectures:** All\n\n## \u003ca name=\"affected-packages\"\u003e\u003c/a\u003eAffected Packages\n\nThe tables list affected version ranges and fixed package versions. Runtime and standalone deliveries are listed separately.\n\n### .NET 11.0 - affected runtime packages\n\nPackage | Affected version | Patched version\n--- | --- | ---\n[Microsoft.AspNetCore.App.Runtime.linux-arm](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.linux-arm) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.linux-arm64](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.linux-arm64) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.linux-musl-arm](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.linux-musl-arm) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.linux-musl-arm64](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.linux-musl-arm64) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.linux-musl-x64](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.linux-musl-x64) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.linux-x64](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.linux-x64) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.osx-arm64](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.osx-arm64) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.osx-x64](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.osx-x64) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.win-arm64](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.win-arm64) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.win-x64](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.win-x64) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n[Microsoft.AspNetCore.App.Runtime.win-x86](https://www.nuget.org/packages/Microsoft.AspNetCore.App.Runtime.win-x86) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n\n### Standalone validation delivery\n\nPackage | Affected version | Patched version\n--- | --- | ---\n[Microsoft.Extensions.Validation](https://www.nuget.org/packages/Microsoft.Extensions.Validation) | \u003e= 11.0.0-rc.1.26425.128, \u003c= 11.0.0-rc.3.26522.148 | 11.0.0\n\n## Advisory FAQ\n\n### \u003ca name=\"how-affected\"\u003e\u003c/a\u003eHow do I know if I am affected?\n\nCheck the deployed runtime and application package versions against the affected ranges above. Self-contained applications include their own runtime; updating a machine-wide runtime does not replace it.\n\n### \u003ca name=\"how-fix\"\u003e\u003c/a\u003eHow do I fix the issue?\n\nInstall the applicable runtime or update each independently referenced package to the fixed version above. Restart applications. Rebuild and redeploy self-contained applications; updating a machine-wide runtime does not replace their embedded runtime. An SDK update alone does not update an application\u0027s standalone package references.\n\n## Other Information\n\n### Reporting Security Issues\n\nIf you have found a potential security issue in a supported version of .NET, please report it to the Microsoft Security Response Center (MSRC) via the [MSRC Researcher Portal](https://msrc.microsoft.com/report/vulnerability/new). Further information can be found in the MSRC [Report an Issue FAQ](https://www.microsoft.com/msrc/faqs-report-an-issue).\n\nSecurity reports made through MSRC may qualify for the Microsoft .NET Bounty. Details of the Microsoft .NET Bounty Program including terms and conditions are at https://aka.ms/corebounty.\n\n### Support\n\nYou can ask questions about this issue on GitHub in the .NET GitHub organization. The main repos are located at https://github.com/dotnet/runtime. The Announcements repo (https://github.com/dotnet/Announcements) will contain this bulletin as an issue and will include a link to a discussion issue. You can ask questions in the linked discussion issue.\n\n### Disclaimer\n\nThe information provided in this advisory is provided \"as is\" without warranty of any kind. Microsoft disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. In no event shall Microsoft Corporation or its suppliers be liable for any damages whatsoever including direct, indirect, incidental, consequential, loss of business profits or special damages, even if Microsoft Corporation or its suppliers have been advised of the possibility of such damages. Some states do not allow the exclusion or limitation of liability for consequential or incidental damages so the foregoing limitation may not apply.\n\n### External Links\n\n[CVE-2026-118749](https://www.cve.org/CVERecord?id=CVE-2026-118749)\n\n### Acknowledgements\n\n- Alejandro Pacheco\n- Artur Stetsko\n\n### Revisions\n\nV1.0 (November 10, 2026): Advisory published.",
"id": "GHSA-m28h-pj36-4364",
"modified": "2026-11-10T23:08:34Z",
"published": "2026-11-10T23:08:34Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/dotnet/aspnetcore/security/advisories/GHSA-m28h-pj36-4364"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-118749"
},
{
"type": "WEB",
"url": "https://github.com/dotnet/announcements/issues/505"
},
{
"type": "PACKAGE",
"url": "https://github.com/dotnet/aspnetcore"
},
{
"type": "WEB",
"url": "https://github.com/dotnet/aspnetcore/discussions/70468"
},
{
"type": "WEB",
"url": "https://github.com/dotnet/aspnetcore/releases/tag/v11.0.0"
},
{
"type": "WEB",
"url": "https://github.com/dotnet/core/blob/main/release-notes/11.0/11.0.0/11.0.0.md"
},
{
"type": "WEB",
"url": "https://msrc.microsoft.com/update-guide/vulnerability/CVE-2026-118749"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H/E:U/RL:O/RC:C",
"type": "CVSS_V3"
}
],
"summary": "Microsoft Security Advisory CVE-2026-118749 - ASP.NET Core Denial of Service Vulnerability"
}
No mitigation information available for this CWE.
No CAPEC attack patterns related to this CWE.