wp-mpdf Security & Risk Analysis

wordpress.org/plugins/wp-mpdf

Print Wordpress posts as PDF. Optional with Geshi highlighting.

1K active installs v3.9.2 PHP + WP 4.0+ Updated Sep 21, 2025
mpdfpdfprintprinterwp-mpdf
97
A · Safe
CVEs total3
Unpatched0
Last CVESep 26, 2025
Safety Verdict

Is wp-mpdf Safe to Use in 2026?

Generally Safe

Score 97/100

wp-mpdf has a strong security track record. Known vulnerabilities have been patched promptly.

3 known CVEsLast CVE: Sep 26, 2025Updated 6mo ago
Risk Assessment

The wp-mpdf plugin v3.9.2 exhibits a mixed security posture. On the positive side, it has no critical or high severity taint flows and no currently unpatched CVEs. The majority of SQL queries are prepared, and there's a reasonable number of capability checks and nonce checks in place. However, several concerns warrant attention. A significant portion of output is not properly escaped, which poses a risk of Cross-Site Scripting (XSS) vulnerabilities. Furthermore, the taint analysis reveals a notable number of flows with unsanitized paths and four high-severity taint flows, indicating potential vulnerabilities where user-supplied data is not sufficiently validated before being used in sensitive operations. The vulnerability history shows a pattern of medium severity XSS and CSRF vulnerabilities, and the presence of unsanitized paths in the taint analysis directly correlates with the historical XSS issues. While the lack of unpatched CVEs is good, the ongoing taint flow issues suggest potential for new vulnerabilities to emerge if not addressed. The bundling of TCPDF is also a potential concern if it's an outdated version, as bundled libraries can introduce vulnerabilities if not maintained.

In conclusion, while the plugin demonstrates some good security practices like prepared statements and authorization checks, the prevalence of unsanitized paths in taint flows and the high percentage of unescaped output are significant weaknesses. The historical medium-severity vulnerabilities, particularly XSS, coupled with these code analysis findings, suggest that users are at risk of encountering vulnerabilities if this plugin is not actively maintained and audited for proper input sanitization and output escaping. The existence of 4 high severity taint flows is a key area for immediate investigation and remediation.

Key Concerns

  • High severity taint flows detected
  • Unsanitized paths in taint flows
  • Unescaped output detected (34% of outputs)
  • Bundled library (TCPDF)
Vulnerabilities
3

wp-mpdf Security Vulnerabilities

CVEs by Year

1 CVE in 2021
2021
1 CVE in 2024
2024
1 CVE in 2025
2025
Patched Has unpatched

Severity Breakdown

Medium
3

3 total CVEs

CVE-2025-60040medium · 6.4Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

wp-mpdf <= 3.9.1 - Authenticated (Contributor+) Stored Cross-Site Scripting

Sep 26, 2025 Patched in 3.9.2 (4d)
CVE-2024-27962medium · 6.1Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

wp-mpdf <= 3.7.1 - Reflected Cross-Site Scripting

Mar 13, 2024 Patched in 3.8 (8d)
CVE-2021-4416medium · 4.3Cross-Site Request Forgery (CSRF)

wp-mpdf <= 3.5.1 - Cross-Site Request Forgery Bypass

Jun 21, 2021 Patched in 3.5.2 (946d)
Code Analysis
Analyzed Mar 16, 2026

wp-mpdf Code Analysis

Dangerous Functions
0
Raw SQL Queries
8
49 prepared
Unescaped Output
31
60 escaped
Nonce Checks
3
Capability Checks
4
File Operations
15
External Requests
0
Bundled Libraries
1

Bundled Libraries

TCPDF

SQL Query Safety

86% prepared57 total queries

Output Escaping

66% escaped91 total outputs
Data Flows
5 unsanitized

Data Flow Analysis

9 flows5 with unsanitized paths
mpdf_admin_cache (wp-mpdf_admin.php:633)
Source (user input) Sink (dangerous op) Sanitizer Transform Unsanitized Sanitized
Attack Surface

wp-mpdf Attack Surface

Entry Points1
Unprotected0

Shortcodes 1

[mpdfbutton] wp-mpdf.php:361
WordPress Hooks 9
actiondbx_post_advancedwp-mpdf.php:548
actiondbx_page_advancedwp-mpdf.php:549
actionmpdf_generate_pdfs_hookwp-mpdf.php:691
actiondelete_postwp-mpdf.php:692
actiontemplate_redirectwp-mpdf.php:694
actionadmin_menuwp-mpdf.php:695
filterthe_contentwp-mpdf.php:696
actionsave_postwp-mpdf.php:698
actioninitwp-mpdf.php:700

Scheduled Events 1

mpdf_generate_pdfs_hook
Maintenance & Trust

wp-mpdf Maintenance & Trust

Maintenance Signals

WordPress version tested6.8.5
Last updatedSep 21, 2025
PHP min version
Downloads51K

Community Trust

Rating96/100
Number of ratings18
Active installs1K
Developer Profile

wp-mpdf Developer Profile

fkrauthan

1 plugin · 1K total installs

77
trust score
Avg Security Score
97/100
Avg Patch Time
319 days
View full developer profile
Detection Fingerprints

How We Detect wp-mpdf

Patterns used to identify this plugin on WordPress sites during automated security audits and web crawling.

Asset Fingerprints

Asset Paths
/wp-content/plugins/wp-mpdf/mpdf/css/mpdf.css/wp-content/plugins/wp-mpdf/mpdf/js/mpdf.js
Script Paths
/wp-content/plugins/wp-mpdf/mpdf/js/mpdf.js
Version Parameters
wp-mpdf/mpdf/css/mpdf.css?ver=wp-mpdf/mpdf/js/mpdf.js?ver=

HTML / DOM Fingerprints

HTML Comments
<!-- mpdf -->
JS Globals
window.mpdf_globalvar mpdf_global
Shortcode Output
[mpdf][mpdf title=[mpdf filename=[mpdf toc=
FAQ

Frequently Asked Questions about wp-mpdf