Critical Buffer Overflow Vulnerability in Expat Package

expat Updated 02 Oct 2025

Summary

26/05/2016
N/A
Yes i
Critical
9.8

ALPINE-CVE-2016-0718: Expat allows context-dependent attackers to cause a denial of service (crash) or possibly execute arbitrary code via a malformed input document, which triggers a buffer overflow. Affects expat versions < 2.1.1-r1. Fixed in 2.1.1-r1. 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 Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

Background

Expat is an XML parsing library widely used in various applications for processing XML data. It is known for its efficiency and ease of use, making it a popular choice among developers. However, the library has a critical vulnerability that can be exploited through malformed input documents, leading to severe consequences.

Vulnerability Detail

The vulnerability, identified as CVE-2016-0718, allows context-dependent attackers to cause a denial of service (crash) or potentially execute arbitrary code through a buffer overflow triggered by malformed input documents. This vulnerability poses a significant risk as it can compromise the integrity and availability of applications utilizing the Expat library.

How To Fix

Minimum fixed version

2.1.1-r1

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

If immediate updating is not feasible, consider implementing input validation to sanitize XML documents before processing them with Expat. This can help mitigate the risk of triggering the buffer overflow.

Conclusion

The Expat package has a critical vulnerability (CVE-2016-0718) that can lead to severe consequences if exploited. It is crucial to update to the patched version 2.1.1-r1 to mitigate risks. Additionally, implementing input validation can serve as a temporary workaround while ensuring the security of applications using this library.

See every vulnerability recorded for expat →

Share this vulnerability

FAQ

CVE-2016-0718 is a vulnerability in the Expat XML parsing library that allows attackers to exploit buffer overflow issues through malformed XML documents.

The vulnerability can lead to denial of service attacks or arbitrary code execution, compromising the security and stability of applications using the Expat library.

You can use the Vulert platform to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected by this vulnerability.

Yes, the patched version of the Expat package is 2.1.1-r1. Updating to this version will resolve the vulnerability.

The CVSS score for CVE-2016-0718 is 9.8, indicating a critical level of severity.

Related vulnerabilities

Recent vulnerabilities recorded for expat.

Sponsored Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

How To Fix

Minimum fixed version

2.1.1-r1

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