aboutsummaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorLukasz Rymanowski <lukasz.rymanowski@tieto.com>2011-03-01 10:44:21 +0100
committerJonas ABERG <jonas.aberg@stericsson.com>2011-03-03 15:15:16 +0100
commitbb1f123edc1f2351756c4c2615793433fb6b93b2 (patch)
treeaf7629deec078ca925afe8d8ee36cbf49bddbf2f /net
parent71a6f6a578c2f2a6d2246fc1edee5248e6383b20 (diff)
BT: Force MITM on BT_SECURITY_HIGH level.
This patch fixes scenario when it is possible to connect socket which requires MITM, without MITM. ST-Ericsson ID: 326071 ST-Ericcson FOSS-OUT-ID: Trivial ST-Ericsson Linux next: 274079 Depends-On: I8ff3fe6dfb7d9a4e537abb87a10932a0cd209ff9 Change-Id: I9b07e684efbe5c35bccbe7bae39c5b4126f546cf Signed-off-by: Lukasz Rymanowski <lukasz.rymanowski@tieto.com> Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/17247 Reviewed-by: Henrik POSSUNG <henrik.possung@stericsson.com> Tested-by: Lukasz RYMANOWSKI <lukasz.rymanowski@stericsson.com> Reviewed-by: Par-Gunnar HJALMDAHL <par-gunnar.p.hjalmdahl@stericsson.com>
Diffstat (limited to 'net')
-rw-r--r--net/bluetooth/hci_conn.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c
index 9a2b003e2bb..c009fa4c4a2 100644
--- a/net/bluetooth/hci_conn.c
+++ b/net/bluetooth/hci_conn.c
@@ -502,7 +502,7 @@ int hci_conn_security(struct hci_conn *conn, __u8 sec_level, __u8 auth_type)
/* An unauthenticated combination key has sufficient security for
any security level other than max (for SAP) */
if (conn->key_type == HCI_LK_UNAUTHENTICATED_COMBINATION
- && sec_level != BT_SECURITY_MAX)
+ && sec_level < BT_SECURITY_HIGH)
goto do_encrypt;
/* For max security, combination key should be generated using