Linux bluetooth development
 help / color / mirror / Atom feed
From: Johan Hedberg <johan.hedberg@gmail.com>
To: Waldemar Rymarkiewicz <waldemar.rymarkiewicz@tieto.com>
Cc: linux-bluetooth@vger.kernel.org, padovan@profusion.mobi
Subject: Re: [PATCH v2 6/6] Bluetooth: Respect local MITM req in io_cap reply
Date: Thu, 21 Apr 2011 11:10:48 +0300	[thread overview]
Message-ID: <20110421081048.GA23120@jh-x301> (raw)
In-Reply-To: <1303372461-11848-6-git-send-email-waldemar.rymarkiewicz@tieto.com>

Hi Waldek,

On Thu, Apr 21, 2011, Waldemar Rymarkiewicz wrote:
> If host requires MITM protection notify that to controller in
> io capabilities reply even if the remote device requires no bonding.
> 
> If it is not respected, host can get an unauthenticated link key while
> it expects authenticated one.
> 
> Signed-off-by: Waldemar Rymarkiewicz <waldemar.rymarkiewicz@tieto.com>
> ---
>  net/bluetooth/hci_event.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/net/bluetooth/hci_event.c b/net/bluetooth/hci_event.c
> index 087953e..3ee0060 100644
> --- a/net/bluetooth/hci_event.c
> +++ b/net/bluetooth/hci_event.c
> @@ -2369,7 +2369,7 @@ static inline u8 hci_get_auth_req(struct hci_conn *conn)
>  
>  	/* If remote requests no-bonding follow that lead */
>  	if (conn->remote_auth == 0x00 || conn->remote_auth == 0x01)
> -		return 0x00;
> +		return conn->auth_type & 0x01;
>  
>  	return conn->auth_type;
>  }

Your other patches seem ok to me, but have you verified this one with
the BITE tester? This logic is directly copied from how it is in user
space right now and that's something we have arrived at after multiple
iterations with the BITE tester over the last few years. So I'd be very
careful when changing it.

Johan

  reply	other threads:[~2011-04-21  8:10 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-21  7:54 [PATCH v2 1/6] Bluetooth: Add definitions for link key types Waldemar Rymarkiewicz
2011-04-21  7:54 ` [PATCH v2 2/6] Bluetooth: Don't modify sec_level if auth failed Waldemar Rymarkiewicz
2011-04-21  7:54 ` [PATCH v2 3/6] Bluetooth: Map sec_level to link key requirements Waldemar Rymarkiewicz
2011-04-21 10:02   ` Waldemar.Rymarkiewicz
2011-04-21  7:54 ` [PATCH v2 4/6] Bluetooth: Ignore key unauthenticated for high security Waldemar Rymarkiewicz
2011-04-21  7:54 ` [PATCH v2 5/6] Bluetooth: Double check sec req for pre 2.1 device Waldemar Rymarkiewicz
2011-04-21  9:53   ` Waldemar.Rymarkiewicz
2011-04-21  7:54 ` [PATCH v2 6/6] Bluetooth: Respect local MITM req in io_cap reply Waldemar Rymarkiewicz
2011-04-21  8:10   ` Johan Hedberg [this message]
2011-04-21  8:24     ` Waldemar.Rymarkiewicz
2011-04-25 17:09       ` Luiz Augusto von Dentz
2011-04-26 23:59   ` Johan Hedberg
2011-04-27 23:09   ` [PATCH] " johan.hedberg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110421081048.GA23120@jh-x301 \
    --to=johan.hedberg@gmail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=padovan@profusion.mobi \
    --cc=waldemar.rymarkiewicz@tieto.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox