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 E5B55246764 for ; Tue, 20 May 2025 15:34:51 +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=1747755292; cv=none; b=HZhcdk7ujde3qKAHXfHD0IfN1UbHF05o7gQNqBi9dpw8+w7ycDk/e2lEYajz5Q+KzQBi2+0J5e0py+HvLjaPpAwxpH96CyutvXS4L/2oLk09ml5xILYlkQWMPEH7m2gUoZ2hLb9oQILwRbkm3bAL9ybo++DZtxrtDVg4Juv8aXA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747755292; c=relaxed/simple; bh=FzYIRVKmTn2wRr5IM3pVkgZwSUk9h4e1Tz8yGQNNRXk=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=M35mDxKmwZT9TeIcAtlE9tTXFrFk3FzPmXfCtxk0cabrEv9PhPTwHv9z2Dt++XGSsEmmYO5jJjVj2tebl2GvP48B2jx0XxrQy38r/0W2Ukdo4kiissaXuXxNzl0FyB+dZD3gWSkw1FXro5C+cC/F1SoodXkGbamfclNgNb6Abls= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=luXNkqHb; 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="luXNkqHb" Received: by smtp.kernel.org (Postfix) with ESMTPSA id DFE6BC4CEE9; Tue, 20 May 2025 15:34:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1747755291; bh=FzYIRVKmTn2wRr5IM3pVkgZwSUk9h4e1Tz8yGQNNRXk=; h=From:To:Cc:Subject:Date:Reply-to:From; b=luXNkqHbrEgU0ze1TZd66mXQxhXKVFxF181H8k+9XkXUUfiLOyTnr3n/4jpvMQh5i tNrR/CbuOcn1n487RGWX8oYtrn8rYg0Y+bsuU8n74KSm70HqRBVD2HPeKDokgPwpDn QsoeywxgZ1Iet5Gf8MSl51Z8o2YhRMT5fwVHUcQg= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-37938: tracing: Verify event formats that have "%*p.." Date: Tue, 20 May 2025 17:34:46 +0200 Message-ID: <2025052047-CVE-2025-37938-30a4@gregkh> X-Mailer: git-send-email 2.49.0 Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Reply-to: , X-Developer-Signature: v=1; a=openpgp-sha256; l=3418; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=L8lOLjujOvBMERp1MV8heLTahhM+nzFdkL7TY6o0eaA=; b=owGbwMvMwCRo6H6F97bub03G02pJDBk6C8WFz52v2rTxxt3bjlfklq3wdPvE/5bf5/+1/hsxi 5X+/3kn3BHLwiDIxCArpsjyZRvP0f0VhxS9DG1Pw8xhZQIZwsDFKQATUXrJMFeo6fy3++dLhR7J rZf6zH8z6E1gtyjD/JAd4j863+9P+1Y9Y9WmkIlzhBVNlwIA 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: Verify event formats that have "%*p.." The trace event verifier checks the formats of trace events to make sure that they do not point at memory that is not in the trace event itself or in data that will never be freed. If an event references data that was allocated when the event triggered and that same data is freed before the event is read, then the kernel can crash by reading freed memory. The verifier runs at boot up (or module load) and scans the print formats of the events and checks their arguments to make sure that dereferenced pointers are safe. If the format uses "%*p.." the verifier will ignore it, and that could be dangerous. Cover this case as well. Also add to the sample code a use case of "%*pbl". The Linux kernel CVE team has assigned CVE-2025-37938 to this issue. Affected and fixed versions =========================== Issue introduced in 5.13 with commit 5013f454a352cce8e62162976026a9c472595e42 and fixed in 6.1.136 with commit 6854c87ac823181c810f8c07489ba543260c0023 Issue introduced in 5.13 with commit 5013f454a352cce8e62162976026a9c472595e42 and fixed in 6.6.89 with commit 4d11fac941d83509be4e6a21038281d6d96da50c Issue introduced in 5.13 with commit 5013f454a352cce8e62162976026a9c472595e42 and fixed in 6.12.26 with commit 03127354027508d076073b020d3070990fd6a958 Issue introduced in 5.13 with commit 5013f454a352cce8e62162976026a9c472595e42 and fixed in 6.13.11 with commit 04b80d45ecfaf780981d6582899e3ab205e4aa08 Issue introduced in 5.13 with commit 5013f454a352cce8e62162976026a9c472595e42 and fixed in 6.14.2 with commit c7204fd1758c0caf1938e8a59809a1fdf28a8114 Issue introduced in 5.13 with commit 5013f454a352cce8e62162976026a9c472595e42 and fixed in 6.15-rc1 with commit ea8d7647f9ddf1f81e2027ed305299797299aa03 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-2025-37938 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_events.c samples/trace_events/trace-events-sample.h 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/6854c87ac823181c810f8c07489ba543260c0023 https://git.kernel.org/stable/c/4d11fac941d83509be4e6a21038281d6d96da50c https://git.kernel.org/stable/c/03127354027508d076073b020d3070990fd6a958 https://git.kernel.org/stable/c/04b80d45ecfaf780981d6582899e3ab205e4aa08 https://git.kernel.org/stable/c/c7204fd1758c0caf1938e8a59809a1fdf28a8114 https://git.kernel.org/stable/c/ea8d7647f9ddf1f81e2027ed305299797299aa03