# CVE-2024-36012: Bluetooth: msft: fix slab-use-after-free in msft_do_close()

- Severity: High 7.8 (CVSS:3.1, scored by Linux) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.21%, higher than 12% of CVEs (2026-12-01)
- Published: 2024-05-23T07:03:06.904Z
- Modified: 2026-08-05T11:31:34.945Z
- Weaknesses: CWE-416
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: Linux

## Description

In the Linux kernel, the following vulnerability has been resolved:

Bluetooth: msft: fix slab-use-after-free in msft_do_close()

Tying the msft->data lifetime to hdev by freeing it in
hci_release_dev() to fix the following case:

[use]
msft_do_close()
  msft = hdev->msft_data;
  if (!msft)                      ...(1) <- passed.
    return;
  mutex_lock(&msft->filter_lock); ...(4) <- used after freed.

[free]
msft_unregister()
  msft = hdev->msft_data;
  hdev->msft_data = NULL;         ...(2)
  kfree(msft);                    ...(3) <- msft is freed.

==================================================================
BUG: KASAN: slab-use-after-free in __mutex_lock_common
kernel/locking/mutex.c:587 [inline]
BUG: KASAN: slab-use-after-free in __mutex_lock+0x8f/0xc30
kernel/locking/mutex.c:752
Read of size 8 at addr ffff888106cbbca8 by task kworker/u5:2/309

(As written by CVE List.)

## Affected

- Linux Linux: from bf6a4e30ffbd9e9ef8934582feb937f6532f8b68 before e3880b531b68f98d3941d83f2f6dd11cf4fd6b76; from bf6a4e30ffbd9e9ef8934582feb937f6532f8b68 before a85a60e62355e3bf4802dead7938966824b23940; from bf6a4e30ffbd9e9ef8934582feb937f6532f8b68 before 4f1de02de07748da80a8178879bc7a1df37fdf56; from bf6a4e30ffbd9e9ef8934582feb937f6532f8b68 before 10f9f426ac6e752c8d87bf4346930ba347aaabac; 5.12 (not affected: before 5.12; from 6.1.91 up to 6.1.*; from 6.6.31 up to 6.6.*; from 6.8.10 up to 6.8.*; from 6.9 up to *)
- linux linux_kernel: from 5.12 before 6.1.91; from 6.2 before 6.6.31; from 6.7 before 6.8.10; 6.9

## Every score

- Linux: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`

## References

- <https://git.kernel.org/stable/c/e3880b531b68f98d3941d83f2f6dd11cf4fd6b76> (patch)
- <https://git.kernel.org/stable/c/a85a60e62355e3bf4802dead7938966824b23940> (patch)
- <https://git.kernel.org/stable/c/4f1de02de07748da80a8178879bc7a1df37fdf56> (patch)
- <https://git.kernel.org/stable/c/10f9f426ac6e752c8d87bf4346930ba347aaabac> (patch)

## Sources

- CVE List: [CVE-2024-36012](https://www.cve.org/CVERecord?id=CVE-2024-36012), CVE Terms of Use, modified 2026-08-05
- NVD: [CVE-2024-36012](https://nvd.nist.gov/vuln/detail/CVE-2024-36012), Public domain, modified 2026-08-04

---

Page: https://cve.day/CVE-2024-36012 · Whole record: https://cve.day/CVE-2024-36012.json · Rebuilt by cve.day 2026-11-25T22:58:40.754Z
