CVEfocus › CVE database › CVE-2026-49452

CVE-2026-49452WeasyPrint: CSS Injection via Presentational Hints

CVSS 6.5 MediumEPSS 0.4% (higher than 23% of CVEs)Published 2026-08-18Updated 2026-08-19Assigner: GitHub_M

WeasyPrint helps web developers to create PDF documents. Prior to 69.0, WeasyPrint embeds unescaped HTML presentational-hint attribute values into CSS in weasyprint/css/__init__.py when presentational_hints=True. The background attribute is inserted into a background-image:url() declaration and parsed by tinycss2.parse_blocks_contents(), allowing untrusted HTML to inject additional CSS declarations. Applications that render untrusted HTML with presentational hints enabled can be affected by CSS injection and server-side requests through injected url() values. This issue is fixed in version 69.0.

CWE-74

What to do

Fixed builds are available from Debian: see the table below for the fixed version per release.

Debian, PyPI, Ubuntu have not shipped a fix for every release yet.

Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.

curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \
  -H "Content-Type: text/plain" --data-binary @inventory.txt

Vendor status at a glance

1Fixed
5Fix pending
3Under investigation
1Will not fix

Status by vendor and release

From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.

ReleasePackageStatusFixed versionAdvisory
Ubuntu 26.10weasyprintFix pendingUBUNTU-CVE-2026-49452
Ubuntu 26.04weasyprintUnder investigationUBUNTU-CVE-2026-49452
Ubuntu 25.10weasyprintWill not fix
Ubuntu decided not to fix this in this release
UBUNTU-CVE-2026-49452
Ubuntu 24.04weasyprintUnder investigationUBUNTU-CVE-2026-49452
Ubuntu 22.04weasyprintUnder investigationUBUNTU-CVE-2026-49452
Ubuntu 20.04weasyprintFix pendingUBUNTU-CVE-2026-49452
Debian 14weasyprintFixed69.0-1DEBIAN-CVE-2026-49452
Debian 13weasyprintFix pendingDEBIAN-CVE-2026-49452
Debian 12weasyprintFix pendingDEBIAN-CVE-2026-49452
PyPI libraryweasyprintFix pendingPYSEC-2026-3412

What the vendor says

As published in the CVE record by GitHub_M, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.

References

About this page

Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.