CVEfocus › CVE database › CVE-2025-58058

CVE-2025-58058github.com/ulikunitz/xz leaks memory when decoding a corrupted multiple LZMA archives

CVSS 5.3 MediumEPSS 0.6% (higher than 42% of CVEs)Published 2025-08-28Updated 2025-08-29Assigner: GitHub_M

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.

CWE-770

What to do

Fixed builds are available from Debian, Go: see the table below for the fixed version per release.

Debian, Red Hat, Ubuntu have not shipped a fix for every release yet.

Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.

curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \
  -H "Content-Type: text/plain" --data-binary @inventory.txt

Vendor status at a glance

2Fixed
52Fix pending
3Under investigation
1Will not fix

Status by vendor and release

From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.

ReleasePackageStatusFixed versionAdvisory
Ubuntu 26.10golang-github-ulikunitz-xzFix pendingUBUNTU-CVE-2025-58058
Ubuntu 26.04golang-github-ulikunitz-xzUnder investigationUBUNTU-CVE-2025-58058
Ubuntu 25.10golang-github-ulikunitz-xzWill not fix
Ubuntu decided not to fix this in this release
UBUNTU-CVE-2025-58058
Ubuntu 24.04golang-github-ulikunitz-xzUnder investigationUBUNTU-CVE-2025-58058
Ubuntu 22.04golang-github-ulikunitz-xzUnder investigationUBUNTU-CVE-2025-58058
Ubuntu 20.04golang-github-ulikunitz-xzFix pendingUBUNTU-CVE-2025-58058
Debian 14golang-github-ulikunitz-xzFixed0.5.15-1DEBIAN-CVE-2025-58058
Debian 13golang-github-ulikunitz-xzFix pendingDEBIAN-CVE-2025-58058
Debian 12golang-github-ulikunitz-xzFix pendingDEBIAN-CVE-2025-58058
Red Hat Enterprise Linux 10buildahFix pending
Fix deferred
Red Hat Enterprise Linux 10buildah-testsFix pending
Fix deferred
Red Hat Enterprise Linux 10image-builderFix pending
Fix deferred
Red Hat Enterprise Linux 10osbuild-composerFix pending
Fix deferred
Red Hat Enterprise Linux 10osbuild-composer-coreFix pending
Fix deferred
Red Hat Enterprise Linux 10osbuild-composer-workerFix pending
Fix deferred
Red Hat Enterprise Linux 10podmanFix pending
Fix deferred
Red Hat Enterprise Linux 10podman-dockerFix pending
Fix deferred
Red Hat Enterprise Linux 10podman-remoteFix pending
Fix deferred
Red Hat Enterprise Linux 10podman-testsFix pending
Fix deferred
Red Hat Enterprise Linux 10skopeoFix pending
Fix deferred
Red Hat Enterprise Linux 10skopeo-testsFix pending
Fix deferred
Red Hat Enterprise Linux 9buildahFix pending
Fix deferred
Red Hat Enterprise Linux 9buildah-testsFix pending
Fix deferred
Red Hat Enterprise Linux 9conmonFix pending
Fix deferred
Red Hat Enterprise Linux 9image-builderFix pending
Fix deferred
Red Hat Enterprise Linux 9osbuild-composerFix pending
Fix deferred
Red Hat Enterprise Linux 9osbuild-composer-coreFix pending
Fix deferred
Red Hat Enterprise Linux 9osbuild-composer-dnf-jsonFix pending
Fix deferred
Red Hat Enterprise Linux 9osbuild-composer-workerFix pending
Fix deferred
Red Hat Enterprise Linux 9podmanFix pending
Fix deferred
Red Hat Enterprise Linux 9podman-catatonitFix pending
Fix deferred
Red Hat Enterprise Linux 9podman-dockerFix pending
Fix deferred
Red Hat Enterprise Linux 9podman-gvproxyFix pending
Fix deferred
Red Hat Enterprise Linux 9podman-pluginsFix pending
Fix deferred
Red Hat Enterprise Linux 9podman-remoteFix pending
Fix deferred
Red Hat Enterprise Linux 9podman-testsFix pending
Fix deferred
Red Hat Enterprise Linux 9skopeoFix pending
Fix deferred
Red Hat Enterprise Linux 9skopeo-testsFix pending
Fix deferred
Red Hat Enterprise Linux 8buildahFix pending
Fix deferred
Red Hat Enterprise Linux 8buildah-testsFix pending
Fix deferred
Red Hat Enterprise Linux 8conmonFix pending
Fix deferred
Red Hat Enterprise Linux 8containers-commonFix pending
Fix deferred
Red Hat Enterprise Linux 8osbuild-composerFix pending
Fix deferred
Red Hat Enterprise Linux 8osbuild-composer-coreFix pending
Fix deferred
Red Hat Enterprise Linux 8osbuild-composer-dnf-jsonFix pending
Fix deferred
Red Hat Enterprise Linux 8osbuild-composer-workerFix pending
Fix deferred
Red Hat Enterprise Linux 8podmanFix pending
Fix deferred
Red Hat Enterprise Linux 8podman-catatonitFix pending
Fix deferred
Red Hat Enterprise Linux 8podman-dockerFix pending
Fix deferred
Red Hat Enterprise Linux 8podman-gvproxyFix pending
Fix deferred
Red Hat Enterprise Linux 8podman-manpagesFix pending
Fix deferred
Red Hat Enterprise Linux 8podman-pluginsFix pending
Fix deferred
Red Hat Enterprise Linux 8podman-remoteFix pending
Fix deferred
Red Hat Enterprise Linux 8podman-testsFix pending
Fix deferred
Red Hat Enterprise Linux 8skopeoFix pending
Fix deferred
Red Hat Enterprise Linux 8skopeo-testsFix pending
Fix deferred
Red Hat Enterprise Linux 7skopeoFix pending
Fix deferred
Go librarygithub.com/ulikunitz/xzFixed0.5.15GHSA-jc7w-c686-c4v9

What the vendor says

As published in the CVE record by GitHub_M, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.

References

About this page

Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.