CVE-2021-45394
Cross-site Scripting in HTML2PDF
An issue was discovered in Spipu HTML2PDF before 5.2.4. Attackers can trigger deserialization of arbitrary data via the injection of a malicious <link> tag in the converted HTML document.
Attack profile
How easy it is to exploit
- Attack vector
- Network
- Complexity
- Low
- Privileges needed
- None
- User interaction
- Required
What an attacker can affect
- Confidentiality
- High
- Integrity
- High
- Availability
- High
Exploit likelihood
What each source reports
NVD Score used
8.8
An issue was discovered in Spipu HTML2PDF before 5.2.4. Attackers can trigger deserialization of arbitrary data via the injection of a malicious <link> tag in the converted HTML document.
- Record
CVE-2021-45394- CVSS 3.1
- 8.8 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H - CVSS 2.0
- 6.8 Medium
AV:N/AC:M/Au:N/C:P/I:P/A:P - Weakness
- CWE-502, CWE-918
- Updated
- 2026-11-02
CVE List No score
An issue was discovered in Spipu HTML2PDF before 5.2.4. Attackers can trigger deserialization of arbitrary data via the injection of a malicious <link> tag in the converted HTML document.
- Record
CVE-2021-45394- Updated
- 2026-11-02
EUVDEUVD-2022-0482 No score
An issue was discovered in Spipu HTML2PDF before 5.2.4. Attackers can trigger deserialization of arbitrary data via the injection of a malicious <link> tag in the converted HTML document.
- Record
EUVD-2022-0482- Updated
- 2026-11-03
GitHub AdvisoriesGHSA-6m93-343m-3jrc
8.8
Cross-site Scripting in HTML2PDF
An issue was discovered in Spipu HTML2PDF before 5.2.4. Attackers can trigger deserialization of arbitrary data via the injection of a malicious <link> tag in the converted HTML document.
- Record
GHSA-6m93-343m-3jrc- CVSS 3.1
- 8.8 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H - Weakness
- CWE-79, CWE-918
- Updated
- 2026-11-02
OSV
8.8
An issue was discovered in Spipu HTML2PDF before 5.2.4. Attackers can trigger deserialization of arbitrary data via the injection of a malicious <link> tag in the converted HTML document.
- Record
CVE-2021-45394- CVSS 3.1
- 8.8 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H - Updated
- 2026-11-02
OSVGHSA-6m93-343m-3jrc
8.8
Cross-site Scripting in HTML2PDF
An issue was discovered in Spipu HTML2PDF before 5.2.4. Attackers can trigger deserialization of arbitrary data via the injection of a malicious <link> tag in the converted HTML document.
- Record
GHSA-6m93-343m-3jrc- CVSS 3.1
- 8.8 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H - Weakness
- CWE-79, CWE-918
- Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
spipu/html2pdfPackagist |
before 5.2.4 | 5.2.4 |
spipu/html2pdfPackagist |
before 5.2.4, plus listed versions v4.4.0v4.5.0v4.5.1v4.6.0v4.6.1 Show 7 moreShow lessv5.0.0v5.0.1v5.1.0v5.2.0v5.2.1v5.2.2v5.2.3 |
5.2.4 |
History
| Recorded | Changed | Sources |
|---|---|---|
| aliases | EUVD | |
| first indexed | CVE List, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2021-45394 is a high vulnerability (CVSS 8.8) in Html2pdf Project Html2pdf, published January 18, 2022. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 1.58%, the 75th percentile. Fixed in spipu/html2pdf 5.2.4.
References
github.com/spipu/html2pdf
synacktiv.com/sites/default/files/2022-01/html2pdf_ssrf_deserialization.pdf
github.com/spipu/html2pdf/blob/master/CHANGELOG.md
nvd.nist.gov/vuln/detail/CVE-2021-45394
github.com/spipu/html2pdf/commit/100a4d509abf8550765cf0e0da83e83abb422585
github.com/spipu/html2pdf/commit/2e6bab9a2afe9cfd4d3c3038da64d8ad74e41d7f
github.com/spipu/html2pdf/releases/tag/v5.2.4
github.com/advisories/GHSA-6m93-343m-3jrc