Use After Free Affecting tukaani-project/xz package, versions [5.3.3alpha,5.8.1)


Severity

Recommended
0.0
high
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.07% (18th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Use After Free vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-UNMANAGED-TUKAANIPROJECTXZ-9673785
  • published6 Apr 2025
  • disclosed2 Apr 2025
  • creditHarri K. Koskinen

Introduced: 2 Apr 2025

NewCVE-2025-31115  (opens in a new tab)
CWE-416  (opens in a new tab)

How to fix?

Upgrade tukaani-project/xz to version 5.8.1 or higher.

Overview

Affected versions of this package are vulnerable to Use After Free when processing multiple threads in the worker_decoder() function in stream_decoder_mt.c. An attacker can cause the input buffer to be freed while a worker-specific thread is still writing to it, triggering a crash.

Note: The lzma_stream_decoder, including its use by xz --decompress --threads=1 and xzdec commands, is not affected.

CVSS Base Scores

version 4.0
version 3.1