Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSubmit attacker-controlled HTML to writeHTML()
-
DeliveryReference local file via CSS url() or img| bullet with uppercase path
-
ExploitBypass cssSafeMarkupPath() allowlist check
-
ExecutionFile copied to temp dir and embedded in PDF
-
ImpactRetrieve generated PDF to disclose file contents
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK
2 techniques across 2 tactics: Discovery, Collection The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires that the host application render attacker-controlled HTML through TCPDF's writeHTML()/writeHTMLCell(), and that the attacker can retrieve the resulting PDF to recover the embedded file. The concrete trigger, per the vendor changelog, is a CSS url() value or a legacy list-style-type:img| (list-image) bullet path whose path contains uppercase characters, which evades the cssSafeMarkupPath() allowlist so the referenced file is copied to a predictable name in the system temp directory and embedded. Limiting factors: the attacker must control HTML input to the markup engine (not a default-exposed function in every deployment), impact is confined to confidentiality/local file disclosure of files readable by the PHP process (no write, code execution, or availability impact), and only files outside K_ALLOWED_PATHS are the target of the bypass. The complete fix is upgrading to 7.0.20 (which removes the temp-dir copy and resolves paths directly and requires tecnickcom/tc-lib-pdf ^8.82.1); the vendor additionally advises keeping K_ALLOWED_PATHS as narrow as possible and not listing the system temp directory when rendering untrusted markup. |
| Impact | Signals align on a moderate, not critical, priority. The supplied CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N) with only VC:L and VI/VA:N yields a 6.9 (medium) score driven entirely by a low-confidentiality impact - local file disclosure - with no integrity or availability effect and no scope change to other systems. The vuln.today decision label is 'this_month', consistent with a bug that warrants scheduled remediation rather than emergency action. There is no CISA KEV listing and no EPSS score in the provided data, so there is no evidence of active or probable near-term exploitation; the only references are the vendor patch/release and a VulnCheck advisory, none of which is working exploit code, so no public exploit is identified. The one caveat is that AV:N/PR:N describes the library's trigger surface (attacker-controlled HTML), but real exploitability depends on the host application actually passing untrusted HTML to writeHTML() - a deployment condition the CVSS vector cannot capture. Net: a genuine issue to patch this month for anyone rendering untrusted HTML with TCPDF, but not a high-urgency, widely-weaponized threat on the available signals. |
| Exploit ScenarioDerived | A web application uses TCPDF's writeHTML() to turn user-supplied HTML into a PDF (e.g., invoice or report generation). An attacker submits HTML whose CSS url() value or legacy list-image bullet references a sensitive local file outside K_ALLOWED_PATHS using uppercase characters in the path to bypass the cssSafeMarkupPath() allowlist check. TCPDF copies that file into the temporary directory and embeds it into the generated PDF, which the attacker then retrieves to read the file's contents. No public exploit code is identified; the attack follows directly from the vendor's description and patch, and AV:N/AC:L means the crafted markup can be delivered remotely with low complexity. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Dec 02, 2026
Local file disclosure in TCPDF 7.0.0 through 7.0.19 lets an attacker who controls HTML rendered by writeHTML() or writeHTMLCell() pull files from outside the K_ALLOWED_PATHS allowlist into the generated PDF: a CSS url() value or a legacy list-style-type:img| bullet path containing uppercase characters slips past cssSafeMarkupPath(), so the referenced file is copied to a predictable name in the system temp directory and embedded in the output. Impact is confined to confidentiality of files readable by the PHP process - no write, code execution, or availability effect - and exploitation requires the host application to render untrusted markup and to let the attacker recover the resulting PDF. No public exploit code has been identified at time of analysis; the vendor closed the gap in 7.0.20 by deleting the temp-directory copy and resolving these paths directly through the engine file helper.
RemediationAI
Upgrade to TCPDF 7.0.20, which is the vendor-released patch (upstream commit c8834161b905b21bd8dcc0df6284e0132c5efa05, release https://github.com/tecnickcom/TCPDF/releases/tag/7.0.20), and make sure the dependency resolves to tecnickcom/tc-lib-pdf ^8.82.1, since the engine-level allowlist changes ship there. As a compensating measure the vendor advises keeping K_ALLOWED_PATHS as narrow as the deployment allows and, when rendering untrusted markup, not listing the system temp directory in it - the trade-off is that HTML/CSS/SVG resources that genuinely live in the temp directory will no longer load after 7.0.20, while Image(), ImageSVG() and the other direct API methods retain access to it by design. Also lower K_MAX_REMOTE_SIZE to the expected asset size to limit remote fetch behavior. If upgrading must be staged, treat 7.0.0-7.0.19 deployments that render user-supplied HTML as exposed and reduce what the PHP process can read until the upgrade completes.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
TCPDF is a long-standing PHP library for generating PDFs; its writeHTML()/writeHTMLCell() path renders caller-supplied markup, and resources referenced from HTML, CSS, and SVG are normally gated by a realpath()-based allowlist of trusted roots (K_ALLOWED_PATHS) enforced in cssSafeMarkupPath(). This is a CWE-22 path traversal/allowlist bypass: markup-supplied paths that contained uppercase characters were not subjected to the allowlist check, and the legacy handling instead copied the referenced file to a predictable file name inside the system temp directory - a directory that is allowlisted by default - from which the engine then embedded it. Because the copy landed in an allowlisted location under a guessable name, the check downstream of the copy no longer constrained which file could reach the PDF. The fix removes that copy step (the engine resolves the paths directly), stops HTML/CSS/SVG markup from reading resources out of the system temp directory entirely, converts legacy list-style-type:img| bullets into list-style-image:url(path) with the width/height fields ignored, and also routes Image() mask handles and other API reads through the same allowlist. The release additionally bumps the dependency to tecnickcom/tc-lib-pdf ^8.82.1, which applies the path allowlist to PDF import and a host allowlist to signature timestamp requests.
Know when Tcpdf gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N
Attacker-controlled HTML can be delivered remotely with low complexity and no auth or interaction at the library boundary (AV:N/AC:L/PR:N/UI:N); impact is limited local file disclosure, so C:L with I:N/A:N.
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
TCPDF 7.0.0 before 7.0.20 contains an allowlist bypass vulnerability in cssSafeMarkupPath() that allows attackers to embed local files outside K_ALLOWED_PATHS via CSS url() values. Attackers controlling HTML rendered by writeHTML() can reference list-style-image or img| bullet paths containing uppercase characters, causing files to be copied to the temporary directory and embedded in generated PDFs.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.
An issue was discovered in TCPDF before 6.2.22. Rated critical severity (CVSS 9.8), this vulnerability is remotely explo
An issue was discovered in TCPDF before 6.8.0. Rated high severity (CVSS 7.5), this vulnerability is remotely exploitabl
TCPDF version 6.6.5 and before is vulnerable to ReDoS (Regular Expression Denial of Service) if parsing an untrusted SVG
TCPDF version <=6.6.5 is vulnerable to ReDoS (Regular Expression Denial of Service) if parsing an untrusted HTML page wi
An issue was discovered in TCPDF before 6.8.0. Rated critical severity (CVSS 9.8), this vulnerability is remotely exploi
tcpdf before 6.2.0 uploads files from the server generating PDF-files to an external FTP. Rated high severity (CVSS 7.5)
An issue was discovered in TCPDF before 6.8.0. Rated high severity (CVSS 7.5), this vulnerability is remotely exploitabl
An issue was discovered in TCPDF before 6.8.0. Rated high severity (CVSS 7.5), this vulnerability is remotely exploitabl
Local File Inclusion (LFI) vulnerability has been discovered in TCPDF 6.7.5. Rated medium severity (CVSS 6.2), this vuln
TCPDF before 6.7.4 mishandles calls that use HTML syntax. Rated medium severity (CVSS 6.1), this vulnerability is remote
EUVD-2026-141620
GHSA-9cw8-wcwq-x458
NVD
CVE.org
EPSS
Exploit-DB