PropertyID.BtSilentPairingWhitelistingEnable Field |
By reducing the need for user interaction for trusted devices, the SDK streamlines the user experience while maintaining security protocols for all other devices.
How It Works:
When an external device attempts to pair with the mobile device using Bluetooth, Android typically prompts the user to confirm the connection thought several steps. However, with Bluetooth Silent Pairing mechanism, developers can preemptively whitelist one or more devices. So, when a whitelisted device initiates a pairing request, the mobile device bypasses the confirmation dialogs, allowing the device to connect automatically and seamlessly without any user intervention. Only devices that have been whitelisted will bypass the pairing dialogs. This ensures security and control over which devices can connect automatically.
In order to define the list of pre-approved devices,
the property BT_SILENT_PAIRING_WHITELISTING
shall be configured.
Default Pairing:
The silent pairing procedure does not modify or interfere with the default Android pairing and connection processes.
For devices that are not whitelisted, the default Android behavior is maintained.
The user will be prompted with the standard Android pairing dialogs,
ensuring that non-whitelisted devices still require explicit user approval before they can connect.
In case the default Android behavior required to be modified or the user shall be restricted
in pairing external devices, the property BT_PAIRING_POLICY
can be configured
with this purpose.
Developer Responsibilities:
Even when using the silent pairing procedure, developers are still responsible for managing the Bluetooth connection and its associated events within their application. This includes utilizing the standard Android APIs and event receivers to handle the Bluetooth connection process after the pairing is completed. As documented by Google in https://developer.android.com/reference/android/bluetooth/BluetoothDevice
Developers must ensure that their application properly listens for Bluetooth connection events, manages connections, and handles any disconnections or other relevant events. The silent pairing procedure only affects the user interaction during the initial pairing process, and does not alter the standard procedures for Bluetooth connection management within the Android ecosystem.
By integrating this feature, developers can provide a more streamlined user experience while still leveraging the full capabilities of Android's Bluetooth API to manage device connections effectively.
The class of the property is BooleanProperty
.