CVE-2025-31115 XZ has a heap-use-after-free bug in threaded .xz decoder
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- No known exploitation · automatable: no · technical impact: partial
- Technology
- UbuntuDebian
Description
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.
Upgrade path
16 packages: 12 fixed, 3 with no fix yet.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP | >= V3.1.5 | No fix listed | No fix yet |
| Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP | >= V3.1.5 | No fix listed | No fix yet |
| Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP | >= V3.1.5 | No fix listed | No fix yet |
| alpine/xz(Alpine v3.18) | < 5.4.3-r1 | 5.4.3-r1 | Fixed |
| alpine/xz(Alpine v3.19) | < 5.4.5-r1 | 5.4.5-r1 | Fixed |
| alpine/xz(Alpine v3.20) | < 5.6.2-r1 | 5.6.2-r1 | Fixed |
| alpine/xz(Alpine v3.21) | < 5.6.3-r1 | 5.6.3-r1 | Fixed |
| alpine/xz(Alpine v3.22) | < 5.8.1-r0 | 5.8.1-r0 | Fixed |
| alpine/xz(Alpine v3.23) | < 5.8.1-r0 | 5.8.1-r0 | Fixed |
| alpine/xz(Alpine v3.24) | < 5.8.1-r0 | 5.8.1-r0 | Fixed |
| azure linux xz(Azure Linux 3.0) | < 5.4.4-2 | 5.4.4-2 | Fixed |
| debian/xz-utils(Debian 12) | < 5.4.1-1; = 5.4.1-0.2 | 5.4.1-1 | Fixed |
| debian/xz-utils(Debian 13) | < 5.8.1-1 | 5.8.1-1 | Fixed |
| debian/xz-utils(Debian 14) | < 5.8.1-1 | 5.8.1-1 | Fixed |
| ubuntu/xz-utils(Ubuntu 24.04) | < 5.6.1+really5.4.5-1ubuntu0.2 | 5.6.1+really5.4.5-1ubuntu0.2 | Fixed |
| tukaani-project xz | = >= 5.3.3alpha, < 5.8.1 | No fix listed | Versions listed |
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| azure linux xz(Azure Linux:3.0) | < 5.4.4-2 | 5.4.4-2 |
| debian/xz-utils(Debian:12) | < 5.4.1-1 | 5.4.1-1 |
| debian/xz-utils(Debian:12) | = 5.4.1-0.2 | No fix listed |
| debian/xz-utils(Debian:13) | < 5.8.1-1 | 5.8.1-1 |
| debian/xz-utils(Debian:14) | < 5.8.1-1 | 5.8.1-1 |
| tukaani-project xz | = >= 5.3.3alpha, < 5.8.1 | No fix listed |
| Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP | >= V3.1.5 | No fix listed |
| Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP | >= V3.1.5 | No fix listed |
| Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP | >= V3.1.5 | No fix listed |
| alpine/xz(Alpine:v3.18) | < 5.4.3-r1 | 5.4.3-r1 |
| alpine/xz(Alpine:v3.19) | < 5.4.5-r1 | 5.4.5-r1 |
| alpine/xz(Alpine:v3.20) | < 5.6.2-r1 | 5.6.2-r1 |
| alpine/xz(Alpine:v3.21) | < 5.6.3-r1 | 5.6.3-r1 |
| alpine/xz(Alpine:v3.22) | < 5.8.1-r0 | 5.8.1-r0 |
| alpine/xz(Alpine:v3.23) | < 5.8.1-r0 | 5.8.1-r0 |
| alpine/xz(Alpine:v3.24) | < 5.8.1-r0 | 5.8.1-r0 |
| ubuntu/xz-utils(Ubuntu:24.04) | < 5.6.1+really5.4.5-1ubuntu0.2 | 5.6.1+really5.4.5-1ubuntu0.2 |
References
- MSRC Security Update Guide vendor-advisory
- CBL-Mariner Releases vendor-advisory
- Debian Security Tracker CVE-2025-31115 vendor-advisory
- https://github.com/tukaani-project/xz/security/advisories/GHSA-6cc8-p5mm-29w2
- https://github.com/tukaani-project/xz/commit/d5a2ffe41bb77b918a8c96084885d4dbe4bf6480
- https://tukaani.org/xz/xz-cve-2025-31115.patch
- www.openwall.com
- www.openwall.com
- www.openwall.com
- cert-portal.siemens.com
- security.alpinelinux.org vendor-advisory
- Ubuntu CVE tracker vendor-advisory
- USN-7414-1 vendor-advisory
- www.cve.org
- ENISA EUVD EUVD-2025-14786 third-party-advisory