PHP Remote File Inclusion Affecting mpdf/mpdf package, versions >=5.5.1


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.03% (9th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-PHP-MPDFMPDF-14927583
  • published14 Jan 2026
  • disclosed13 Jan 2026
  • creditMusyoka Ian

Introduced: 13 Jan 2026

CVE-2022-50897  (opens in a new tab)
CWE-98  (opens in a new tab)

How to fix?

There is no fixed version for mpdf/mpdf.

Overview

mpdf/mpdf is a PHP library generating PDF files from UTF-8 encoded HTML.

Affected versions of this package are vulnerable to PHP Remote File Inclusion via the annotation file parameters. An attacker can access arbitrary system files by supplying crafted annotation content containing file path specifications, using URL-encoded or base64 payloads.

Note:

This vulnerability is disputed by the maintainer, claiming that it can only be exploited by passing an unsanitized external input to mPDF which is the user's responsibility to handle.

CVSS Base Scores

version 4.0
version 3.1