]> git.baikalelectronics.ru Git - kernel.git/commit
Bluetooth: Add key preference parameter to smp_sufficient_security
authorJohan Hedberg <johan.hedberg@intel.com>
Thu, 13 Nov 2014 08:55:18 +0000 (10:55 +0200)
committerMarcel Holtmann <marcel@holtmann.org>
Sat, 15 Nov 2014 00:46:49 +0000 (01:46 +0100)
commit502319add0cb545bed74a38a3ba33d2e77df60b6
tree24b259e7c459dd1a6f75bd79c572e5e5560ef975
parent4cad24467d0fffe5fd58a2c9fe33cb05e8e75b75
Bluetooth: Add key preference parameter to smp_sufficient_security

So far smp_sufficient_security() has returned false if we're encrypted
with an STK but do have an LTK available. However, for the sake of LE
CoC servers we do want to let the incoming connection through even
though we're only encrypted with the STK.

This patch adds a key preference parameter to smp_sufficient_security()
with two possible values (enum used instead of bool for readability).

Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
net/bluetooth/l2cap_core.c
net/bluetooth/smp.c
net/bluetooth/smp.h