diff options
author | Johan Hedberg <johan.hedberg@intel.com> | 2014-06-10 02:54:24 -0400 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2014-06-13 07:30:39 -0400 |
commit | e694788d73efe139b24f78b036deb97fe57fa8cb (patch) | |
tree | 816dc5b0dc807a57d9e9baf7fbf25d6d0cbb9cf0 /drivers/parisc/lasi.c | |
parent | b62b65055bcc5372d5c3f4103629176cb8db3678 (diff) |
Bluetooth: Fix check for connection encryption
The conn->link_key variable tracks the type of link key in use. It is
set whenever we respond to a link key request as well as when we get a
link key notification event.
These two events do not however always guarantee that encryption is
enabled: getting a link key request and responding to it may only mean
that the remote side has requested authentication but not encryption. On
the other hand, the encrypt change event is a certain guarantee that
encryption is enabled. The real encryption state is already tracked in
the conn->link_mode variable through the HCI_LM_ENCRYPT bit.
This patch fixes a check for encryption in the hci_conn_auth function to
use the proper conn->link_mode value and thereby eliminates the chance
of a false positive result.
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Cc: stable@vger.kernel.org
Diffstat (limited to 'drivers/parisc/lasi.c')
0 files changed, 0 insertions, 0 deletions