mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-06 06:21:31 +00:00
Bluetooth: Allow 3D profile to use security mode 4 level 0
The PSM 0x0021 is dedicated to the 3D profile and has permission to use security mode 4 level 0 for L2CAP connectionless unicast data transfers. When establishing a L2CAP connectionless channel on PSM 0x0021, it will no longer force Secure Simple Pairing. Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This commit is contained in:
parent
6a974b50a1
commit
3124b84309
3 changed files with 15 additions and 0 deletions
|
@ -688,6 +688,16 @@ static inline u8 l2cap_get_auth_type(struct l2cap_chan *chan)
|
|||
return HCI_AT_NO_BONDING;
|
||||
}
|
||||
break;
|
||||
case L2CAP_CHAN_CONN_LESS:
|
||||
if (chan->psm == __constant_cpu_to_le16(L2CAP_PSM_3DSP)) {
|
||||
if (chan->sec_level == BT_SECURITY_LOW)
|
||||
chan->sec_level = BT_SECURITY_SDP;
|
||||
}
|
||||
if (chan->sec_level == BT_SECURITY_HIGH)
|
||||
return HCI_AT_NO_BONDING_MITM;
|
||||
else
|
||||
return HCI_AT_NO_BONDING;
|
||||
break;
|
||||
case L2CAP_CHAN_CONN_ORIENTED:
|
||||
if (chan->psm == __constant_cpu_to_le16(L2CAP_PSM_SDP)) {
|
||||
if (chan->sec_level == BT_SECURITY_LOW)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue