Bluetooth: virtio_bt: avoid OOB read of build info string
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ afd2daa26c7abd734d78bd274fc6c59a15e61063 · < 84ea9c99874804f5ca13f35bbc186ba93902f30f| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
Bluetooth: virtio_bt: avoid OOB read of build info string
The virtbt_setup_zephyr() sends the Zephyr vendor command 0xfc08 (Read Build Information) and hands the response to bt_dev_info() and hci_set_fw_info() as a "%s" string starting at skb->data + 1, without checking the length. A backend that answers with status only leaves that pointer past the end of the received data, so the walk reads adjacent slab memory until it meets a NUL. Those bytes reach the kernel log and the firmware-info debugfs file.
To fix this, print the string with a bounded "%.*s" limited to skb->len - 1. A short or unterminated response then prints as much as arrived instead of failing setup.
This mirrors commit dd068ef04412 ("Bluetooth: bpa10x: avoid OOB read of revision string in bpa10x_setup()"), which fixed the identical pattern.
From the CVE record · Linux
The Linux kernel’s Bluetooth virtio_bt driver reads a Zephyr build-information response as an unbounded string. If a backend returns only a status byte, the driver can read adjacent slab memory and expose it in the kernel log and firmware-info debugfs file. The input does not specify authentication or user-interaction requirements.
Engineers running Linux kernels with the Bluetooth virtio_bt driver should check whether their kernel includes the fix; affected versions are not specified.