From nobody Wed Jul 2 22:27:33 2025 X-Original-To: freebsd-security-notifications@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4bXZK22Lbyz6123n for ; Wed, 02 Jul 2025 22:27:34 +0000 (UTC) (envelope-from security-advisories@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2610:1c1:1:6074::16:84]) (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 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "freefall.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4bXZK16ddnz3Mjx; Wed, 02 Jul 2025 22:27:33 +0000 (UTC) (envelope-from security-advisories@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1751495254; h=from:from:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc; bh=vzTErx4234CUX/iw/7m8ax4dV06ULrnGBJ+sT5vgX9c=; b=n3QNZGqfWnQXS9CBSDUFCpD6D8sq6a+PcyMzkjEax26kPOf4LnPEDHPcAlly4xfYZLSzOY qyVOCLIYkEqTBjIKLOGMdcXFs4zTn1s5AUr/HW9byF0MYbBrO5fo5DsfZ8/4x9kLMZ+bsc ghdRdMieCEE/qbVSMBbJWG2Ash+TnI7Xeczg9yE+IGRXztuoqfR2ZUyTjFMZW7FI4AlNYm MRDnjgsrdnk2Fwvpjf/NGOPi175Yk/cr0qQoK1fnX3IFGYnbrQV3l9sRMyDqiwzZm9nO6F AcMhAmdpOZt6OpZ+jh8FkZjoEJBw3PgdQ/4i/PJuW91jttiWfyl0Ln7aZjC9bw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1751495254; h=from:from:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc; bh=vzTErx4234CUX/iw/7m8ax4dV06ULrnGBJ+sT5vgX9c=; b=tUgtxxzqLar1olLtakUt8+FTK/YnvnVv9/7nZZpi8a1mcbmcA6UckQcGWvf46XiOic8WKv VOs0NxL0QPeu6QAjJyBq3497JEqOl4tuFGcnRhehaedTBcka7oiRAYucIzpgT59FL8gaCi NIEfUoasR/PoX6uWlOyBYkWKdK9H6+5Apyopqvi9YSUSZ01R5eHjCayxRMliAlnDaBOcrN FIJBtJuDu4Tr53bZfINsOlZ919rzFaybpYW3a0piAxgz2irvikNyK+Xsci8/giA6SuSis6 BgIsTHMrTQL1JddneEb5x39dUOQxKDLe17VsuFpb897fh0zmoKR36sjvh1gwrQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1751495254; a=rsa-sha256; cv=none; b=rXBnWf0dwSsnaDOg2DUe42t+/qJJPqSqffIPzOKD3Y6w/fjSrJ1etvGgn/sLH5PnP1a2a4 JtBQ5xCLYvNSxnZQWJl9ko30rXUFAbgu25cEB3m5bCd1LpQIhSF/pkiKZl7T1o274NjXMQ ImlNAi+znY3B7hVIM2KWUqzqwzhYuzCCUHka6jhpBIk8aXrwBoi1uCiliwoEGPk79KJNbq vuqvWi7lcj/lwOzeGm/UpvHNcIrsLiAbPfxXcHCQ4huaeZJAdLswKsAiwC1jWx9kH7dghT XRQMJtPhVRNf4v6rr0FdXJzeiDtwCl/f4r9JcP6Adq3l9oaGwxGuFJgHWeuZFQ== Received: by freefall.freebsd.org (Postfix, from userid 945) id D0157110BC; Wed, 02 Jul 2025 22:27:33 +0000 (UTC) From: FreeBSD Security Advisories To: FreeBSD Security Advisories Subject: FreeBSD Security Advisory FreeBSD-SA-25:06.xz Reply-To: freebsd-security@freebsd.org Precedence: bulk Message-Id: <20250702222733.D0157110BC@freefall.freebsd.org> Date: Wed, 02 Jul 2025 22:27:33 +0000 (UTC) List-Id: Moderated Security Notifications [moderated, low volume] List-Archive: https://lists.freebsd.org/archives/freebsd-security-notifications List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: freebsd-security-notifications@freebsd.org Sender: owner-freebsd-security-notifications@FreeBSD.org -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 ============================================================================= FreeBSD-SA-25:06.xz Security Advisory The FreeBSD Project Topic: Use-after-free in multi-threaded xz decoder Category: contrib Module: xz Announced: 2025-07-02 Affects: FreeBSD 13.5 and FreeBSD 14.2 Corrected: 2025-05-07 21:26:00 UTC (stable/14, 14.2-STABLE) 2025-07-02 18:28:13 UTC (releng/14.2, 14.2-RELEASE-p4) 2025-05-07 21:25:59 UTC (stable/13, 13.4-STABLE) 2025-07-02 18:28:32 UTC (releng/13.5, 13.5-RELEASE-p2) CVE Name: CVE-2025-31115 For general information regarding FreeBSD Security Advisories, including descriptions of the fields above, security branches, and the following sections, please visit . I. Background XZ Utils is a set of free software command-line lossless data compressors, including the programs lzma and xz. II. Problem Description A worker thread could free its input buffer after decoding, while the main thread might still be writing to it. This leads to an use-after-free condition on heap memory. III. Impact An attacker may use specifically crafted .xz file to cause multi-threaded xz decoder to crash, or potentially run arbitrary code under the credential the decoder was executed. IV. Workaround No workaround is available, but systems where xz decoding was not used in multi-threaded mode are not affected. V. Solution Upgrade your vulnerable system to a supported FreeBSD stable or release / security branch (releng) dated after the correction date. Unless the decoder is running as a daemon, no reboot is required. Perform one of the following: 1) To update your vulnerable system via a binary patch: Systems running a RELEASE version of FreeBSD on the amd64 or arm64 platforms, or the i386 platform on FreeBSD 13, can be updated via the freebsd-update(8) utility: # freebsd-update fetch # freebsd-update install # shutdown -r +10min "Rebooting for a security update" 2) To update your vulnerable system via a source code patch: The following patches have been verified to apply to the applicable FreeBSD release branches. a) Download the relevant patch from the location below, and verify the detached PGP signature using your PGP utility. # fetch https://security.FreeBSD.org/patches/SA-25:06/xz.patch # fetch https://security.FreeBSD.org/patches/SA-25:06/xz.patch.asc # gpg --verify xz.patch.asc b) Apply the patch. Execute the following commands as root: # cd /usr/src # patch < /path/to/patch c) Recompile the operating system using buildworld and installworld as described in . Restart all daemons that use the liblzma library, or reboot the system. VI. Correction details This issue is corrected as of the corresponding Git commit hash in the following stable and release branches: Branch/path Hash Revision - ------------------------------------------------------------------------- stable/14/ 5cf27a49a2de stable/14-n271423 releng/14.2/ 49b07b94662b releng/14.2-n269529 stable/13/ 346bb5d3fe19 stable/13-n259281 releng/13.5/ 95e9c54b3961 releng/13.5-n259171 - ------------------------------------------------------------------------- Run the following command to see which files were modified by a particular commit: # git show --stat Or visit the following URL, replacing NNNNNN with the hash: To determine the commit count in a working tree (for comparison against nNNNNNN in the table above), run: # git rev-list --count --first-parent HEAD VII. References The latest revision of this advisory is available at -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEthUnfoEIffdcgYM7bljekB8AGu8FAmhlfTUACgkQbljekB8A Gu/LnA//WD66vLyMS5V+GcwJO3+Txq502F7U/HRoq0TRNJoEkSL5u+tpJD/hZUn4 tkBayhSdJKs6d6UURZdhlEsCF4V7bjMzmudOwUnEwFZNXoUZHe0DHPMzFpGvVrD/ zlN2QZptcP5IU0mPlSFbhQzrUwLnKhjN0NqDZSdaM+7jWDN2zdQFTwijHLFZV66a FYK8Gr+x4OJHn2CtxBz2ST2S4Aaju38D02IdwX/MQFTtVpLHvt2w/j84Ks2c/MXp BJxHKcyohEZRd0jO2XKaX1gBANoLNSRcJbeamJ8zYXSygakbqTkgfW8QHi09WSJH cLqp/NNi4D5v83j11vKlMHAujLgvgTupF7KTG5FXVYF0KZ0URXGEprC9mCWPbIOo 5AD1pbDW1G/OO/cmBn63nILu0U5YLqjcIh2UkJxROs8BBCWouh3k6ZEx2mxQZ9Jy U2aDrC8TwYf1Sqwr063L+WNo38SUSILNaP17xWpeDToDMYHqnrdMOtj/OFDV1g1U ra0CYfp2yWpMZ9UibS6GV+mvtiPe/exxqMNFmkpZ/+uTBbH3vPX/rVbJIJkIsOsA Re9OUfhOYTsPV/bK+NRPAqaLTrmifEECYlskmAgvGoVdMldeL47nGt0EyZLKZ75y xY4qPHPJEv7TXA8ZOpQ85M491TfwoETZ6CytmwjeXQmOEY8KRtQ= =TZId -----END PGP SIGNATURE-----