Server-Side Request Forgery in PhpWeasyPrint PHP Library
CVE-2026-49359
6.5MEDIUM
What is CVE-2026-49359?
The PhpWeasyPrint library, used for generating PDFs from URLs or HTML content, contains a vulnerability that allows an attacker to exploit the attachment option by injecting malicious URLs. This vulnerability enables a Server-Side Request Forgery attack, which can lead to access to internal HTTP endpoints, exfiltration of sensitive data, and local file disclosures through unsafe URL schemes. The issue arises from the use of file_get_contents() without proper URL scheme restrictions prior to version 2.6.0. Users are strongly advised to upgrade to the patched version to mitigate these risks.
Affected Version(s)
php-weasyprint < 2.6.0
