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 6DD131F180C for ; Wed, 16 Apr 2025 14:15:56 +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=1744812956; cv=none; b=oy6b/QxWbotSi3P6YmkOBdwmM/tju9vDL+ZNyO+bNgav2iNvkQDdhSjHOCDWR6sgiBx4yk7SnFV2UEVr5vEStSHB/+3SMcu+r3ZrbS768OxketowGwd9ZLBe5VrA6aO819lRvNw6u6Hj+pBrB+wXPCj9OhZXEt+gdUxO+oN1hW0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744812956; c=relaxed/simple; bh=depbjSHvEcxbqDwkw35wNT6WtW7sh9wcMKAQzERh2fc=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=BlKb3pCMKYhNyXMZrNJVCNCjbERAo5AR0vXpokcmlKcD2bN/7OfkUMOYk8+PxTSaVBxu5AGjlYky99oQ7fXoSilNLcG+pM5GybysBu/00X82jIZH7Lke5zXSrsL4bDG+qHv0jAF8Pp6QkDMlK0Pc4iKQTQ7Zwzs+GcxncgUuV1k= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=0MbATkF9; 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="0MbATkF9" Received: by smtp.kernel.org (Postfix) with ESMTPSA id D26DDC4CEE2; Wed, 16 Apr 2025 14:15:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1744812956; bh=depbjSHvEcxbqDwkw35wNT6WtW7sh9wcMKAQzERh2fc=; h=From:To:Cc:Subject:Date:Reply-to:From; b=0MbATkF9ylW64AD5tRk+q8O/uoZ3F4gqd03XdjltvkLD/covcYqnVh/fY9IiTKg7x kCZWKFxu5cB8R8nTB9gFyVtqocj58zjG5a6rme0OJ0jEmbvszGr0WRCnF2jNqd3TvE 950n50RUA3DokwLE07QEuNocFX3B3zgxDUe2LLUg= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2025-22041: ksmbd: fix use-after-free in ksmbd_sessions_deregister() Date: Wed, 16 Apr 2025 16:12:12 +0200 Message-ID: <2025041600-CVE-2025-22041-6dbd@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=2464; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=depbjSHvEcxbqDwkw35wNT6WtW7sh9wcMKAQzERh2fc=; b=owGbwMvMwCRo6H6F97bub03G02pJDOn/d23IExFo+lGpp9TWeO/Gn10XsnSnzPxiu2bao33r5 4vH7XnS2RHLwiDIxCArpsjyZRvP0f0VhxS9DG1Pw8xhZQIZwsDFKQATubWQYa7wlvDyqh71v2+O tXo/9Y1e0qPJfpphfsgFTqUOXt65wW85Fuke4uKJzOSqBQA= X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit Description =========== In the Linux kernel, the following vulnerability has been resolved: ksmbd: fix use-after-free in ksmbd_sessions_deregister() In multichannel mode, UAF issue can occur in session_deregister when the second channel sets up a session through the connection of the first channel. session that is freed through the global session table can be accessed again through ->sessions of connection. The Linux kernel CVE team has assigned CVE-2025-22041 to this issue. Affected and fixed versions =========================== Fixed in 6.1.134 with commit f0eb3f575138b816da74697bd506682574742fcd Fixed in 6.6.87 with commit a8a8ae303a8395cbac270b5b404d85df6ec788f8 Fixed in 6.12.23 with commit ca042cc0e4f9e0d2c8f86dd67e4b22f30a516a9b Fixed in 6.13.11 with commit 8ed0e9d2f410f63525afb8351181eea36c80bcf1 Fixed in 6.14.2 with commit 33cc29e221df7a3085ae413e8c26c4e81a151153 Fixed in 6.15-rc1 with commit 15a9605f8d69dc85005b1a00c31a050b8625e1aa 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-22041 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: fs/smb/server/mgmt/user_session.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/f0eb3f575138b816da74697bd506682574742fcd https://git.kernel.org/stable/c/a8a8ae303a8395cbac270b5b404d85df6ec788f8 https://git.kernel.org/stable/c/ca042cc0e4f9e0d2c8f86dd67e4b22f30a516a9b https://git.kernel.org/stable/c/8ed0e9d2f410f63525afb8351181eea36c80bcf1 https://git.kernel.org/stable/c/33cc29e221df7a3085ae413e8c26c4e81a151153 https://git.kernel.org/stable/c/15a9605f8d69dc85005b1a00c31a050b8625e1aa