-
Notifications
You must be signed in to change notification settings - Fork 6.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CSIS: Invalid usage of bt_conn_auth_cb callbacks #42928
Comments
@Thalley please assign the "Bluetooth LE Audio" project, seems I do not have sufficient permissions to assign project |
With the current implementation of I wonder if it would be possible to allow multiple registrations of |
If the bond is removed, the ACL link is disconnected. So the only need is to check whether bt_addr_le_is_bonded on bt_conn_cb->connected callback and register for bt_conn_cb->security_changed callback |
CSIS also needs to know when security with bonding is finished, as there is a requirement to send notifications when that happens. For this purpose, CSIS also needs to know when a bond has been removed (which it may be after disconnection). |
Please add "Bluetooth" as a label aside from "Bluetooth Audio" |
@jhedberg @joerchan Do you know/remember why only a single instance of It does have some sense for the majority of the callbacks where the host asks for acceptance from the register, but for the informational callbacks ( We can split up the callback structure between functional and informational callbacks, or allow multiple registers. The security failed/complete is all that necessary as you can get the same information from I do have an alternative to using the |
@Thalley yes, the original reasoning is that it needs to be clear who answers to the callbacks that solicit a response. I'm fine with splitting this up so that informational callbacks are separate (and can be registered multiple times) |
The current CSIS implementation registers authentication callbacks. Those callbacks are used to handle authentication pairing requests. There can be only one instance of registered callbacks, thus the one shall be registered by application that handles pairing and csis.c is not the one.
Once the CSIS registers the callbacks, the callbacks cannot be further registered in any other place, as -ALREADY error is returned.
The only callbacks handled in csis.c are pairing_complete and bond_deleted which disables support for authenticated pairing in the system.
The text was updated successfully, but these errors were encountered: