]> git.baikalelectronics.ru Git - kernel.git/commit
Bluetooth: Delay check for conn->smp in smp_conn_security()
authorJohan Hedberg <johan.hedberg@intel.com>
Fri, 4 Sep 2015 09:22:46 +0000 (12:22 +0300)
committerMarcel Holtmann <marcel@holtmann.org>
Thu, 17 Sep 2015 10:28:27 +0000 (12:28 +0200)
commit2d5a0e7e996bae4adcd672da625fcf636866681a
tree3f3f0b3c775621eef856097a6c5ef7847452f502
parent3822fbfc08902b9361424d964569cca5abc9b62a
Bluetooth: Delay check for conn->smp in smp_conn_security()

There are several actions that smp_conn_security() might make that do
not require a valid SMP context (conn->smp pointer). One of these
actions is to encrypt the link with an existing LTK. If the SMP
context wasn't initialized properly we should still allow the
independent actions to be done, i.e. the check for the context should
only be done at the last possible moment.

Reported-by: Chuck Ebbert <cebbert.lkml@gmail.com>
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Cc: stable@vger.kernel.org # 4.0+
net/bluetooth/smp.c