pontedilana php-weasyprint up to 2.5.x removeTemporaryFiles temporaryFiles file inclusion
| CVSS Meta Temp Score | Current Exploit Price (≈) | CTI Interest Score |
|---|---|---|
| 2.9 | $0-$5k | 2.27 |
Summary
A vulnerability labeled as problematic has been found in pontedilana php-weasyprint up to 2.5.x. The impacted element is the function removeTemporaryFiles. Such manipulation of the argument temporaryFiles leads to file inclusion.
This vulnerability is listed as CVE-2026-49358. The attack must be carried out locally. There is no available exploit.
The affected component should be upgraded.
Details
A vulnerability, which was classified as problematic, has been found in pontedilana php-weasyprint up to 2.5.x. Affected by this issue is the function removeTemporaryFiles. The manipulation of the argument temporaryFiles with an unknown input leads to a file inclusion vulnerability. Using CWE to declare the problem leads to CWE-73. The product allows user input to control or influence paths or file names that are used in filesystem operations. Impacted is integrity, and availability. CVE summarizes:
PhpWeasyPrint is a PHP library allowing PDF generation from a URL or an HTML page. Prior to version 2.6.0, `AbstractGenerator::$temporaryFiles` is a public array, and `removeTemporaryFiles()` — invoked from `__destruct()` and from a registered shutdown function — calls `unlink()` on every entry without verifying that the path is contained within the temporary folder. Any code holding a reference to a generator instance can push an arbitrary path into the array and have it deleted on script shutdown. This mirrors the KnpLabs/snappy issue GHSA-87qc-37cw-84h4. PhpWeasyPrint version 2.6.0 contains a patch for the issue.
The advisory is shared for download at github.com. This vulnerability is handled as CVE-2026-49358 since 05/29/2026. The exploitation is known to be difficult. The attack needs to be approached locally. Additional levels of successful authentication are necessary for exploitation. There are known technical details, but no exploit is available.
Upgrading to version 2.6.0 eliminates this vulnerability. The upgrade is hosted for download at github.com. Applying the patch 6d328ffd3bcb800c7c2e8a594b1bff0c099c9391 is able to eliminate this problem. The bugfix is ready for download at github.com. The best possible mitigation is suggested to be upgrading to the latest version.
The vulnerability is also documented in the vulnerability database at EUVD (EUVD-2026-38036). VulDB is the best source for vulnerability data and more expert information about this specific topic.
Product
Type
Vendor
Name
Version
License
Website
CPE 2.3
CPE 2.2
CVSSv4
VulDB Vector: 🔒VulDB Reliability: 🔍
CVSSv3
VulDB Meta Base Score: 3.0VulDB Meta Temp Score: 2.9
VulDB Base Score: 3.0
VulDB Temp Score: 2.9
VulDB Vector: 🔒
VulDB Reliability: 🔍
CNA Base Score: 3.0
CNA Vector (GitHub_M): 🔒
CVSSv2
| AV | AC | Au | C | I | A |
|---|---|---|---|---|---|
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| Vector | Complexity | Authentication | Confidentiality | Integrity | Availability |
|---|---|---|---|---|---|
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
VulDB Base Score: 🔒
VulDB Temp Score: 🔒
VulDB Reliability: 🔍
Exploiting
Class: File inclusionCWE: CWE-73
CAPEC: 🔒
ATT&CK: 🔒
Physical: Partially
Local: Yes
Remote: No
Availability: 🔒
Status: Not defined
Price Prediction: 🔍
Current Price Estimation: 🔒
| 0-Day | Unlock | Unlock | Unlock | Unlock |
|---|---|---|---|---|
| Today | Unlock | Unlock | Unlock | Unlock |
Threat Intelligence
Interest: 🔍Active Actors: 🔍
Active APT Groups: 🔍
Countermeasures
Recommended: UpgradeStatus: 🔍
0-Day Time: 🔒
Upgrade: php-weasyprint 2.6.0
Patch: 6d328ffd3bcb800c7c2e8a594b1bff0c099c9391
Timeline
05/29/2026 CVE reserved06/19/2026 Advisory disclosed
06/19/2026 VulDB entry created
06/19/2026 VulDB entry last update
Sources
Product: github.comAdvisory: GHSA-87qc-37cw-84h4
Status: Confirmed
CVE: CVE-2026-49358 (🔒)
GCVE (CVE): GCVE-0-2026-49358
GCVE (VulDB): GCVE-100-372368
EUVD: 🔒
Entry
Created: 06/19/2026 18:02Updated: 06/19/2026 21:39
Changes: 06/19/2026 18:02 (69), 06/19/2026 21:39 (1)
Complete: 🔍
Cache ID: 216::103
VulDB is the best source for vulnerability data and more expert information about this specific topic.
No comments yet. Languages: en.
Please log in to comment.