Critical Vulnerabilities in libxml2: Denial of Service and Arbitrary Code Execution Risks

libxml2 Updated 03 Oct 2025

Summary

16/05/2022
N/A
Yes i
Unrated
Not published

USN-5422-1: libxml2 vulnerabilities. Affects libxml2 versions < 2.9.1+dfsg1-3ubuntu4.13+esm3. Fixed in 2.9.1+dfsg1-3ubuntu4.13+esm3. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

libxml2 is a widely used XML parsing library that provides developers with the ability to read, manipulate, and write XML documents. It is known for its performance and compliance with XML standards, making it a critical component in many applications. However, recent vulnerabilities have been discovered that could allow attackers to exploit the library, leading to severe security risks.

Vulnerability Detail

Two significant vulnerabilities have been identified in libxml2. The first, CVE-2022-23308, allows an attacker to craft specific XML files that could cause a crash, resulting in a denial of service. The second, CVE-2022-29824, presents a similar risk, where improper handling of XML files could lead to arbitrary code execution. Both vulnerabilities primarily affect Ubuntu 14.04 ESM and Ubuntu 16.04 ESM, posing a serious threat to systems using these versions.

How To Fix

Minimum fixed version

2.9.1+dfsg1-3ubuntu4.13+esm3

This is the first release that contains the fix.

sudo apt-get install --only-upgrade libxml2

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If immediate patching is not feasible, consider restricting access to the affected systems or disabling the use of libxml2 in applications until the vulnerabilities can be addressed. Additionally, ensure that any XML files processed by the library are from trusted sources.

Conclusion

The vulnerabilities in libxml2 pose significant risks to systems running affected versions of Ubuntu. It is crucial to apply the necessary updates to mitigate these risks and ensure the security of applications relying on this library. Regular monitoring and using tools like Vulert can help maintain awareness of potential vulnerabilities.

See every vulnerability recorded for libxml2 →

Share this vulnerability

FAQ

The main vulnerabilities are CVE-2022-23308 and CVE-2022-29824, which can lead to denial of service and arbitrary code execution.

The vulnerabilities primarily affect Ubuntu 14.04 ESM and Ubuntu 16.04 ESM.

You can use Vulert, which monitors and alerts for open-source vulnerabilities in your software. Visit Vulert Scanner to check your application's manifest file for vulnerabilities.

If immediate updates are not possible, restrict access to the affected systems and disable the use of libxml2 in applications until the vulnerabilities are patched.

Vulert is a tool that monitors open-source vulnerabilities in your software using just a manifest file. It provides real-time alerts and insights without requiring code access or installation.

Related vulnerabilities

Recent vulnerabilities recorded for libxml2.

How To Fix

Minimum fixed version

2.9.1+dfsg1-3ubuntu4.13+esm3

This is the first release that contains the fix.

sudo apt-get install --only-upgrade libxml2

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback