From mboxrd@z Thu Jan 1 00:00:00 1970 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 113D71F03D2 for ; Mon, 8 Dec 2025 01:20:29 +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=1765156829; cv=none; b=GdK8mihpQvrzHkNMOfuuQyRKU5nehHypYjJUp8QqTE8AJZYtRpjWd9lvh6Hn2ssUfleKJyPgajdYr3n+FEsnV3PNPBi3tJvcHqTXtUXEIl79xMSJM7bxiRRzb5JnSDrLI2jCcf0+nchrKzyg2g0d72a09XaOgLHrnaWxJIFfs24= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1765156829; c=relaxed/simple; bh=IgvhYzgK0G3UircC8jTN/73oGW3WlUak0vKWXtsfn9A=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=ic+ZnbQ7TgAyd+zfF9VaJTRWLTZu6T1wUArDgAhgH9/aNbYV1T+5adOUWzb3viCQchAnHj3NmegygsEsqApinTvuxPyRN66Rfonia3uT2RirfSdzpasDBBPLwJrob44NxNBOasTbcDEqrEdR8YjTDbD5l9GtgzJeQIRtkVtrrTc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=1/BJeHzb; 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="1/BJeHzb" Received: by smtp.kernel.org (Postfix) with ESMTPSA id A3417C4CEFB; Mon, 8 Dec 2025 01:20:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1765156828; bh=IgvhYzgK0G3UircC8jTN/73oGW3WlUak0vKWXtsfn9A=; h=From:To:Cc:Subject:Date:Reply-To:From; b=1/BJeHzbIw5GAIWUmT3NN+pFCUSfdBZKQxJGijVd28sBUEREqozsn54EF0lJUL0ix pUNHHEtoniv2hVI8co5WjGsqHXYcmt0emr0gCRh1mKab9wmWiPdKp7C9cNY+yWR5qu dpH0XLDvhIesNWiIzqn7rQgkOxIi0zJlUNOHUr3g= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2023-53762: Bluetooth: hci_sync: Fix UAF in hci_disconnect_all_sync Date: Mon, 8 Dec 2025 10:20:01 +0900 Message-ID: <2025120845-CVE-2023-53762-01bc@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=4566; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=26vPpWchA+Xde99Ecv+8Xjy1WOfaIjjzhEt8Q5Qs16o=; b=owGbwMvMwCRo6H6F97bub03G02pJDJlm6huv+//kOaifkeXHNHnvp0NVxSLW7tt14/OWsn3Qr 1eYYVjWEcvCIMjEICumyPJlG8/R/RWHFL0MbU/DzGFlAhnCwMUpABM5YsGwYGZr9g+7XzXzHn7d 5SZ9sOds8ymJWwzzDPfmmS1cp55h1LFAfsuXxUHsfzUtAQ== 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: Bluetooth: hci_sync: Fix UAF in hci_disconnect_all_sync Use-after-free can occur in hci_disconnect_all_sync if a connection is deleted by concurrent processing of a controller event. To prevent this the code now tries to iterate over the list backwards to ensure the links are cleanup before its parents, also it no longer relies on a cursor, instead it always uses the last element since hci_abort_conn_sync is guaranteed to call hci_conn_del. UAF crash log: ================================================================== BUG: KASAN: slab-use-after-free in hci_set_powered_sync (net/bluetooth/hci_sync.c:5424) [bluetooth] Read of size 8 at addr ffff888009d9c000 by task kworker/u9:0/124 CPU: 0 PID: 124 Comm: kworker/u9:0 Tainted: G W 6.5.0-rc1+ #10 Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.2-1.fc38 04/01/2014 Workqueue: hci0 hci_cmd_sync_work [bluetooth] Call Trace: dump_stack_lvl+0x5b/0x90 print_report+0xcf/0x670 ? __virt_addr_valid+0xdd/0x160 ? hci_set_powered_sync+0x2c9/0x4a0 [bluetooth] kasan_report+0xa6/0xe0 ? hci_set_powered_sync+0x2c9/0x4a0 [bluetooth] ? __pfx_set_powered_sync+0x10/0x10 [bluetooth] hci_set_powered_sync+0x2c9/0x4a0 [bluetooth] ? __pfx_hci_set_powered_sync+0x10/0x10 [bluetooth] ? __pfx_lock_release+0x10/0x10 ? __pfx_set_powered_sync+0x10/0x10 [bluetooth] hci_cmd_sync_work+0x137/0x220 [bluetooth] process_one_work+0x526/0x9d0 ? __pfx_process_one_work+0x10/0x10 ? __pfx_do_raw_spin_lock+0x10/0x10 ? mark_held_locks+0x1a/0x90 worker_thread+0x92/0x630 ? __pfx_worker_thread+0x10/0x10 kthread+0x196/0x1e0 ? __pfx_kthread+0x10/0x10 ret_from_fork+0x2c/0x50 Allocated by task 1782: kasan_save_stack+0x33/0x60 kasan_set_track+0x25/0x30 __kasan_kmalloc+0x8f/0xa0 hci_conn_add+0xa5/0xa80 [bluetooth] hci_bind_cis+0x881/0x9b0 [bluetooth] iso_connect_cis+0x121/0x520 [bluetooth] iso_sock_connect+0x3f6/0x790 [bluetooth] __sys_connect+0x109/0x130 __x64_sys_connect+0x40/0x50 do_syscall_64+0x60/0x90 entry_SYSCALL_64_after_hwframe+0x6e/0xd8 Freed by task 695: kasan_save_stack+0x33/0x60 kasan_set_track+0x25/0x30 kasan_save_free_info+0x2b/0x50 __kasan_slab_free+0x10a/0x180 __kmem_cache_free+0x14d/0x2e0 device_release+0x5d/0xf0 kobject_put+0xdf/0x270 hci_disconn_complete_evt+0x274/0x3a0 [bluetooth] hci_event_packet+0x579/0x7e0 [bluetooth] hci_rx_work+0x287/0xaa0 [bluetooth] process_one_work+0x526/0x9d0 worker_thread+0x92/0x630 kthread+0x196/0x1e0 ret_from_fork+0x2c/0x50 ================================================================== The Linux kernel CVE team has assigned CVE-2023-53762 to this issue. Affected and fixed versions =========================== Issue introduced in 5.17 with commit 182ee45da083db4e3e621541ccf255bfa9652214 and fixed in 6.4.16 with commit a30c074f0b5b7f909a15c978fbc96a29e2f94e42 Issue introduced in 5.17 with commit 182ee45da083db4e3e621541ccf255bfa9652214 and fixed in 6.5.3 with commit ba3ba53ce1f76fc372b8f918fece4f9b1e41acd4 Issue introduced in 5.17 with commit 182ee45da083db4e3e621541ccf255bfa9652214 and fixed in 6.6 with commit 94d9ba9f9888b748d4abd2aa1547af56ae85f772 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-53762 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: net/bluetooth/hci_sync.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/a30c074f0b5b7f909a15c978fbc96a29e2f94e42 https://git.kernel.org/stable/c/ba3ba53ce1f76fc372b8f918fece4f9b1e41acd4 https://git.kernel.org/stable/c/94d9ba9f9888b748d4abd2aa1547af56ae85f772