CVE Catalog

CVE-2025-58058

MediumCVSS 5.3
Published: Updated: Translated: NVD NIST

Exploitation Probability (EPSS)

Low risk
0.41%

33th percentile - higher than 33% of all known CVEs

Summary

In the xz package for Go prior to version 0.5.14, it is possible to place data before an LZMA-encoded byte stream without detection during header reading. This leads to increased memory consumption because the implementation allocates the full decoding buffer immediately after reading the header.

Risk Assessment

An attacker could provide a specially crafted xz file, causing excessive memory consumption, potentially leading to resource exhaustion and denial of service (DoS). The risk affects applications processing untrusted xz files.

Recommendation

Update the xz package for Go to version 0.5.14 or later. Avoid processing untrusted xz files without prior validation.

Related vulnerabilities

Original NVD description (English source)

xz is a pure golang package for reading and writing xz-compressed files. Prior to version 0.5.14, it is possible to put data in front of an LZMA-encoded byte stream without detecting the situation while reading the header. This can lead to increased memory consumption because the current implementation allocates the full decoding buffer directly after reading the header. The LZMA header doesn't include a magic number or has a checksum to detect such an issue according to the specification. Note that the code recognizes the issue later while reading the stream, but at this time the memory allocation has already been done. This issue has been patched in version 0.5.14.

Vulnerability data from NVD (NIST) · CISA KEV · EPSS