CVE-2025-31115
XZ has a heap-use-after-free bug in threaded .xz decoder
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.
Attack profile
How easy it is to exploit
- Attack vector
- Network
- Complexity
- Low
- Privileges needed
- None
- User interaction
- None
What an attacker can affect
- Confidentiality
- None
- Integrity
- None
- Availability
- High
Exploit likelihood
What each source reports
CVE List Score used
8.7
XZ has a heap-use-after-free bug in threaded .xz decoder
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.
- Record
CVE-2025-31115- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N - Weakness
- CWE-366, CWE-416, CWE-476, CWE-826
- Updated
- 2026-11-02
EUVDEUVD-2025-14786
8.7
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.
- Record
EUVD-2025-14786- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N - Updated
- 2026-11-02
NVD
8.7
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.
- Record
CVE-2025-31115- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X - Weakness
- CWE-366, CWE-416, CWE-476, CWE-826
- Updated
- 2026-11-02
OSVALPINE-CVE-2025-31115
8.7
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.
- Record
ALPINE-CVE-2025-31115- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X - Updated
- 2026-11-02
OSV
8.7
XZ has a heap-use-after-free bug in threaded .xz decoder
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.
- Record
CVE-2025-31115- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N - Weakness
- CWE-366, CWE-416, CWE-476, CWE-826
- Updated
- 2026-11-02
OSVDEBIAN-CVE-2025-31115
8.7
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.
- Record
DEBIAN-CVE-2025-31115- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X - Updated
- 2026-11-02
Show 14 moreShow less
OSVOESA-2025-1430
8.2
xz security update
XZ Utils is free general-purpose data compression software with a high compression ratio. XZ Utils were written for POSIX-like systems, but also work on some not-so-POSIX systems. XZ Utils are the successor to LZMA Utils.
Security Fix(es):
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.(CVE-2025-31115)
- Record
OESA-2025-1430- CVSS 3.1
- 8.2 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H - Updated
- 2026-11-02
OSVOESA-2025-1431
8.2
xz security update
XZ Utils is free general-purpose data compression software with a high compression ratio. XZ Utils were written for POSIX-like systems, but also work on some not-so-POSIX systems. XZ Utils are the successor to LZMA Utils.
Security Fix(es):
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.(CVE-2025-31115)
- Record
OESA-2025-1431- CVSS 3.1
- 8.2 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:H - Updated
- 2026-11-02
OSVRHSA-2025:7524
7.5
Red Hat Security Advisory: xz security update
- Record
RHSA-2025:7524- CVSS 3.1
- 7.5 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H - Updated
- 2026-11-02
OSVRLSA-2025:7524
7.5
Important: xz security update
XZ Utils is an integrated collection of user-space file compression utilities based on the Lempel-Ziv-Markov chain algorithm (LZMA), which performs lossless data compression. The algorithm provides a high compression ratio while keeping the decompression time short.
Security Fix(es):
- xz: XZ has a heap-use-after-free bug in threaded .xz decoder (CVE-2025-31115)
For more details about the security issue(s), including the impact, a CVSS score, acknowledgments, and other related information, refer to the CVE page(s) listed in the References section.
- Record
RLSA-2025:7524- CVSS 3.1
- 7.5 High
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H - Updated
- 2026-11-02
OSVUBUNTU-CVE-2025-31115
8.7
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.
- Record
UBUNTU-CVE-2025-31115- CVSS 4.0
- 8.7 High
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N - Updated
- 2026-11-02
OSVALSA-2025:7524 No score
Important: xz security update
XZ Utils is an integrated collection of user-space file compression utilities based on the Lempel-Ziv-Markov chain algorithm (LZMA), which performs lossless data compression. The algorithm provides a high compression ratio while keeping the decompression time short.
Security Fix(es):
- xz: XZ has a heap-use-after-free bug in threaded .xz decoder (CVE-2025-31115)
For more details about the security issue(s), including the impact, a CVSS score, acknowledgments, and other related information, refer to the CVE page(s) listed in the References section.
- Record
ALSA-2025:7524- Updated
- 2026-11-02
OSVAZL-59497 No score
CVE-2025-31115 affecting package xz for versions less than 5.4.4-2
XZ Utils provide a general-purpose data-compression library plus command-line tools. In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in liblzma has a bug where invalid input can at least result in a crash. The effects include heap use after free and writing to an address based on the null pointer plus an offset. Applications and libraries that use the lzma_stream_decoder_mt function are affected. The bug has been fixed in XZ Utils 5.8.1, and the fix has been committed to the v5.4, v5.6, v5.8, and master branches in the xz Git repository. No new release packages will be made from the old stable branches, but a standalone patch is available that applies to all affected releases.
- Record
AZL-59497- Updated
- 2026-11-02
OSVHSEC-2025-0003 No score
Use after free in multithreaded lzma (.xz) decoder
Use after free in multithreaded lzma (.xz) decoder
In XZ Utils 5.3.3alpha to 5.8.0, the multithreaded .xz decoder in
liblzma has a bug where invalid input can at least result in a crash
(CVE-2025-31115). The effects include heap use after free and
writing to an address based on the null pointer plus an offset.
Applications and libraries that use the lzma_stream_decoder_mt
function are affected.
The Haskell xz-clib library vendors and builds the C implementation. The xz package does not use the multithreaded decoder and is therefore unaffected.
- Record
HSEC-2025-0003- Updated
- 2026-11-02
OSVMGASA-2025-0131 No score
Updated xz packages fix security vulnerability
XZ has a heap-use-after-free bug in threaded .xz decoder. (CVE-2025-31115)
- Record
MGASA-2025-0131- Updated
- 2026-11-02
OSVopenSUSE-SU-2025:14984-1 No score
liblzma5-32bit-5.8.1-1.1 on GA media
These are all security issues fixed in the liblzma5-32bit-5.8.1-1.1 package on the GA media of openSUSE Tumbleweed.
- Record
openSUSE-SU-2025:14984-1- Updated
- 2026-11-02
OSVSUSE-SU-2025:1137-1 No score
Security update for xz
This update for xz fixes the following issues:
- CVE-2025-31115: Fixed heap use after free and writing to an address based on the null pointer plus an offset (bsc#1240414)
- Record
SUSE-SU-2025:1137-1- Updated
- 2026-11-02
OSVSUSE-SU-2025:20553-1 No score
Security update for xz
This update for xz fixes the following issues:
- CVE-2025-31115: Fixed heap use after free and writing to an address based on the null pointer plus an offset (bsc#1240414)
- Record
SUSE-SU-2025:20553-1- Updated
- 2026-11-02
OSVSUSE-SU-2025:20590-1 No score
Security update for xz
This update for xz fixes the following issues:
- CVE-2025-31115: Fixed heap use after free and writing to an address based on the null pointer plus an offset (bsc#1240414)
- Record
SUSE-SU-2025:20590-1- Updated
- 2026-11-02
OSVUSN-7414-1 No score
xz-utils vulnerability
Harri K. Koskinen discovered that XZ Utils incorrectly handled the threaded xz decoder. If a user or automated system were tricked into processing an xz file, a remote attacker could use this issue to cause XZ Utils to crash, resulting in a denial of service, or possibly execute arbitrary code.
- Record
USN-7414-1- Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
xzAlpine:v3.18 |
before 5.4.3-r1 | 5.4.3-r1 |
xzAlpine:v3.19 |
before 5.4.5-r1 | 5.4.5-r1 |
xzAlpine:v3.20 |
before 5.6.2-r1 | 5.6.2-r1 |
xzAlpine:v3.21 |
before 5.6.3-r1 | 5.6.3-r1 |
xzAlpine:v3.22 |
before 5.8.1-r0 | 5.8.1-r0 |
xzAlpine:v3.23 |
before 5.8.1-r0 | 5.8.1-r0 |
xzAlpine:v3.24 |
before 5.8.1-r0 | 5.8.1-r0 |
xzAlmaLinux:10 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xz-develAlmaLinux:10 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xz-libsAlmaLinux:10 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
Show 26 moreShow less
| Package | Affected | Fixed |
|---|---|---|
xz-lzma-compatAlmaLinux:10 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xzAzure Linux:3 |
before 5.4.4-2 | 5.4.4-2 |
xzAlpaquita:stream |
5.4.1-r0 up to 5.8.1-r0 | 5.8.1-r0 |
xzBellSoft Hardened Containers:stream |
5.4.1-r0 up to 5.8.1-r0 | 5.8.1-r0 |
xz-utilsDebian:12 |
before 5.4.1-1, plus listed versions 5.4.1-0.2 |
5.4.1-1 |
xz-utilsDebian:13 |
before 5.8.1-1 | 5.8.1-1 |
xz-utilsDebian:14 |
before 5.8.1-1 | 5.8.1-1 |
xz-clibHackage |
5.6.3 up to 5.8.1, plus listed versions 5.6.45.8.05.8.0.1 |
5.8.1 |
xzMageia:9 |
before 5.4.3-1.1.mga9 | 5.4.3-1.1.mga9 |
xzopenEuler:24.03-LTS |
before 5.4.7-5.oe2403 | 5.4.7-5.oe2403 |
xzopenEuler:24.03-LTS-SP1 |
before 5.4.7-5.oe2403sp1 | 5.4.7-5.oe2403sp1 |
xz-debuginfoRed Hat:enterprise_linux:10.0 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xz-debugsourceRed Hat:enterprise_linux:10.0 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xz-develRed Hat:enterprise_linux:10.0 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xz-libs-debuginfoRed Hat:enterprise_linux:10.0 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xz-lzma-compatRed Hat:enterprise_linux:10.0 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xz-lzma-compat-debuginfoRed Hat:enterprise_linux:10.0 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xzRed Hat:enterprise_linux:10.0 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xz-libsRed Hat:enterprise_linux:10.0 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xzRocky Linux:10 |
before 1:5.6.2-4.el10_0 | 1:5.6.2-4.el10_0 |
xzSUSE:Linux Enterprise Module for Basesystem 15 SP6 |
before 5.4.1-150600.3.3.1 | 5.4.1-150600.3.3.1 |
xzopenSUSE:Leap 15.6 |
before 5.4.1-150600.3.3.1 | 5.4.1-150600.3.3.1 |
xzSUSE:Linux Micro 6.0 |
before 5.4.3-5.1 | 5.4.3-5.1 |
xzSUSE:Linux Micro 6.1 |
before 5.4.3-slfo.1.1_2.1 | 5.4.3-slfo.1.1_2.1 |
xz-utilsUbuntu:24.04:LTS |
before 5.6.1+really5.4.5-1ubuntu0.2, plus listed versions 5.4.1-0.25.4.4-0.15.4.5-0.15.4.5-0.35.6.0-0.25.6.1+really5.4.5-15.6.1+really5.4.5-1build0.1 |
5.6.1+really5.4.5-1ubuntu0.2 |
xzopenSUSE:Tumbleweed |
before 5.8.1-1.1 | 5.8.1-1.1 |
History
| Recorded | Changed | Sources |
|---|---|---|
| first indexed | CVE List, EUVD, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2025-31115 is a high vulnerability (CVSS 8.7) in Tukaani-project Xz, published April 3, 2025. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.68%, the 52nd percentile. Fixed in xz 5.4.3-r1.
References
github.com/tukaani-project/xz/security/advisories/GHSA-6cc8-p5mm-29w2
github.com/tukaani-project/xz/commit/d5a2ffe41bb77b918a8c96084885d4dbe4bf6480
tukaani.org/xz/xz-cve-2025-31115.patch
openwall.com/lists/oss-security/2025/04/03/1
openwall.com/lists/oss-security/2025/04/03/2
openwall.com/lists/oss-security/2025/04/03/3
Show 29 moreShow less
cert-portal.siemens.com/productcert/html/ssa-082556.html
security.alpinelinux.org/vuln/CVE-2025-31115
access.redhat.com/errata/RHSA-2025:7524
access.redhat.com/security/cve/CVE-2025-31115
bugzilla.redhat.com/2357249
errata.almalinux.org/10/ALSA-2025-7524.html
nvd.nist.gov/vuln/detail/CVE-2025-31115
docs.bell-sw.com/security/cves/CVE-2025-31115
github.com/CVEProject/cvelistV5/tree/main/cves/2025/31xxx/CVE-2025-31115.json
security-tracker.debian.org/tracker/CVE-2025-31115
tukaani.org/xz/threaded-decoder-early-free.html
github.com/hasufell/lzma-static/commit/e95fe96530568addfc83b771900025053e2c6951
advisories.mageia.org/MGASA-2025-0131.html
bugs.mageia.org/show_bug.cgi?id=34164
openeuler.org/zh/security/security-bulletins/detail?id=openEuler-SA-2025-1430
openeuler.org/zh/security/security-bulletins/detail?id=openEuler-SA-2025-1431
access.redhat.com/security/updates/classification
bugzilla.redhat.com/show_bug.cgi?id=2357249
security.access.redhat.com/data/csaf/v2/advisories/2025/rhsa-2025_7524.json
cve.org/CVERecord?id=CVE-2025-31115
errata.rockylinux.org/RLSA-2025:7524
suse.com/support/update/announcement/2025/suse-su-20251137-1
bugzilla.suse.com/1240414
suse.com/security/cve/CVE-2025-31115
suse.com/support/update/announcement/2025/suse-su-202520553-1
suse.com/support/update/announcement/2025/suse-su-202520590-1
ubuntu.com/security/CVE-2025-31115
ubuntu.com/security/notices/USN-7414-1
lists.opensuse.org/archives/list/[email protected]/thread/P5GO5ENHURQSO7WJQXKN647RXXWTS24U