WeasyPrint passes EPS images to Ghostscript, risking code execution
Key facts
- Attack vector
- Network
- Privileges required
- Low
- User interaction
- None
- Attack complexity
- Low
- Impact type
- —
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub.
Summary
WeasyPrint before 70.0 passes image bytes to Pillow without excluding EPS or PostScript formats, an improper input validation flaw (CWE-20). On hosts with Ghostscript installed, Pillow hands attacker-controlled PostScript to the interpreter. An attacker with low privileges who supplies image content can cause interpreter-permitted effects and possibly code execution, depending on the Ghostscript version. Hosts without Ghostscript do not reach this path.
Written with Claude Haiku 5.5 from the sources below · 2026-10-29
Description from the CNA
WeasyPrint helps web developers to create PDF documents. Prior to 70.0, the image-loading path in weasyprint/images.py passes fetched image bytes from HTML img URLs, CSS image values, SVG image references, and data URIs to Pillow's generic image dispatcher without excluding EPS or PostScript formats. On hosts with Ghostscript installed, Pillow EpsImagePlugin invokes the interpreter for attacker-controlled PostScript, which can produce interpreter-permitted effects and can lead to remote code execution when the installed Ghostscript version has a usable sandbox bypass. Hosts without Ghostscript do not reach this rasterization path. This issue is fixed in version 70.0.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Total
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| Kozea | WeasyPrint | before 70.0 | 70.0 | Patch available | CNA |
| — | WeasyPrint (PyPI) | before 70.0 | 70.0 | Patch available | GHSA-r543-q48m-4c9j |
- WeasyPrint VendorKozea Affected before 70.0 Fixed in 70.0 Patch available CNA
- WeasyPrint (PyPI) Vendor— Affected before 70.0 Fixed in 70.0 Patch available GHSA-r543-q48m-4c9j
Remediation
Upgrade the PyPI package WeasyPrint to version 70.0, which fixes this issue.
Written with Claude Haiku 5.5 from the sources below · 2026-10-29
- Fix · CNA WeasyPrint (Kozea) Fixed in 70.0
- Fix · GHSA-r543-q48m-4c9j WeasyPrint (PyPI) Fixed in 70.0 Advisory →
Vendor assessments
Red Hat
Red Hat rating: Important. Red Hat's page for this CVE →
Not affected: 1 product
- Red Hat Ansible Automation Platform 2
Timeline
- 2026-10-06 Threatist record created from CVE-2026-106443
- 2026-10-07 Affected versions changed · Red Hat
- 2026-10-07 CVSS score added · Red Hat
- 2026-10-07 Alias added: GHSA-r543-q48m-4c9j
- 2026-10-07 Fix available: PyPI/[email protected] · GHSA-r543-q48m-4c9j
- 2026-10-07 CVSS score added · GHSA-r543-q48m-4c9j
- 2026-10-07 Weakness changed · GHSA-r543-q48m-4c9j
- 2026-10-07 5 new references · GHSA-r543-q48m-4c9j
- 2026-10-07 Priority changed: LOW → MEDIUM
- 2026-10-13 Affected versions changed · Red Hat
References
More Kozea vulnerabilities
- TI-2026-69644 Inefficient path parsing in CairoSVG enables denial of service CVSS 4.0HIGH 8.7
- TI-2026-24451 CairoSVG vulnerable to Exponential DoS via recursive <use> element amplification CVSS 3.1HIGH 7.5
- TI-2025-42134 WeasyPrint Vulnerable to Server-Side Request Forgery (SSRF) Protection Bypass via HTTP Redirect CVSS 3.1HIGH 7.5
- TI-2026-36607 WeasyPrint: CSS Injection via Presentational Hints CVSS 3.1MEDIUM 6.5
- TI-2026-39778 WeasyPrint restrictive URL fetcher bypass allows local file read and SSRF CVSS 3.1MEDIUM 6.2
- TI-2023-12296 CairoSVG improperly processes SVG files loaded from external resources CVSS 3.1CRITICAL 9.9
Sources
- CVE-2026-106443 · CVE Program
- CVE-2026-106443 · NVD
- FIRST EPSS
- GHSA-r543-q48m-4c9j · GitHub Advisory Database · CC BY 4.0
- CVE-2026-106443 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences