Auto-Pairing for Bluetooth PAN clients

I have setup a Bluetooth Network PAN via Blueman's Local ServicesNetwork that looks like this:

local services

However whenever I pair a device to my Ubuntu box so that it can share its network connection, I have to manually confirm the pairing like so:

confirmation dialog 1

On the Phone I'll see a dialog that states:

Bluetooth Pairing Request
"Ubuntu Box" would like to pair with your
iPhone. Confirm that this code is
displayed on "Ubuntu Box". 127459

After which, a set of "accept/deny" notifications pop up on my Ubuntu box which goes one-by-one through the capabilities that should be granted to the iPhone, BNEP being the networking capability, but I'm also asked about Audio sharing:

confirmation dialog 2

Question

I would like to know if it's possible to configure Ubuntu such that when any device (not just my iPhone) pairs with my Ubuntu box, it is automatically paired/trusted and that all capabilities are granted to it without my interaction. This box is in my home, and I want to auto-pair out of convenience for setting up a local network.

1

1 Answer

The trick was to run my own auth agent, here's what I did:

  1. First I disabled the AuthAgent plugin in Blueman (Bluetooth tray icon -> Plugins -> AuthAgent (uncheck))

Auth Agent GUI

  1. sudo apt-get install bluez-tools

  2. bt-agent --capability=NoInputNoOutput

After that, I was able to pair and connect without any confirmation on the Ubuntu Box

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like