Author Topic: Pairing using a default PIN  (Read 19484 times)

superpole

  • Guest
Pairing using a default PIN
« on: April 04, 2011, 04:31:15 PM »
Hello,
I brefely explain what I need, and I would know if it's possibile to do this with your library.

I'm developing an application for a standalone kiosk that manages images, which has a bluetooth dongle.
The need of my application it to receive images / videos from mobile phones.
With some phones, pairing is not needed: I just have to properly set security parameter of the bluetooth dongle driver software.
But, with the last generation phones, this is not enough, so I found that pairing is needed.
So here comes your lib.

See that in my app is "touch screen" (so no keyb is connected), what I would do is the following:
- tell the customer to set his phone to be discoverable
- launch a "discover" with your authenticator.
- the customer selects his device from a list that is filled from your lib.
- once he selects his device, a connect request is launched from your authenticator, with a default PIN (let's say, '0000')
- the customer is asked to digit 0000 on his phone
- once the device is connected, the customer can send images to my the kiosk.

I thought that this was possibile, but I'm encountering some problems because it seems that the default pin is not settable: so, a "driver" window appears on the kiosk, asking to set a pin for the connection.
Is there a workaround for this? Am I doing something wrong?

Thank you in advance
superpole

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Pairing using a default PIN
« Reply #1 on: April 04, 2011, 04:35:07 PM »
Hello,

It is possible and your thoughts are absolutely correct. The issue may appear becasue:

1. You didn't call wclAuthenticator.Open
2. Your application must run with administrative rights.

Also I think it could be better if you pair with device manualy by calling wclBluetoothDevice.Pair method with your default PIN. So after pairing is done (and you may check the result) you already know device's MAC and can accept only this MAC to receive content. I think it may be better.

superpole

  • Guest
Re: Pairing using a default PIN
« Reply #2 on: May 09, 2011, 12:00:40 PM »
Mike, thank you for your answer,
Everything is working in my "test" environment, with a toshiba stack and a conceptronic dongle: so pairing with a default PIN is possibile. :)
But, our customer has got a different scenario: even if it has a similar dongle (and same stack version), a random PIN is required. I investigated it, and in the security options of the stack, there are some additional options: SSP 2.1, MITM 2.1...
The first one is always checked (and uncheckable), so I think that this is something related to SSP.  ::)
Is there a particular procedure to implement the pairing also with these additional "security" improvements?  ???

Now, my code for the pairing is something like the following:

Code: [Select]

wcl.wclBluetoothRadio Radio = GetSelectedRadio();
wclAuthenticator1.Radio = Radio;
res = wclAuthenticator1.Open();
wcl.wclBluetoothDevice Device = new wcl.wclBluetoothDevice();
Device.Address = addr;
res = Device.Pair(Radio, "0000");

Thank you in advance

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Pairing using a default PIN
« Reply #3 on: May 10, 2011, 09:13:33 AM »
Hello,

Unfortunately no, there is no such methods. However, you may try to use wclAuthenticator.

superpole

  • Guest
Re: Pairing using a default PIN
« Reply #4 on: May 10, 2011, 03:36:45 PM »
Hello,
so, if I understand, the library is not compatible with dongles with edr or additional security protocols?

I'm now testing here my all stuff with a belkin (widcomm) dongle - model BCM-2046 B1 Bluetooth Us + EDR adapter class 2 v2.1 UHE
and I can reproduce our customer behaviour: so it's not possibile to connect to devices which require PIN (like Blackberry, samsung).

The error (making Pair) is Authentication failed.

Mike, at this point, what can I do? Do you expect to release an emprovement that allows to pair with "pin devices"?
Do you have any suggestion, like a list of working dongles that surely compatible with your library?
Thank you. 

superpole


Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Pairing using a default PIN
« Reply #5 on: May 10, 2011, 05:01:46 PM »
WCL knows nothing about hardware, EDR and other low-level things as it uses BT driver functions only.

WCL works perfect with Blackberry, Samsung or any other phone which require PIN. We have never had any problem with that. However, you must provide PIN for pairing.

What error is it?

We have no such list as WCL doesn't know about any hardware or dongle. It just knows about drivers.

superpole

  • Guest
Re: Pairing using a default PIN
« Reply #6 on: May 11, 2011, 10:54:24 AM »
Hello Mike,
the need it's clear.
What my app has to do (but I think that thisis a common issue), is to force a mobile device to be paired with the computer on which the app runs. I need this to allow the mobile device to send items to the computer.

So what I want to do is to Send a Pairing / Connect request to a specific address, with a default pin.

I wouldn't care about dongle/driver/etc. But I found that, for example, with a default microsoft bluetooth driver - widcom dongle (so, no security options available), this is possibile just with some phones (let's say, Nokia).

With other phones like Blackberry or Samsug, this is not possibile, because on the phone appear a message like: "does this Code correspond with the one on the computer screen? XXX XXX" The code is 6 digits long and I suppose it's generated by the driver, bypassing WCL request. Obviously, pairing is not possibile.

I just made this stuff work with one toshiba stack, disabling all the driver security Options, but I found that the drivers options depends from the hardware (my customer and I installed the same driver, but the behaviour is different due to a newer/more secure dongle).





Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Pairing using a default PIN
« Reply #7 on: May 11, 2011, 11:00:21 AM »
Hello,

Aha, now I got what you need exactly :) I have to check one thing first and then back to you with a better way to do what you need shortly.

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Pairing using a default PIN
« Reply #8 on: May 11, 2011, 06:37:13 PM »
Hello,

Please, find the attached demo which does what you described.

[attachment deleted by admin]

superpole

  • Guest
Re: Pairing using a default PIN
« Reply #9 on: May 11, 2011, 07:58:27 PM »
Thank you Mike,
I downloaded the demo. Tomorrow I'll check it better, but for the moment: what do I have to expect from that demo solution?
I tried the program, but nothing happens.
What I expected is a sort of program/service that discovers the mobile phones available, and launches a connection/pair request with a default pin.
This seems a bit different, but perhaps I'm missing something. But I would make it work before passing from Personal to developer profile.
Thank you in advance

superpole

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Pairing using a default PIN
« Reply #10 on: May 11, 2011, 08:26:55 PM »
As you wrote mobile should send content to PC and pair before with default PIN.

Quote
I need this to allow the mobile device to send items to the computer.

This is exactly what application does. It waits for mobile connection and pairs with it before receives content.

superpole

  • Guest
Re: Pairing using a default PIN
« Reply #11 on: May 12, 2011, 01:34:27 PM »
Hello Mike,

I'm trying the demo. It works with Nokia (it correctly asks for a PiN. default 0000), but doesn't work with  Blackberry and samgung.
In these cases, a 6 digits password is shown by the phone, and connection is not possibile.
So the program probably doesn't listen to that kind of connections, that are taken by the driver.
Any other suggestion?  ???
Thanks

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Pairing using a default PIN
« Reply #12 on: May 12, 2011, 03:37:43 PM »
All works perfect. tested with BlackBerry 9500.

First, you have to add device into blackberry bluetooth devices list (and pair with it). Pairing works great and hanled by application without any issue (Tested with MS on Win 7 and WidComm on Win XP).
Then you can select file and send to this paired PC - works great too and no one dialog is appears. The same with samsung.

superpole

  • Guest
Re: Pairing using a default PIN
« Reply #13 on: May 13, 2011, 09:58:44 AM »
Hello Mike,

it's still not working.  :-\ I'm trying on:
- win 7 64Bit - baMicrosoft
- winXP sp3 - baWidComm

with Blackberry 8520 / Samsung
The behaviour is always the same: from the mobile phone, once I try to add the "computer" to my device list, I'm not asked to insert the default pin, but a random 6 digits pin is prompted.

The pairing procedure works with an old nokia (correct PIN prompted) but it's not possibile to "directly"  send images / elements without confirmation. The driver catches it and a ballon appears to ask "Access request to transfer PIM elements": after a manual confirmation, it's possibile to send the image.

The only thing it that now I have a Personal License. I downloaded the Developer demo and I'm using it for the test. I don't know if it has any restictions.
Thanks for the support. i hope that there is a solution.


Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Pairing using a default PIN
« Reply #14 on: May 13, 2011, 10:10:48 AM »
Well, it looks like on both system runs WidComm (on Win 7 it runs as MS extention). WidComm has its own OPP Server which handles all the send requests. So you must disable its server first (before running the application).

Server (used in my demo) is available only in Developer License.

Also, make sure that you run application with administrative rights, otherwise it couldn't call some functions (it has to make some changes in system registry to catch authentication requests with MS driver).

Any way, it does look very strage so i'm going to buy same dongle as your one and do more tests with it. I think today evening I will have something for you.

 

Sitemap 1 2 3 4 5 6 7