From 91ee7498214310b04b0d70d0016dfd3804dd64ae Mon Sep 17 00:00:00 2001 From: Marcel Holtmann Date: Thu, 15 Jan 2009 23:47:50 +0100 Subject: Use dedicated bonding and no MITM for pairing --- src/dbus-hci.c | 5 +---- src/device.c | 2 +- 2 files changed, 2 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/dbus-hci.c b/src/dbus-hci.c index d4dc1537..994e25cc 100644 --- a/src/dbus-hci.c +++ b/src/dbus-hci.c @@ -1252,10 +1252,7 @@ int hcid_dbus_get_io_cap(bdaddr_t *local, bdaddr_t *remote, /* For CreatePairedDevice use dedicated bonding */ agent = device_get_agent(device); - if (agent) { - debug("Pairing attempt, use dedicated bonding without MITM"); - *auth = 0x02; - } else + if (!agent) agent = adapter_get_agent(adapter); if (!agent) { diff --git a/src/device.c b/src/device.c index 02077f94..deb63645 100644 --- a/src/device.c +++ b/src/device.c @@ -1706,7 +1706,7 @@ static int l2raw_connect(const bdaddr_t *src, const bdaddr_t *dst, } memset(&sec, 0, sizeof(sec)); - sec.level = BT_SECURITY_HIGH; + sec.level = BT_SECURITY_MEDIUM; err = setsockopt(sk, SOL_BLUETOOTH, BT_SECURITY, &sec, sizeof(sec)); if (auth_required) -- cgit