From patchwork Sat Dec 5 20:16:24 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adolf Belka X-Patchwork-Id: 10966 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (Client CN "mail01.haj.ipfire.org", Issuer "YR2" (not verified)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4jhfln3kHCz3wh8 for ; Sat, 05 Dec 2026 20:16:53 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (Client CN "mail02.haj.ipfire.org", Issuer "YE1" (not verified)) by mail01.ipfire.org (Postfix) with ESMTPS id 4jhfln0nF5z6ly for ; Sat, 05 Dec 2026 20:16:53 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [IPv6:::1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4jhflc4f5jz2yGy for ; Sat, 05 Dec 2026 20:16:44 +0000 (UTC) X-Original-To: development@lists.ipfire.org Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519) (Client CN "mail01.haj.ipfire.org", Issuer "YR2" (not verified)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4jhflS0wtYz2yLL for ; Sat, 05 Dec 2026 20:16:36 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4jhflQ0D85z8BC; Sat, 05 Dec 2026 20:16:34 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1796501794; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=WdD7af04nMwABQjEBln5fkAd3nSEmyycp8xkI1FWu2s=; b=QPXtVwNCQZvHhcn2iJi7mbtzhedc6cdzxKDNrrW674sBB5ewKk7vNyaqDNpwVZK0/Ha+nI kSQ9Ldb/0C/penCg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1796501794; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=WdD7af04nMwABQjEBln5fkAd3nSEmyycp8xkI1FWu2s=; b=Nw/EK3t7QN12/RrhDm6aykJ0K/0L+SzTbGnps7MAUbjKql4KF8ePGp/DH2O3yv+EJhYmdw BI+oWMaoEfImkQQOdjtQ0jFxkgN0iqJD2pJKfP9oMc2xSboz9hsxkekXAjDEa6Omwi2KPX VXxkXLNpl7uffE/EN55LtQ0m2GSTBpcE/qv9PLsgHgZUlYNDNdPQqJLQT6NDz/McwljHub vzxSSX3z5bqPwXuqLNTTsyljECQEwwnrILHGgjiDV6RmSuu1yMWbu/ZIERd9JGGwQoRGpK 6cvL6rHzOx9CRb5bzNt/qeGDJR+5rIBr8pIuQ+QuVzuAICUiLylFffK0vXLtlw== From: Adolf Belka To: development@lists.ipfire.org Cc: Adolf Belka Subject: [PATCH] xz: Update to version 5.8.5 Date: Sat, 5 Dec 2026 21:16:24 +0100 Message-ID: <20261205201625.2213794-16-adolf.belka@ipfire.org> In-Reply-To: <20261205201625.2213794-1-adolf.belka@ipfire.org> References: <20261205201625.2213794-1-adolf.belka@ipfire.org> Precedence: list List-Id: List-Subscribe: , List-Unsubscribe: , List-Post: List-Help: Sender: Mail-Followup-To: MIME-Version: 1.0 - Update from version 5.8.4 to 5.8.5 - Update of rootfile - This mentions security fixes. There are three GHSA fixes - Changelog 5.8.5 IMPORTANT: This includes security fixes. These and a few other fixes have also been committed to the old stable branches (v5.2, v5.4, and v5.6) in the xz Git repository. Those fixes are marked below. No new 5.2.x, 5.4.x, or 5.6.x releases will be made. * liblzma: - Fix a data corruption bug in the LZMA2 encoder. The issue was found via code analysis; no one has reported actual data corruption. Creating a test file to trigger this bug isn't straightforward, and at the time of this release, no such files are known. If the bug is triggered in a debug build, an assertion will fail. In non-debug builds, a corrupt file is created. It should usually be recoverable if one knows that the corruption is due to this bug. If the dictionary size is smaller than 64 KiB (uncommon) and some extra conditions are met, triggering the bug can result in memory reads a few bytes before the beginning of an array. In this case, if the encoder doesn't crash, the resulting corrupt file won't be recoverable. The bug is specific to liblzma; it wasn't inherited from LZMA SDK, and XZ for Java has done this detail differently from the beginning. This is tracked as GHSA-vhhh-g38j-pr8q. The bug was reported by Vladimir Kukharenko (GenProof). (Also in v5.2, v5.4, and v5.6.) - Fix data corruption or deadlock in the x86 BCJ filter when the buffer passed to the filter function exceeds 4 GiB and contains appropriate input data. Apps, that use smaller buffers to process large files, aren't affected. The code was revised, and the new code is both simpler and faster. This is tracked as GHSA-6237-3fq8-r2hg. The bug was reported by Vladimir Kukharenko (GenProof). (Also in v5.2, v5.4, and v5.6.) - Fix reinitialization bugs in lzma_stream_encoder_mt(): * Reinitialization with different lzma_mt.block_size could result in a buffer overflow. It should crash easily, yet this bug wasn't found until now. So it seems that few applications can trigger it. For example, xz cannot. * If the encoder was reinitialized in some other situation than after lzma_code() has returned LZMA_STREAM_END, the reinitialized encoder could corrupt data, deadlock, or show wrong progress indicator information. In xz this was possible after memory allocation failure or I/O error. These are tracked as GHSA-jvh7-x64f-69mg. The bugs were reported by Mar. (Also in v5.2, v5.4, and v5.6.) - lzma_alone_decoder() and lzma_raw_decoder() with LZMA_FILTER_LZMA1EXT: Fix detection of an optional LZMA end marker. Decoding failed with LZMA_DATA_ERROR if all input bytes needed to decode the end marker weren't provided in the same lzma_code() call. That is, the failure depended how the input file was split into chunks by an application. (Also in v5.2, v5.4, and v5.6.) - lzma_stream_decoder_mt(): * Fix a double free if a mutex or condition variable initialization failed. * Fix a mutex and condition variable leak on lzma_end(). * Fix lzma_memusage() after lzma_code() has returned LZMA_MEMLIMIT_ERROR. The reported memory usage requirement was too low (usually 32 KiB). Increasing the limit to that value with lzma_memlimit_set() incorrectly succeeded, but lzma_code() still returned LZMA_MEMLIMIT_ERROR and decoding couldn't be continued. (Also in v5.4 and v5.6.) - Fixes that affect lzma_memusage(), lzma_memlimit_get(), and lzma_memlimit_set() when used with specific decoders: * lzma_stream_decoder(), lzma_alone_decoder(), and lzma_lzip_decoder(): After decoder reinitialization, include the still-allocated cached memory from the previous decoder instance in the current memory usage. lzma_auto_decoder() and lzma_stream_decoder_mt() already did this. * lzma_auto_decoder(): After decoder reinitialization with a different memory usage limit, make lzma_memlimit_get() return the current limit, not the previous limit. In debug builds, fix a related assertion failure, which also occurred with lzma_memusage() and lzma_memlimit_set(). - lzma_stream_decoder(), lzma_stream_decoder_mt(), lzma_alone_decoder(), lzma_auto_decoder(), and lzma_lzip_decoder(): On reinitialization, free the old cached decoder if its memory usage is higher than the new memory usage limit. - Set lzma_stream.total_in and .total_out to 0 even if a coder initialization fails. This matches the API docs, but it's unlikely that anything actually cares about these counters after an initialization error. (Also in v5.2, v5.4, and v5.6.) - lzma_easy_encoder(): If called with an unsupported preset, free the previous coder (if any) to avoid a memory leak. (Also in v5.2, v5.4, and v5.6.) - lzma_easy_encoder_memusage() and lzma_easy_decoder_memusage(): On error (invalid or unsupported preset), return UINT64_MAX as documented instead of UINT32_MAX. (Also in v5.2, v5.4, and v5.6.) - lzma_get_progress(): Don't crash if no coder is initialized in the lzma_stream argument. (Also in v5.2, v5.4, and v5.6.) - lzma_index_append(): Fix a possible integer overflow if the function is called on a concatenated lzma_index (created using lzma_index_cat()). It's valid use of the API, but there is no known use case where an application might want to do this. (Also in v5.2, v5.4, and v5.6.) - LZMA/LZMA2 encoder: Silence Valgrind and -fsanitize=memory if a preset dictionary is used (a raw encoder only feature). A few bytes of uninitialized memory was read, but those bytes were eventually ignored, so the code still worked correctly. (Also in v5.2, v5.4, and v5.6.) - Improve LZMA/LZMA2 encoder speed by prefetching hash table entries with __builtin_prefetch(). The benefit depends on the computer, input file, and compression settings. - Linux: Make lzma_physmem() and lzma_cputhreads() look at cgroup v2 memory.max and cpu.max, and use the .max values when they are lower than the physical hardware resources. This makes it much less likely that OOM killer will send SIGKILL to xz (or any other app that uses these functions to estimate available resources) when running in a container that uses these cgroup v2 limits. NOTE: In some distros, one might need to update SELinux policies for applications that call lzma_physmem() or lzma_cputhreads() because now these functions try to read files from the /sys/fs/cgroup tree. * xz: Fix EINTR handling in --files and --files0. If reading a filename blocked and a progress indicator signal (SIGALRM, SIGUSR1, or SIGINFO) or stop signal from a user (SIGTSTP) arrived, the rest of the filenames were ignored and xz went into an infinite loop. (Also in v5.2, v5.4, and v5.6.) * xz and xzdec on Linux: Support Landlock ABI version 10. * lzmainfo: Open named files in binary mode. This matters on Windows. Reading from standard input didn't have this bug. (Also in v5.2, v5.4, and v5.6.) * xzdiff: Fix "xzdiff foo_z" to decompress foo_z with gzip and compare it against uncompressed file "foo". * Tests: - Fix test_files.sh failure with --disable-xz. - Add new test files: * file bad-1-powerpc-1.xz (60 bytes) * Translations: - Add Chinese (simplified), Chinese (traditional), and Latvian man page translations. - Add Chinese (simplified) and Latvian message translations. - Update Spanish message translations. Signed-off-by: Adolf Belka --- config/rootfiles/common/xz | 78 +++++++++++++++++++++++++++++++++++++- lfs/xz | 4 +- 2 files changed, 79 insertions(+), 3 deletions(-) diff --git a/config/rootfiles/common/xz b/config/rootfiles/common/xz index d7af0fa4d..08b63eda1 100644 --- a/config/rootfiles/common/xz +++ b/config/rootfiles/common/xz @@ -41,7 +41,7 @@ usr/bin/xzmore #usr/lib/liblzma.la #usr/lib/liblzma.so usr/lib/liblzma.so.5 -usr/lib/liblzma.so.5.8.4 +usr/lib/liblzma.so.5.8.5 #usr/lib/pkgconfig/liblzma.pc #usr/share/doc/xz #usr/share/doc/xz/AUTHORS @@ -76,6 +76,7 @@ usr/lib/liblzma.so.5.8.4 #usr/share/locale/it/LC_MESSAGES/xz.mo #usr/share/locale/ka/LC_MESSAGES/xz.mo #usr/share/locale/ko/LC_MESSAGES/xz.mo +#usr/share/locale/lv/LC_MESSAGES/xz.mo #usr/share/locale/nl/LC_MESSAGES/xz.mo #usr/share/locale/pl/LC_MESSAGES/xz.mo #usr/share/locale/pt/LC_MESSAGES/xz.mo @@ -201,6 +202,31 @@ usr/lib/liblzma.so.5.8.4 #usr/share/man/ko/man1/xzgrep.1 #usr/share/man/ko/man1/xzless.1 #usr/share/man/ko/man1/xzmore.1 +#usr/share/man/lv +#usr/share/man/lv/man1 +#usr/share/man/lv/man1/lzcat.1 +#usr/share/man/lv/man1/lzcmp.1 +#usr/share/man/lv/man1/lzdiff.1 +#usr/share/man/lv/man1/lzegrep.1 +#usr/share/man/lv/man1/lzfgrep.1 +#usr/share/man/lv/man1/lzgrep.1 +#usr/share/man/lv/man1/lzless.1 +#usr/share/man/lv/man1/lzma.1 +#usr/share/man/lv/man1/lzmadec.1 +#usr/share/man/lv/man1/lzmainfo.1 +#usr/share/man/lv/man1/lzmore.1 +#usr/share/man/lv/man1/unlzma.1 +#usr/share/man/lv/man1/unxz.1 +#usr/share/man/lv/man1/xz.1 +#usr/share/man/lv/man1/xzcat.1 +#usr/share/man/lv/man1/xzcmp.1 +#usr/share/man/lv/man1/xzdec.1 +#usr/share/man/lv/man1/xzdiff.1 +#usr/share/man/lv/man1/xzegrep.1 +#usr/share/man/lv/man1/xzfgrep.1 +#usr/share/man/lv/man1/xzgrep.1 +#usr/share/man/lv/man1/xzless.1 +#usr/share/man/lv/man1/xzmore.1 #usr/share/man/man1/lzcat.1 #usr/share/man/man1/lzcmp.1 #usr/share/man/man1/lzdiff.1 @@ -337,3 +363,53 @@ usr/lib/liblzma.so.5.8.4 #usr/share/man/uk/man1/xzgrep.1 #usr/share/man/uk/man1/xzless.1 #usr/share/man/uk/man1/xzmore.1 +#usr/share/man/zh_CN +#usr/share/man/zh_CN/man1 +#usr/share/man/zh_CN/man1/lzcat.1 +#usr/share/man/zh_CN/man1/lzcmp.1 +#usr/share/man/zh_CN/man1/lzdiff.1 +#usr/share/man/zh_CN/man1/lzegrep.1 +#usr/share/man/zh_CN/man1/lzfgrep.1 +#usr/share/man/zh_CN/man1/lzgrep.1 +#usr/share/man/zh_CN/man1/lzless.1 +#usr/share/man/zh_CN/man1/lzma.1 +#usr/share/man/zh_CN/man1/lzmadec.1 +#usr/share/man/zh_CN/man1/lzmainfo.1 +#usr/share/man/zh_CN/man1/lzmore.1 +#usr/share/man/zh_CN/man1/unlzma.1 +#usr/share/man/zh_CN/man1/unxz.1 +#usr/share/man/zh_CN/man1/xz.1 +#usr/share/man/zh_CN/man1/xzcat.1 +#usr/share/man/zh_CN/man1/xzcmp.1 +#usr/share/man/zh_CN/man1/xzdec.1 +#usr/share/man/zh_CN/man1/xzdiff.1 +#usr/share/man/zh_CN/man1/xzegrep.1 +#usr/share/man/zh_CN/man1/xzfgrep.1 +#usr/share/man/zh_CN/man1/xzgrep.1 +#usr/share/man/zh_CN/man1/xzless.1 +#usr/share/man/zh_CN/man1/xzmore.1 +#usr/share/man/zh_TW +#usr/share/man/zh_TW/man1 +#usr/share/man/zh_TW/man1/lzcat.1 +#usr/share/man/zh_TW/man1/lzcmp.1 +#usr/share/man/zh_TW/man1/lzdiff.1 +#usr/share/man/zh_TW/man1/lzegrep.1 +#usr/share/man/zh_TW/man1/lzfgrep.1 +#usr/share/man/zh_TW/man1/lzgrep.1 +#usr/share/man/zh_TW/man1/lzless.1 +#usr/share/man/zh_TW/man1/lzma.1 +#usr/share/man/zh_TW/man1/lzmadec.1 +#usr/share/man/zh_TW/man1/lzmainfo.1 +#usr/share/man/zh_TW/man1/lzmore.1 +#usr/share/man/zh_TW/man1/unlzma.1 +#usr/share/man/zh_TW/man1/unxz.1 +#usr/share/man/zh_TW/man1/xz.1 +#usr/share/man/zh_TW/man1/xzcat.1 +#usr/share/man/zh_TW/man1/xzcmp.1 +#usr/share/man/zh_TW/man1/xzdec.1 +#usr/share/man/zh_TW/man1/xzdiff.1 +#usr/share/man/zh_TW/man1/xzegrep.1 +#usr/share/man/zh_TW/man1/xzfgrep.1 +#usr/share/man/zh_TW/man1/xzgrep.1 +#usr/share/man/zh_TW/man1/xzless.1 +#usr/share/man/zh_TW/man1/xzmore.1 diff --git a/lfs/xz b/lfs/xz index b0c90d790..78d869b85 100644 --- a/lfs/xz +++ b/lfs/xz @@ -24,7 +24,7 @@ include Config -VER = 5.8.4 +VER = 5.8.5 THISAPP = xz-$(VER) DL_FILE = $(THISAPP).tar.xz @@ -45,7 +45,7 @@ objects = $(DL_FILE) $(DL_FILE) = $(DL_FROM)/$(DL_FILE) -$(DL_FILE)_BLAKE2 = 917cd5c0b8bf296d15b6d868a6be3910f73e06f96eb2e17a2064902c3635268a4b0aca9f8c617a402cffc10e06e4e12d998bacf8db81f084cf62e46f3485fb51 +$(DL_FILE)_BLAKE2 = 2ae4b36687b4294b7798ee81b0043be843bfaba86c449c21ea3d054960650b47ee59fcae43ddb3ca1ab5111336a5b1ac25624940edbf4417a6029a78b7724336 install : $(TARGET)