Description
CairoSVG is an SVG converter based on Cairo, a 2D graphics library. Prior to 2.9.1, rendering an attacker-controlled SVG with a path containing many segments can cause quadratic CPU consumption in cairosvg/path.py. The path tokenizer repeatedly slices and rescans the remaining path data, while draw_markers drains node.vertices with node.vertices.pop(0), causing repeated linear-time work. The svg2png, svg2pdf, and svg2ps APIs reach these operations during ordinary rendering, allowing a sub-megabyte SVG to consume substantial CPU and deny service to a rendering application. This issue is fixed in version 2.9.1.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| Kozea | CairoSVG | < 2.9.1 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | cairosvg | 2.9.1-1 | — |
| Debian 13 | cairosvg | No fix yet | — |
| Debian 12 | cairosvg | No fix yet | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 24.04 LTS | cairosvg | No fix yet | — |
| Ubuntu 22.04 LTS | cairosvg | No fix yet | — |
| Ubuntu 20.04 LTS | cairosvg | No fix yet | — |
| Ubuntu 18.04 LTS | cairosvg | No fix yet | — |
| Ubuntu 16.04 LTS | cairosvg | No fix yet | — |
SUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLES 15 SP6 | python-CairoSVG | 2.7.1-150400.9.9.1 | SUSE-SU-2026:4949-1 |
| SLES 15 SP5 | python-CairoSVG | 2.7.1-150400.9.9.1 | SUSE-SU-2026:4949-1 |
| SLES 15 SP4 | python-CairoSVG | 2.7.1-150400.9.9.1 | SUSE-SU-2026:4949-1 |
| SLES 3 | python-CairoSVG | 2.7.1-150400.9.9.1 | SUSE-SU-2026:4949-1 |
Show 7 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLES for SAP 16.0 | python-CairoSVG | 2.7.1-160000.4.1 | SUSE-SU-2026:24596-1 |
| SLES for SAP 15 SP6 | python-CairoSVG | 2.7.1-150400.9.9.1 | SUSE-SU-2026:4949-1 |
| SLES for SAP 15 SP5 | python-CairoSVG | 2.7.1-150400.9.9.1 | SUSE-SU-2026:4949-1 |
| SLES for SAP 15 SP4 | python-CairoSVG | 2.7.1-150400.9.9.1 | SUSE-SU-2026:4949-1 |
| SLES 16.0 | python-CairoSVG | 2.7.1-160000.4.1 | SUSE-SU-2026:24596-1 |
| SLE HPC 15 SP5 | python-CairoSVG | 2.7.1-150400.9.9.1 | SUSE-SU-2026:4949-1 |
| SLE HPC 15 SP4 | python-CairoSVG | 2.7.1-150400.9.9.1 | SUSE-SU-2026:4949-1 |
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Tumbleweed | python-CairoSVG | 2.9.1-1.1 | openSUSE-SU-2026:12111-1 |
| openSUSE Leap 16.0 | python-CairoSVG | 2.7.1-160000.4.1 | openSUSE-SU-2026:22182-1 |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| PyPI | cairosvg | < 2.9.1 | 2.9.1 | GHSA-c3jg-qh8m-j3h2 |
Advisories 4
- SUSE-SU-2026:24596-1 Security update for python-CairoSVG SUSE / openSUSE Security Updates · Nov 10, 2026
- SUSE-SU-2026:4949-1 Security update for python-CairoSVG SUSE / openSUSE Security Updates · Nov 2, 2026
- openSUSE-SU-2026:22182-1 Security update for python-CairoSVG SUSE / openSUSE Security Updates · Oct 31, 2026
- openSUSE-SU-2026:12111-1 python313-CairoSVG-2.9.1-1.1 on GA media SUSE / openSUSE Security Updates · Oct 13, 2026