CVE-2022-23308
📋 TL;DR
CVE-2022-23308 is a use-after-free vulnerability in libxml2's validation component that allows attackers to potentially execute arbitrary code or cause denial of service. It affects applications that process untrusted XML documents using libxml2's validation features. This vulnerability impacts any software using vulnerable versions of libxml2 for XML parsing and validation.
💻 Affected Systems
- libxml2
- Any software using libxml2 library
📦 What is this software?
Clustered Data Ontap Antivirus Connector by Netapp
View all CVEs affecting Clustered Data Ontap Antivirus Connector →
Communications Cloud Native Core Binding Support Function by Oracle
View all CVEs affecting Communications Cloud Native Core Binding Support Function →
Communications Cloud Native Core Network Function Cloud Native Environment by Oracle
View all CVEs affecting Communications Cloud Native Core Network Function Cloud Native Environment →
Communications Cloud Native Core Network Repository Function by Oracle
View all CVEs affecting Communications Cloud Native Core Network Repository Function →
Communications Cloud Native Core Network Repository Function by Oracle
View all CVEs affecting Communications Cloud Native Core Network Repository Function →
Communications Cloud Native Core Network Slice Selection Function by Oracle
View all CVEs affecting Communications Cloud Native Core Network Slice Selection Function →
Communications Cloud Native Core Unified Data Repository by Oracle
View all CVEs affecting Communications Cloud Native Core Unified Data Repository →
Fedora by Fedoraproject
Ipados by Apple
Libxml2 by Xmlsoft
Macos by Apple
macOS is Apple's desktop and laptop operating system powering Mac computers used by millions of professionals, developers, creative professionals, and enterprise users worldwide. Built on a Unix foundation with the Darwin kernel and modern Cocoa frameworks, macOS delivers a seamless ecosystem integr...
Learn more about Macos →Macos by Apple
macOS is Apple's desktop and laptop operating system powering Mac computers used by millions of professionals, developers, creative professionals, and enterprise users worldwide. Built on a Unix foundation with the Darwin kernel and modern Cocoa frameworks, macOS delivers a seamless ecosystem integr...
Learn more about Macos →Manageability Software Development Kit by Netapp
View all CVEs affecting Manageability Software Development Kit →
Ontap Select Deploy Administration Utility by Netapp
View all CVEs affecting Ontap Select Deploy Administration Utility →
Snapdrive by Netapp
Solidfire \& Hci Management Node by Netapp
Solidfire\, Enterprise Sds \& Hci Storage Node by Netapp
View all CVEs affecting Solidfire\, Enterprise Sds \& Hci Storage Node →
Tvos by Apple
Watchos by Apple
⚠️ Risk & Real-World Impact
Worst Case
Remote code execution leading to complete system compromise if exploited in a privileged context
Likely Case
Application crash (denial of service) or memory corruption leading to potential information disclosure
If Mitigated
Limited impact if proper input validation and sandboxing are implemented
🎯 Exploit Status
Exploitation requires crafting malicious XML documents with specific ID/IDREF attributes
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: libxml2 2.9.13 and later
Vendor Advisory: https://gitlab.gnome.org/GNOME/libxml2/-/issues/235
Restart Required: Yes
Instructions:
1. Update libxml2 to version 2.9.13 or later. 2. Recompile applications using libxml2. 3. Restart affected services.
🔧 Temporary Workarounds
Disable XML validation
allDisable XML validation features in applications if not required
Application-specific configuration changes
Input filtering
allFilter or reject XML documents containing ID/IDREF attributes
Implement XML schema validation before libxml2 processing
🧯 If You Can't Patch
- Implement strict input validation for XML documents
- Run applications in sandboxed/containerized environments with limited privileges
🔍 How to Verify
Check if Vulnerable:
Check libxml2 version: xml2-config --version or dpkg -l libxml2
Check Version:
xml2-config --version || dpkg -l libxml2 || rpm -q libxml2
Verify Fix Applied:
Verify version is 2.9.13 or higher and test with known malicious XML samples
📡 Detection & Monitoring
Log Indicators:
- Application crashes related to XML parsing
- Memory corruption errors in logs
Network Indicators:
- Unusual XML document patterns with repeated ID/IDREF attributes
SIEM Query:
source="application_logs" AND ("segmentation fault" OR "memory corruption") AND "xml"
🔗 References
- http://seclists.org/fulldisclosure/2022/May/33
- http://seclists.org/fulldisclosure/2022/May/34
- http://seclists.org/fulldisclosure/2022/May/35
- http://seclists.org/fulldisclosure/2022/May/36
- http://seclists.org/fulldisclosure/2022/May/37
- http://seclists.org/fulldisclosure/2022/May/38
- https://github.com/GNOME/libxml2/commit/652dd12a858989b14eed4e84e453059cd3ba340e
- https://gitlab.gnome.org/GNOME/libxml2/-/blob/v2.9.13/NEWS
- https://lists.debian.org/debian-lts-announce/2022/04/msg00004.html
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/LA3MWWAYZADWJ5F6JOUBX65UZAMQB7RF/
- https://security.gentoo.org/glsa/202210-03
- https://security.netapp.com/advisory/ntap-20220331-0008/
- https://support.apple.com/kb/HT213253
- https://support.apple.com/kb/HT213254
- https://support.apple.com/kb/HT213255
- https://support.apple.com/kb/HT213256
- https://support.apple.com/kb/HT213257
- https://support.apple.com/kb/HT213258
- https://www.oracle.com/security-alerts/cpujul2022.html
- http://seclists.org/fulldisclosure/2022/May/33
- http://seclists.org/fulldisclosure/2022/May/34
- http://seclists.org/fulldisclosure/2022/May/35
- http://seclists.org/fulldisclosure/2022/May/36
- http://seclists.org/fulldisclosure/2022/May/37
- http://seclists.org/fulldisclosure/2022/May/38
- https://github.com/GNOME/libxml2/commit/652dd12a858989b14eed4e84e453059cd3ba340e
- https://gitlab.gnome.org/GNOME/libxml2/-/blob/v2.9.13/NEWS
- https://lists.debian.org/debian-lts-announce/2022/04/msg00004.html
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/LA3MWWAYZADWJ5F6JOUBX65UZAMQB7RF/
- https://security.gentoo.org/glsa/202210-03
- https://security.netapp.com/advisory/ntap-20220331-0008/
- https://support.apple.com/kb/HT213253
- https://support.apple.com/kb/HT213254
- https://support.apple.com/kb/HT213255
- https://support.apple.com/kb/HT213256
- https://support.apple.com/kb/HT213257
- https://support.apple.com/kb/HT213258
- https://www.oracle.com/security-alerts/cpujul2022.html