CVE-2017-5992
High · 8.2CVSS
8.2
EPSS
1.2%
Published
Feb 15, 2017
CISA due date
—
Cloudanix analysis
A tool that reads spreadsheet files can accidentally leak private information when it opens a specially made file sent by an attacker.
- Exploitation
- Requires User Interaction
- Attacker needs
- User Interaction
- Complexity
- Low
- Impact
- Data Exposure
- Component
- Library
- Class
- XXE
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
The library parses .xlsx files (which are ZIP archives containing XML) with XML external entity resolution enabled by default, allowing crafted documents to read arbitrary local files or initiate outbound network requests during deserialization.
Why it matters to the business
Organizations that accept or process spreadsheet files from external parties risk unintended exposure of internal data or unintended network activity originating from the parsing system.
How an attack unfolds
An attacker creates a malicious .xlsx containing XML with external entity declarations that reference local files or internal services, then delivers the file to a target application or user that uses the vulnerable library to read it, causing the parser to resolve and potentially exfiltrate the referenced content.
How to fix it
Upgrade to a version containing commit 3b4905f428e1 or later; if upgrade is not possible, configure the parser to disable external entity resolution before loading any untrusted .xlsx content.
How to confirm the fix worked
Confirm the installed version is at or above the fixed commit; test by attempting to parse a minimal XXE-crafted .xlsx and verifying that external entity expansion is rejected or produces no sensitive output.
Typical attack path
- Attacker crafts .xlsx with XXE payload in sharedStrings.xml or other XML parts
- Malicious file is uploaded or opened by an application using the vulnerable library
- Library parses the XML with entity resolution enabled
- External entities are fetched, resulting in local file read or SSRF
- Attacker receives exfiltrated data via out-of-band channel or error responses
How to detect it
Inspect application logs for XML parser warnings, unexpected file reads, or outbound connections triggered during .xlsx processing; review any error messages containing references to file:// or internal resource paths.
What your security team should do
- Prioritize upgrade of openpyxl to the fixed version in all environments that parse user-supplied spreadsheets
- Add input validation or sandboxing around spreadsheet parsing code until patched
- Review logs for any unexpected file-access or network requests during .xlsx processing
The record
Openpyxl 2.4.1 resolves external entities by default, which allows remote attackers to conduct XXE attacks via a crafted .xlsx document.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| PyPI | openpyxl | 0 | 2.4.1 |
| PyPI | openpyxl | 0 | 2.4.2 |
| Debian:11 | openpyxl | 0 | 2.3.0-3 |
| Debian:12 | openpyxl | 0 | 2.3.0-3 |
| Debian:13 | openpyxl | 0 | 2.3.0-3 |
| Ubuntu:18.04:LTS | openpyxl | 0 | 2.4.9-1 |
| Ubuntu:20.04:LTS | openpyxl | 0 | 2.4.9-1 |
| Ubuntu:Pro:16.04:LTS | openpyxl | 0 | 2.3.0-1ubuntu0.1~esm1 |
| openSUSE:Tumbleweed | python-openpyxl | 0 | 3.1.3-1.1 |
| pypi | openpyxl | 2.4.1 | No fix |
Related vulnerabilities
- CVE-2026-89260 MoguBlog through 6.2 contains an XML external entity injection vulnerability in the… CWE-611
- CVE-2026-84941 An information disclosure vulnerability in the SAML Single Sign-On (SSO) functionality of… CWE-611
- CVE-2026-79572 An XXE (XML External Entity) vulnerability in the level-rule module of Distribution… CWE-611
- CVE-2026-19614 The API is prone to XML external entity (XXE) injection. CWE-611
- CVE-2026-71375 Improper restriction of XML external entity reference vulnerability in Cosminexus… CWE-611
- CVE-2026-76958 SAP Integration Suite does not sufficiently validate XML documents accepted from… CWE-611
- CVE-2026-17444 IBM App Connect Enterprise 13.0.1.0 through 13.0.8.1, and 12.0.1.0 through 12.0.12.28 and… CWE-611
- CVE-2026-17443 IBM App Connect Enterprise 13.0.1.0 through 13.0.8.1, and 12.0.1.0 through 12.0.12.28 and… CWE-611