Critical Denial of Service Vulnerability in Expat Package

expat Updated 02 Oct 2025

Summary

30/06/2016
N/A
Yes i
High
8.1

ALPINE-CVE-2016-4472: The overflow protection in Expat is removed by compilers with certain optimization settings, which allows remote attackers to cause a denial of service (crash) or possibly execute arbitrary code via crafted XML data. Affects expat versions < 2.1.1-r2. Fixed in 2.1.1-r2. 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 MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

Expat is an XML parsing library widely used in various software applications for its efficiency and flexibility in handling XML data. It provides a fast and easy way to parse XML documents, making it a popular choice among developers. However, due to certain compiler optimization settings, Expat has been found to be vulnerable to a critical security issue that can lead to severe consequences.

Vulnerability Detail

The vulnerability arises from the removal of overflow protection in Expat when compiled with specific optimization settings. This flaw allows remote attackers to exploit the library by sending crafted XML data, potentially leading to a denial of service (crash) or even arbitrary code execution. This issue is particularly concerning as it stems from an incomplete fix for previously identified vulnerabilities, CVE-2015-1283 and CVE-2015-2716, highlighting the importance of thorough testing and validation in software security.

How To Fix

Minimum fixed version

2.1.1-r2

This is the first release that contains the fix.

sudo apk add --upgrade expat

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

Workaround

As a temporary workaround, consider disabling specific compiler optimizations that may lead to the vulnerability. However, this is not a permanent solution, and updating to the patched version is strongly recommended.

Conclusion

In summary, the Expat package is vulnerable to a critical denial of service issue due to improper handling of overflow protection under certain compiler settings. It is crucial to update to the patched version 2.1.1-r2 to mitigate this risk. Utilizing tools like Vulert can help in monitoring and managing vulnerabilities effectively.

See every vulnerability recorded for expat →

Share this vulnerability

FAQ

The CVSS score of this vulnerability is 8.1, indicating a high severity level.

Yes, attackers can exploit this vulnerability remotely by sending specially crafted XML data to the affected application.

The potential consequences include denial of service (application crash) and the possibility of arbitrary code execution, which can compromise the entire system.

You can use Vulert's playground at Vulert Scanner to check if your application is affected by this vulnerability without any signup.

Yes, Vulert can monitor and alert you in real-time for open-source vulnerabilities using just a manifest file like package-lock.json.

Related vulnerabilities

Recent vulnerabilities recorded for expat.

How To Fix

Minimum fixed version

2.1.1-r2

This is the first release that contains the fix.

sudo apk add --upgrade expat

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