CVE-2021-43113 — itext7-core
CRITICALCVE-2021-43113 is a critical-severity (CVSS 9.8) CWE-77 vulnerability in com.itextpdf:itext7-core. A fix is available for com.itextpdf:itext7-core — see the affected versions and patch details below.
Command injection in itext7-core
Exploitation Status
No confirmed exploitation observed yet
- CISA assesses this as automatable — exploitation doesn’t require manual, per-target effort, which raises the odds of mass scanning and opportunistic attacks.
- A successful exploit gives an attacker total control of the affected component, not partial access.
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for CVE-2021-43113.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
CVE-2021-43113 by exploitation likelihood (EPSS) against impact (CVSS). Outside the shaded patch-first corner.
Where this sits among everything scored
Of 385,738 CVEs with a current EPSS score, this one falls in the < 10% band (highlighted). Counts from FIRST.org, log-scaled.
Real-World Exposure
com.itextpdf:itext7-core☕com.itextpdf:itextpdfReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Maven packages — download data is not available via public APIs for these ecosystems.
Description
iTextPDF in iText 7 and up to (excluding 4.4.13.3) 7.1.17 allows command injection via a CompareTool filename that is mishandled on the gs (aka Ghostscript) command line in GhostscriptHelper.java.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| ☕Maven | com.itextpdf:itext7-core | all versions | 7.1.17com.itextpdf:itext7-core:7.1.17 |
| ☕Maven | com.itextpdf:itextpdf | all versions | 5.5.13.3com.itextpdf:itextpdf:5.5.13.3 |
Affected Products
debian linuxdebianitextitextpdfDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for com.itextpdf:itext7-core, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update com.itextpdf:itext7-core to 7.1.17 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2021-43113 is resolved across your whole dependency graph.
Workarounds
Stop passing untrusted input into the interpreter or shell: call the affected binary with an argument array rather than a composed command string, reject anything outside a strict allowlist of expected values, and run the component under an account that cannot reach beyond the work it legitimately does.
Frequently Asked Questions
Is CVE-2021-43113 in your dependencies?
Find it across Maven, including transitive dependencies.