Bluetooth: L2CAP: Fix possible crash on l2cap_ecred_conn_rsp
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 15f02b91056253e8cdc592888f431da0731337b8 · < 41e29548b5e8b5e5fcf708786b3bea67cab107fa| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
Bluetooth: L2CAP: Fix possible crash on l2cap_ecred_conn_rsp
If dcid is received for an already-assigned destination CID the spec requires that both channels to be discarded, but calling l2cap_chan_del may invalidate the tmp cursor created by list_for_each_entry_safe and in fact it is the wrong procedure as the chan->dcid may be assigned previously it really needs to be disconnected.
Calling l2cap_chan_clone directly may still lead to l2cap_chan_del so instead schedule l2cap_chan_timeout with delay 0 to close the channel asynchronously.
From the CVE record · Linux
The Linux kernel's Bluetooth L2CAP handling can crash when a connection response contains a destination CID that is already assigned. The input does not specify whether an attacker needs authentication or user interaction to trigger this condition.
Engineers running Linux kernels with Bluetooth L2CAP should check whether their versions are affected; affected versions are not specified.