CVE-2025-37918
JSON

8.8high

Bluetooth: btusb: avoid NULL pointer dereference in skb_dequeue()

Severity
8.8high CVSS:3.1 by Linux
Exploit likelihood
0.25% (higher than 17% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
Linux

Description

In the Linux kernel, the following vulnerability has been resolved: Bluetooth: btusb: avoid NULL pointer dereference in skb_dequeue() A NULL pointer dereference can occur in skb_dequeue() when processing a QCA firmware crash dump on WCN7851 (0489:e0f3). [ 93.672166] Bluetooth: hci0: ACL memdump size(589824) [ 93.672475] BUG: kernel NULL pointer dereference, address: 0000000000000008 [ 93.672517] Workqueue: hci0 hci_devcd_rx [bluetooth] [ 93.672598] RIP: 0010:skb_dequeue+0x50/0x80 The issue stems from handle_dump_pkt_qca() returning 0 even when a dump packet is successfully processed. This is because it incorrectly forwards the return value of hci_devcd_init() (which returns 0 on success). As a result, the caller (btusb_recv_acl_qca() or btusb_recv_evt_qca()) assumes the packet was not handled and passes it to hci_recv_frame(), leading to premature kfree() of the skb. Later, hci_devcd_rx() attempts to dequeue the same skb from the dump queue, resulting in a NULL pointer dereference. Fix this by: 1. Making handle_dump_pkt_qca() return 0 on success and negative errno on failure, consistent with kernel conventions. 2. Splitting dump packet detection into separate functions for ACL and event packets for better structure and readability. This ensures dump packets are properly identified and consumed, avoiding double handling and preventing NULL pointer access.

Affected

Product or packageVersionsReported by
Linux Linuxfrom 20981ce2d5a5f79d17da1ace3a93df7b3c6ba3d6 before 2e8d44ebaa7babdd5c5ab50ca275826e241920d6, from 20981ce2d5a5f79d17da1ace3a93df7b3c6ba3d6 before b70b41591ec48c78ec6a885e1f57bfc4029e5e13, from 20981ce2d5a5f79d17da1ace3a93df7b3c6ba3d6 before 8563d9fabd8a4b726ba7acab4737c438bf11a059, from 20981ce2d5a5f79d17da1ace3a93df7b3c6ba3d6 before 0317b033abcd1d8dd2798f0e2de5e84543d0bd22, 6.4
Not affected: before 6.4, from 6.6.90 up to 6.6.*, from 6.12.28 up to 6.12.*, from 6.14.6 up to 6.14.*, from 6.15 up to *
CVE List
linux linux_kernelfrom 6.4 before 6.6.90, from 6.7 before 6.12.28, from 6.13 before 6.14.6, 6.15NVD

All scores

Linux8.8high CVSS:3.1CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
NVD5.5medium CVSS:3.1CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Classification

CWE-476

SSVC (CISA-ADP): exploitation none, automatable no, technical impact total.

What each source says

CVE List

In the Linux kernel, the following vulnerability has been resolved: Bluetooth: btusb: avoid NULL pointer dereference in skb_dequeue() A NULL pointer dereference can occur in skb_dequeue() when processing a QCA firmware crash dump on WCN7851 (0489:e0f3). [ 93.672166] Bluetooth: hci0: ACL memdump size(589824) [ 93.672475] BUG: kernel NULL pointer dereference, address: 0000000000000008 [ 93.672517] Workqueue: hci0 hci_devcd_rx [bluetooth] [ 93.672598] RIP: 0010:skb_dequeue+0x50/0x80 The issue stems from handle_dump_pkt_qca() returning 0 even when a dump packet is successfully processed. This is because it incorrectly forwards the return value of hci_devcd_init() (which returns 0 on success). As a result, the caller (btusb_recv_acl_qca() or btusb_recv_evt_qca()) assumes the packet was not handled and passes it to hci_recv_frame(), leading to premature kfree() of the skb. Later, hci_devcd_rx() attempts to dequeue the same skb from the dump queue, resulting in a NULL pointer dereference. Fix this by: 1. Making handle_dump_pkt_qca() return 0 on success and negative errno on failure, consistent with kernel conventions. 2. Splitting dump packet detection into separate functions for ACL and event packets for better structure and readability. This ensures dump packets are properly identified and consumed, avoiding double handling and preventing NULL pointer access.

NVD (es)

En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: Bluetooth: btusb: evitar la desreferencia de puntero NULL en skb_dequeue() Una desreferencia de puntero NULL puede ocurrir en skb_dequeue() cuando se procesa un volcado de memoria de firmware QCA en WCN7851 (0489:e0f3). [ 93.672166] Bluetooth: hci0: tamaño de volcado de memoria ACL (589824) [ 93.672475] ERROR: Desreferencia de puntero nulo del kernel, dirección: 0000000000000008 [ 93.672517] Cola de trabajo: hci0 hci_devcd_rx [bluetooth] [ 93.672598] RIP: 0010:skb_dequeue+0x50/0x80. El problema se debe a que handle_dump_pkt_qca() devuelve 0 incluso cuando un paquete de volcado se procesa correctamente. Esto se debe a que reenvía incorrectamente el valor de retorno de hci_devcd_init() (que devuelve 0 en caso de éxito). Como resultado, el llamador (btusb_recv_acl_qca() o btusb_recv_evt_qca()) asume que el paquete no fue procesado y lo pasa a hci_recv_frame(), lo que provoca un kfree() prematuro del skb. Posteriormente, hci_devcd_rx() intenta retirar el mismo skb de la cola de volcado, lo que resulta en una desreferencia de puntero nulo. Para solucionar esto: 1. Hacer que handle_dump_pkt_qca() devuelva 0 en caso de éxito y errno negativo en caso de error, de acuerdo con las convenciones del kernel. 2. Dividir la detección de paquetes de volcado en funciones independientes para ACL y paquetes de eventos para una mejor estructura y legibilidad. Esto garantiza que los paquetes de volcado se identifiquen y consuman correctamente, evitando el doble manejo y el acceso a punteros nulos.

References

Sources

SourceRecordLicence
CVE ListCVE-2025-37918 changed 2026-10-15CVE Terms of Use
NVDCVE-2025-37918 changed 2026-10-15Public domain