{"id":"CVE-2026-139378","state":"PUBLISHED","title":"Bluetooth: hci_sync: Serialize devcoredump reset during device open","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nBluetooth: hci_sync: Serialize devcoredump reset during device open\n\nAn ACTIVE devcoredump's buffer cursors must remain valid from the\npacket handler's state check through its copy. hci_devcd_rx() holds\nhdev->lock across that interval, and hci_devcd_reset() requires the\nsame lock. However, hci_dev_open_sync() invokes reset without taking\nit.\n\nA registered VHCI controller can collect a dump through its debugfs\ninterface while the controller is down. If a successful open overlaps\nwith handling a nonempty dump packet, reset can run after the receiver's\nACTIVE check and before its copy:\n\n  hci_devcd_rx()                    hci_dev_open_sync()\n    dequeue nonempty skb\n    hci_dev_lock(hdev)\n    handler observes ACTIVE\n                                     hdev->open(hdev) succeeds\n                                     hci_devcd_reset(hdev)\n                                       dump.tail = NULL\n                                       dump.state = IDLE\n    hci_devcd_copy()\n      compare against old dump.end\n      memcpy(NULL, ..., skb->len)\n    hci_dev_unlock(hdev)\n\nReset leaves dump.end pointing at the old buffer and purges only queued\npackets, so it cannot discard the skb already dequeued by the receiver.\nThe bounds check can pass with a NULL tail, leading to a nonempty copy\nto address zero. KASAN reported a 24-byte NULL write in hci_devcd_rx().\n\nTake hdev->lock around the open-time reset. The receiver then finishes\nits state check and copy using valid cursors before reset, or observes\nIDLE after reset and skips the copy.\n\nKASAN report as below:\n\n    BUG: KASAN: null-ptr-deref in hci_devcd_rx+0x5d5/0x1a80\n    Write of size 24 at addr 0000000000000000 by task kworker/u17:0/496\n\n        CPU: 0 UID: 0 PID: 496 Comm: kworker/u17:0 Not tainted\n    7.2.0-rc6-pmb-bt-functional-v1+ #1 PREEMPT(lazy)\n        Hardware name: QEMU Ubuntu 24.04 PC v2 (i440FX + PIIX, arch_caps\n    fix, 1996), BIOS 1.16.3-debian-1.16.3-2 04/01/2014\n    Workqueue: hci0 hci_devcd_rx\n    Call Trace:\n     <TASK>\n     dump_stack_lvl+0x93/0xd0\n     kasan_report+0xe0/0x110\n     ? hci_devcd_rx+0x5d5/0x1a80\n     kasan_check_range+0x105/0x1b0\n     __asan_memcpy+0x3c/0x60\n     hci_devcd_rx+0x5d5/0x1a80\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? __pfx_hci_devcd_rx+0x10/0x10\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? lock_release+0xc8/0x280\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     process_one_work+0x908/0x19c0\n     ? __pfx_process_one_work+0x10/0x10\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? lock_is_held_type+0x8f/0x100\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     worker_thread+0x65c/0xe40\n     ? __pfx_worker_thread+0x10/0x10\n     kthread+0x34f/0x460\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? __pfx_kthread+0x10/0x10\n     ret_from_fork+0x659/0x940\n     ? __pfx_ret_from_fork+0x10/0x10\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? __switch_to+0x74f/0xf80\n     ? __pfx_kthread+0x10/0x10\n     ret_from_fork_asm+0x1a/0x30\n     </TASK>\n    ==================================================================\n    Disabling lock debugging due to kernel taint","publishedAt":"2026-11-30T13:34:12.194Z","updatedAt":"2026-11-30T13:34:12.194Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"deb8156ebe5cb63a5988e7f86cc46aa062527c2b","status":"affected","lessThan":"265f3540b37a9452dce4fba99406c763fb7730c0","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"a5fabcd656b2ae6f625f512b1207b979488886fc","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"03dce75459e06842832ea1670a3b3c46e5b65de4","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"b782fe3f409eaaa22fcb6c87b2f86f2b417e94b1","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"3973e025ed583096894a0c98c3d4cf28018b7cc2","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"6d91353f6dbcc5c4fbb47bbd0c7f885453cfc939","versionType":"git"},{"version":"6.1.188","status":"affected","lessThan":"6.1.193","versionType":"semver"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/bluetooth/hci_sync.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.4","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.4","versionType":"semver"},{"version":"6.1.193","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.163","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.119","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.65","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.3.6","status":"unaffected","lessThanOrEqual":"7.3.*","versionType":"semver"},{"version":"7.4-rc1","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/bluetooth/hci_sync.c"]}],"references":["https://git.kernel.org/stable/c/265f3540b37a9452dce4fba99406c763fb7730c0","https://git.kernel.org/stable/c/a5fabcd656b2ae6f625f512b1207b979488886fc","https://git.kernel.org/stable/c/03dce75459e06842832ea1670a3b3c46e5b65de4","https://git.kernel.org/stable/c/b782fe3f409eaaa22fcb6c87b2f86f2b417e94b1","https://git.kernel.org/stable/c/3973e025ed583096894a0c98c3d4cf28018b7cc2","https://git.kernel.org/stable/c/6d91353f6dbcc5c4fbb47bbd0c7f885453cfc939"],"weaknesses":[],"ingestedAt":"2026-11-30T13:48:04.491Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/139xxx/CVE-2026-139378.json","commit":"8c2c22940a0de21d18737df980299c0488d5dc73","baselineCommit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-139378","state":"PUBLISHED","datePublished":"2026-11-30T13:34:12.194Z","dateUpdated":"2026-11-30T13:34:12.194Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-11-30T13:22:15.930Z"},"containers":{"cna":{"title":"Bluetooth: hci_sync: Serialize devcoredump reset during device open","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nBluetooth: hci_sync: Serialize devcoredump reset during device open\n\nAn ACTIVE devcoredump's buffer cursors must remain valid from the\npacket handler's state check through its copy. hci_devcd_rx() holds\nhdev->lock across that interval, and hci_devcd_reset() requires the\nsame lock. However, hci_dev_open_sync() invokes reset without taking\nit.\n\nA registered VHCI controller can collect a dump through its debugfs\ninterface while the controller is down. If a successful open overlaps\nwith handling a nonempty dump packet, reset can run after the receiver's\nACTIVE check and before its copy:\n\n  hci_devcd_rx()                    hci_dev_open_sync()\n    dequeue nonempty skb\n    hci_dev_lock(hdev)\n    handler observes ACTIVE\n                                     hdev->open(hdev) succeeds\n                                     hci_devcd_reset(hdev)\n                                       dump.tail = NULL\n                                       dump.state = IDLE\n    hci_devcd_copy()\n      compare against old dump.end\n      memcpy(NULL, ..., skb->len)\n    hci_dev_unlock(hdev)\n\nReset leaves dump.end pointing at the old buffer and purges only queued\npackets, so it cannot discard the skb already dequeued by the receiver.\nThe bounds check can pass with a NULL tail, leading to a nonempty copy\nto address zero. KASAN reported a 24-byte NULL write in hci_devcd_rx().\n\nTake hdev->lock around the open-time reset. The receiver then finishes\nits state check and copy using valid cursors before reset, or observes\nIDLE after reset and skips the copy.\n\nKASAN report as below:\n\n    BUG: KASAN: null-ptr-deref in hci_devcd_rx+0x5d5/0x1a80\n    Write of size 24 at addr 0000000000000000 by task kworker/u17:0/496\n\n        CPU: 0 UID: 0 PID: 496 Comm: kworker/u17:0 Not tainted\n    7.2.0-rc6-pmb-bt-functional-v1+ #1 PREEMPT(lazy)\n        Hardware name: QEMU Ubuntu 24.04 PC v2 (i440FX + PIIX, arch_caps\n    fix, 1996), BIOS 1.16.3-debian-1.16.3-2 04/01/2014\n    Workqueue: hci0 hci_devcd_rx\n    Call Trace:\n     <TASK>\n     dump_stack_lvl+0x93/0xd0\n     kasan_report+0xe0/0x110\n     ? hci_devcd_rx+0x5d5/0x1a80\n     kasan_check_range+0x105/0x1b0\n     __asan_memcpy+0x3c/0x60\n     hci_devcd_rx+0x5d5/0x1a80\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? __pfx_hci_devcd_rx+0x10/0x10\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? lock_release+0xc8/0x280\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     process_one_work+0x908/0x19c0\n     ? __pfx_process_one_work+0x10/0x10\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? lock_is_held_type+0x8f/0x100\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     worker_thread+0x65c/0xe40\n     ? __pfx_worker_thread+0x10/0x10\n     kthread+0x34f/0x460\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? __pfx_kthread+0x10/0x10\n     ret_from_fork+0x659/0x940\n     ? __pfx_ret_from_fork+0x10/0x10\n     ? srso_alias_return_thunk+0x5/0xfbef5\n     ? __switch_to+0x74f/0xf80\n     ? __pfx_kthread+0x10/0x10\n     ret_from_fork_asm+0x1a/0x30\n     </TASK>\n    ==================================================================\n    Disabling lock debugging due to kernel taint"}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"deb8156ebe5cb63a5988e7f86cc46aa062527c2b","status":"affected","lessThan":"265f3540b37a9452dce4fba99406c763fb7730c0","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"a5fabcd656b2ae6f625f512b1207b979488886fc","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"03dce75459e06842832ea1670a3b3c46e5b65de4","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"b782fe3f409eaaa22fcb6c87b2f86f2b417e94b1","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"3973e025ed583096894a0c98c3d4cf28018b7cc2","versionType":"git"},{"version":"9695ef876fd122cb7bbc04a4a93b8727d2e36bda","status":"affected","lessThan":"6d91353f6dbcc5c4fbb47bbd0c7f885453cfc939","versionType":"git"},{"version":"6.1.188","status":"affected","lessThan":"6.1.193","versionType":"semver"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/bluetooth/hci_sync.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.4","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.4","versionType":"semver"},{"version":"6.1.193","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.163","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.119","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.65","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.3.6","status":"unaffected","lessThanOrEqual":"7.3.*","versionType":"semver"},{"version":"7.4-rc1","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/bluetooth/hci_sync.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/265f3540b37a9452dce4fba99406c763fb7730c0"},{"url":"https://git.kernel.org/stable/c/a5fabcd656b2ae6f625f512b1207b979488886fc"},{"url":"https://git.kernel.org/stable/c/03dce75459e06842832ea1670a3b3c46e5b65de4"},{"url":"https://git.kernel.org/stable/c/b782fe3f409eaaa22fcb6c87b2f86f2b417e94b1"},{"url":"https://git.kernel.org/stable/c/3973e025ed583096894a0c98c3d4cf28018b7cc2"},{"url":"https://git.kernel.org/stable/c/6d91353f6dbcc5c4fbb47bbd0c7f885453cfc939"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-11-30T13:34:12.194Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.1.188","versionEndExcluding":"6.1.193"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.4","versionEndExcluding":"6.6.163"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.4","versionEndExcluding":"6.12.119"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.4","versionEndExcluding":"6.18.65"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.4","versionEndExcluding":"7.3.6"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.4","versionEndExcluding":"7.4-rc1"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}