fpdf2: Exponential SVG '<use>' expansion causes CPU and memory exhaustion in 'FPDF.image()'
Affected packages
| Package | Affected → Fixed | |
|---|---|---|
| py-pdffpdf2 | — | Not listed |
| pipfpdf2 |
< 2.8.8→ 2.8.8 |
2.8.8 |
| PyPIfpdf2 |
≥ 2.5.0, < 2.8.8→ 2.8.8 |
2.8.8 |
Fix status by distribution
Records published by each distribution for this CVE. Fixed versions differ by release; check each link.
- Debian DEBIAN-CVE-2026-114610 fpdf2 Fix available
- Ubuntu UBUNTU-CVE-2026-114610 fpdf2 No fixed version in this record
Original description The description as published by the source.
fpdf2 is a PDF creation library for Python. From 2.5.0 until 2.8.8, fpdf2's SVGObject.build_xref() passes nested SVG references to GraphicsContext.add_item(), whose default clone=True deep-copy behavior copies the complete referenced graphics tree during FPDF.image() processing. Repeating references at each nesting level makes the in-memory object count and processing work grow exponentially, allowing a small user-controlled SVG to consume excessive CPU and memory, raise MemoryError, fail PDF generation jobs, and reduce or exhaust worker capacity. ResourceAccessPolicy does not prevent the issue because the references are inline and require no external resource, XML entity, local file, or permissive network setting. This issue is fixed in version 2.8.8.
Source: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory
References
- advisory github.com
- advisory github.com
- advisory nvd.nist.gov
- package github.com
- patch github.com
- patch github.com
- web github.com
- web github.com