CVE-2022-23990 Overview
CVE-2022-23990 is an integer overflow vulnerability in the doProlog function of Expat (also known as libexpat), a widely-used XML parsing library. This vulnerability affects versions prior to 2.4.4 and can be exploited remotely over the network without requiring authentication or user interaction.
Critical Impact
Remote attackers can exploit this integer overflow vulnerability to cause a denial of service condition by crashing applications that use the vulnerable libexpat library for XML parsing.
Affected Products
- libexpat_project libexpat (versions before 2.4.4)
- Tenable Nessus
- Oracle Communications MetaSolv Solution 6.3.1
- Debian Linux 10.0 and 11.0
- Fedora 34 and 35
- Siemens SINEMA Remote Connect Server
Discovery Timeline
- 2022-01-26 - CVE-2022-23990 published to NVD
- 2025-05-05 - Last updated in NVD database
Technical Details for CVE-2022-23990
Vulnerability Analysis
This vulnerability is classified under CWE-190 (Integer Overflow or Wraparound). The flaw exists within the doProlog function of libexpat, which is responsible for parsing the prolog section of XML documents. When processing specially crafted XML input, the function fails to properly validate integer values before performing arithmetic operations, leading to an integer overflow condition.
The vulnerability is exploitable remotely over the network and requires no privileges or user interaction, making it particularly dangerous for internet-facing applications that process untrusted XML content. The primary impact is on system availability, as successful exploitation leads to application crashes and denial of service conditions.
Root Cause
The root cause of CVE-2022-23990 is insufficient bounds checking in the doProlog function when handling integer values during XML prolog parsing. When processing certain XML constructs, arithmetic operations on input-derived values can wrap around due to the finite size of integer data types, resulting in unexpected behavior. This integer overflow can corrupt internal state, leading to crashes or other undefined behavior in the XML parser.
Attack Vector
The attack vector for this vulnerability is network-based. An attacker can exploit this flaw by sending a maliciously crafted XML document to an application that uses a vulnerable version of libexpat for parsing. The attack does not require authentication or any user interaction—simply processing the malicious XML input triggers the vulnerability.
The exploitation scenario typically involves:
- Identifying an application or service that parses XML using libexpat versions prior to 2.4.4
- Crafting an XML document with specific prolog content designed to trigger the integer overflow in the doProlog function
- Submitting the malicious XML to the target application via any input vector that accepts XML (web services, file uploads, API endpoints, etc.)
- The vulnerable application crashes upon parsing, resulting in denial of service
Detection Methods for CVE-2022-23990
Indicators of Compromise
- Application crashes or unexpected termination during XML parsing operations
- Core dumps or crash logs showing segmentation faults originating from libexpat functions
- Abnormal memory usage patterns in processes handling XML input
- Multiple service restarts for applications that process XML data
Detection Strategies
- Monitor application logs for crashes or exceptions related to XML parsing failures
- Implement version detection for libexpat to identify installations running versions prior to 2.4.4
- Deploy intrusion detection signatures to identify potentially malicious XML payloads targeting integer overflow conditions
- Use static and dynamic analysis tools to identify applications linked against vulnerable libexpat versions
Monitoring Recommendations
- Enable crash dump collection for applications that process XML to capture forensic evidence
- Monitor for unusual patterns of XML document submissions that may indicate exploitation attempts
- Set up alerting for repeated service failures or restarts on XML-processing components
- Track libexpat library versions across your infrastructure using software composition analysis tools
How to Mitigate CVE-2022-23990
Immediate Actions Required
- Upgrade libexpat to version 2.4.4 or later immediately
- Identify all applications and services in your environment that depend on libexpat
- Apply vendor-specific patches from affected downstream products (Tenable, Oracle, Siemens, etc.)
- Restrict access to XML parsing endpoints from untrusted sources where possible
Patch Information
The vulnerability has been addressed in libexpat version 2.4.4. The fix is tracked in GitHub Pull Request #551. Multiple vendors have released advisories and patches for their affected products:
- Siemens Security Advisory SSA-484086
- Debian Security Advisory DSA-5073
- Oracle Critical Patch Update April 2022
- Tenable Security Notification TNS-2022-05
- Gentoo GLSA 202209-24
Workarounds
- Implement input validation to reject excessively large or malformed XML documents before they reach the parser
- Consider using XML parsing wrappers that limit document size and complexity
- Deploy web application firewalls (WAF) with rules to filter suspicious XML content
- Isolate XML processing services in sandboxed environments to limit the impact of crashes
# Check installed libexpat version on Debian/Ubuntu
dpkg -l | grep libexpat
# Update libexpat on Debian/Ubuntu
sudo apt-get update && sudo apt-get install libexpat1
# Check installed libexpat version on RHEL/CentOS/Fedora
rpm -qa | grep expat
# Update libexpat on RHEL/CentOS/Fedora
sudo dnf update expat
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.


