Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 65E45296BA9 for ; Tue, 30 Dec 2025 12:10:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767096633; cv=none; b=BEwF6GoR2lxGl9iPWZTR1tYKt6cIGjK+skBo2hFqenZlTqUGFU1tPRSk9nUCQVMcSVYVYeBMUkpfgey+Fy5NkJPxUx66MtMc57td8x11UKJB1e3sehuwzCtB/FV9tNAHmeOTGJBm42Veu4ZaEvS7bnYPtKF3Fa8GGGIsE796E1M= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767096633; c=relaxed/simple; bh=ma9qckq9URSteS++buc7tcSoEY0Pv7DP/3WF4YUSek4=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=WdME6hmJIAOBSDG8isbzSsE2Lnli+xUIGHYLvyhQ7qxK8lvFSm/vX8SypPQFX2AWZiiXlonqUahypJlrPyYKwD92X5vgh5t31lNXtjMk55ShmjPFF7MxUCRbHK3jjv4gid6znM/s4jF9+GlrdnOg7rHQF6TueD1ZaYc7cbsSzEE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=epgyqRE0; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="epgyqRE0" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 98899C4CEFB; Tue, 30 Dec 2025 12:10:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1767096632; bh=ma9qckq9URSteS++buc7tcSoEY0Pv7DP/3WF4YUSek4=; h=From:To:Cc:Subject:Date:Reply-To:From; b=epgyqRE03RrLtLeCq6EIwFOjwzxG47BIgm14Ldj3C8E60FBFGklGeUr9AgQ0LsqoS UNPY5OgbmPl4+txDgAbbdVQm0WrY9FQ/paw82cqT6eOpM6vVGEBZICtIwv5NU7s40h n2+rcY3wvGa5BfesOXyKAhbYG+VAohkePDCfMVqU= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2023-54171: tracing: Fix memory leak of iter->temp when reading trace_pipe Date: Tue, 30 Dec 2025 13:09:39 +0100 Message-ID: <2025123021-CVE-2023-54171-5524@gregkh> X-Mailer: git-send-email 2.52.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=3485; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=nGYbzHfoOxTjEwRQj55kPWFjz/DrJocfir1PgV7MGe8=; b=owGbwMvMwCRo6H6F97bub03G02pJDJnBBz7qiWWJM2UXxK6ZPOdn86/5DR2ePBoHFdL/5rpPV VX0X+fREcvCIMjEICumyPJlG8/R/RWHFL0MbU/DzGFlAhnCwMUpABOxOc4wV77T5EbIJW+1Kasc 7vj8y5y6ovvOEob5tYW9J1V7mQ1eLo4+7W3yZcOM19clAA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: tracing: Fix memory leak of iter->temp when reading trace_pipe kmemleak reports: unreferenced object 0xffff88814d14e200 (size 256): comm "cat", pid 336, jiffies 4294871818 (age 779.490s) hex dump (first 32 bytes): 04 00 01 03 00 00 00 00 08 00 00 00 00 00 00 00 ................ 0c d8 c8 9b ff ff ff ff 04 5a ca 9b ff ff ff ff .........Z...... backtrace: [] __kmalloc+0x4f/0x140 [] trace_find_next_entry+0xbb/0x1d0 [] trace_print_lat_context+0xaf/0x4e0 [] print_trace_line+0x3e0/0x950 [] tracing_read_pipe+0x2d9/0x5a0 [] vfs_read+0x143/0x520 [] ksys_read+0xbd/0x160 [] do_syscall_64+0x3f/0x90 [] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 when reading file 'trace_pipe', 'iter->temp' is allocated or relocated in trace_find_next_entry() but not freed before 'trace_pipe' is closed. To fix it, free 'iter->temp' in tracing_release_pipe(). The Linux kernel CVE team has assigned CVE-2023-54171 to this issue. Affected and fixed versions =========================== Issue introduced in 5.7 with commit ff895103a84abc85a5f43ecabc7f67cf36e1348f and fixed in 5.10.188 with commit 1a1e793e021d75cd0accd8f329ec9456e5cd105e Issue introduced in 5.7 with commit ff895103a84abc85a5f43ecabc7f67cf36e1348f and fixed in 5.15.121 with commit 954792db9f61b6c0b8a94b8831fed5f146014029 Issue introduced in 5.7 with commit ff895103a84abc85a5f43ecabc7f67cf36e1348f and fixed in 6.1.40 with commit be970e22c53d5572b2795b79da9716ada937023b Issue introduced in 5.7 with commit ff895103a84abc85a5f43ecabc7f67cf36e1348f and fixed in 6.4.5 with commit 3f42d57a76e7e96585f08855554e002218cbca0c Issue introduced in 5.7 with commit ff895103a84abc85a5f43ecabc7f67cf36e1348f and fixed in 6.5 with commit d5a821896360cc8b93a15bd888fabc858c038dc0 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2023-54171 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: kernel/trace/trace.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/1a1e793e021d75cd0accd8f329ec9456e5cd105e https://git.kernel.org/stable/c/954792db9f61b6c0b8a94b8831fed5f146014029 https://git.kernel.org/stable/c/be970e22c53d5572b2795b79da9716ada937023b https://git.kernel.org/stable/c/3f42d57a76e7e96585f08855554e002218cbca0c https://git.kernel.org/stable/c/d5a821896360cc8b93a15bd888fabc858c038dc0