Hi Sven
Sorry for the delay.
The Bluetooth Core Specification basically defines the following security levels: non encrypted, encrypted, authenticated, and authorized. Authorized is a bit vague in my view. Authentication already means that the devices have bonded with man-in-the-middle protection.
Authorization then means that a human has agreed that something happens. We've implemented something along this lines. If you declare a Characteristic as "Requires Authorization", BTstack will send the SM_EVENT_AUTHORIZATION_REQUEST event, which then need to be approved by the application. This happens on each new re-connect even though a secure pairing has happened before. That's the theory, I'm not aware of anybody using this in BTstack or have seen this in other customer devices.
As for your pairing procedure. As your setup does not provide any MITM protection, I would suggest to use IO_CAPABILITY_NO_INPUT_NO_OUTPUT which will result in Just Works pairing. You can then call sm_just_works_confirm if the user presses the button (as you've suggested).
Cheers
Matthias
> --
> You received this message because you are subscribed to the Google Groups "btstack-dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
btstack-dev...@googlegroups.com.
> To view this discussion visit
https://groups.google.com/d/msgid/btstack-dev/eba4b8e7-3cdb-427e-a759-44aa7e2242dbn%40googlegroups.com.