public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Local out of band properties
@ 2009-10-26 22:04 Claudio Takahasi
  2009-10-27 12:42 ` Bastien Nocera
  0 siblings, 1 reply; 3+ messages in thread
From: Claudio Takahasi @ 2009-10-26 22:04 UTC (permalink / raw)
  To: BlueZ development

Hi,

this is the first step to support secure simple pairing using out of
band mechanism(NFC, USB, ..).

First it is necessary export to applications a method to retrieve the data
that will be exchanged using out of band mechanism. "Hash" and "Randomizer"
properties were added in GetProperties method and PropertyChanged signal.

git://git.infradead.org/users/cktakahasi/bluez.git oob-local

Comments? Useless for now?



The second part of oob is set the exchanged oob data in the device struct
and reply the oob data when the host controller sends "Remote OOB Data
Request Event".

Initial proposal is here:
git://git.infradead.org/users/cktakahasi/bluez.git  oob-remote
It works, but we need to discuss the API.

Regards,
krau
-- 
--
Claudio Takahasi
Instituto Nokia de Tecnologia
Recife - Pernambuco - Brasil
+55 81 30879999

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Local out of band properties
  2009-10-26 22:04 [PATCH] Local out of band properties Claudio Takahasi
@ 2009-10-27 12:42 ` Bastien Nocera
  2009-10-27 13:45   ` Claudio Takahasi
  0 siblings, 1 reply; 3+ messages in thread
From: Bastien Nocera @ 2009-10-27 12:42 UTC (permalink / raw)
  To: Claudio Takahasi; +Cc: BlueZ development

On Mon, 2009-10-26 at 20:04 -0200, Claudio Takahasi wrote:
> Hi,
> 
> this is the first step to support secure simple pairing using out of
> band mechanism(NFC, USB, ..).
> 
> First it is necessary export to applications a method to retrieve the data
> that will be exchanged using out of band mechanism. "Hash" and "Randomizer"
> properties were added in GetProperties method and PropertyChanged signal.
> 
> git://git.infradead.org/users/cktakahasi/bluez.git oob-local
> 
> Comments? Useless for now?
> 
> 
> 
> The second part of oob is set the exchanged oob data in the device struct
> and reply the oob data when the host controller sends "Remote OOB Data
> Request Event".
> 
> Initial proposal is here:
> git://git.infradead.org/users/cktakahasi/bluez.git  oob-remote
> It works, but we need to discuss the API.

http://git.infradead.org/users/cktakahasi/bluez.git/blobdiff/ece9ea1c2e50697ed9b57fb53ff681d20b317610..d8a359f5e90879468ec1291961f9f60c62a52ac2:/doc/adapter-api.txt
Same typo in both descriptions.

Is there any way to request that the adapter refresh the
hash/randomizer, or would that happen automatically when the data is
actually used?

Also, can the values be used independently of each other? In that case,
it might make sense to have them both concatenated inside a one and only
property.

Finally, as you say you've tested this, which hardware did you use for
testing? I know about the Nokia 6212 with NFC, but couldn't find a
suitable NFC reader to go with it.

Cheers



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] Local out of band properties
  2009-10-27 12:42 ` Bastien Nocera
@ 2009-10-27 13:45   ` Claudio Takahasi
  0 siblings, 0 replies; 3+ messages in thread
From: Claudio Takahasi @ 2009-10-27 13:45 UTC (permalink / raw)
  To: Bastien Nocera; +Cc: BlueZ development

On Tue, Oct 27, 2009 at 10:42 AM, Bastien Nocera <hadess@hadess.net> wrote:
> On Mon, 2009-10-26 at 20:04 -0200, Claudio Takahasi wrote:
>> Hi,
>>
>> this is the first step to support secure simple pairing using out of
>> band mechanism(NFC, USB, ..).
>>
>> First it is necessary export to applications a method to retrieve the data
>> that will be exchanged using out of band mechanism. "Hash" and "Randomizer"
>> properties were added in GetProperties method and PropertyChanged signal.
>>
>> git://git.infradead.org/users/cktakahasi/bluez.git oob-local
>>
>> Comments? Useless for now?
>>
>>
>>
>> The second part of oob is set the exchanged oob data in the device struct
>> and reply the oob data when the host controller sends "Remote OOB Data
>> Request Event".
>>
>> Initial proposal is here:
>> git://git.infradead.org/users/cktakahasi/bluez.git  oob-remote
>> It works, but we need to discuss the API.
>
> http://git.infradead.org/users/cktakahasi/bluez.git/blobdiff/ece9ea1c2e50697ed9b57fb53ff681d20b317610..d8a359f5e90879468ec1291961f9f60c62a52ac2:/doc/adapter-api.txt
> Same typo in both descriptions.
>
> Is there any way to request that the adapter refresh the
> hash/randomizer, or would that happen automatically when the data is
> actually used?
>
> Also, can the values be used independently of each other? In that case,
> it might make sense to have them both concatenated inside a one and only
> property.
>
> Finally, as you say you've tested this, which hardware did you use for
> testing? I know about the Nokia 6212 with NFC, but couldn't find a
> suitable NFC reader to go with it.
>
> Cheers
>
>
>

Hi Bastien,

I agree, both contains the same description we can concatenate in one
property only.
Both values are used in the "Remote OOB Data Request Reply Command" only.

>From BT spec:
" Note: Each OOB transfer will have unique C and R values so after each OOB
transfer this command shall be used to obtain a new set of values for the next
OOB transfer."

Currently, I am not updating hash and randomizer automatically, it is
necessary run  "hciconfig -a hci0 oobdata".
An approach to update it automatically can be  call "Read Local OOB
Data Command" after "Remote OOB Data Request Event". If the remote oob
data is present "Remote OOB Data Request Reply Command" will be used
to notify the Host controller, it also means that the LOCAL oob data
will be used and a new value must be set for the next OOB transfer. At
the moment, I am not sure if it is correct update the local OOB data
immediately or  if it is necessary wait for link key event to avoid
some race condition.

I have only one NXP PN533 board, I wish I had two to test real peer to
peer transfer instead of peer<->tag.
For initial tests I developed a python script, but it is necessary to
type the oob data on both sides :-P

Cheers,
krau

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-10-27 13:45 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-10-26 22:04 [PATCH] Local out of band properties Claudio Takahasi
2009-10-27 12:42 ` Bastien Nocera
2009-10-27 13:45   ` Claudio Takahasi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox