Bluetooth: hci_bcsp: validate received packet lengths

The BCSP transmit path reads an HCI command header when an extension
packet has only been tested for a nonzero length. Its LE configuration
packet handler also indexes bytes through offset seven without a length
check.

Validate the complete command and LE configuration packet headers
before accessing their fields.

Signed-off-by: Li Qiang <liqiang01@kylinos.cn>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
This commit is contained in:
Li Qiang 2026-07-16 16:47:30 +08:00 • committed by Luiz Augusto von Dentz
commit ceea75ad89