ACTION_PAIRING_CANCEL does not contain an EXTRA_BOND_STATE
Test: Log change is no-op
Bug: 253775131
Change-Id: Ida67374e9369991d7e016b38df9c17a8fa5418cc
Add PendingIntent.FLAG_UPDATE_CURRENT to let peding intent can
be updated the intent extra.
Bug: 204133175
Test: make -j64 RunSettingsRoboTests
Change-Id: I42966432dacc3727d31231d10aa07b782bb1d92e
When the pairing dialog doesn't show in the foreground at the first time, the pairing key will display incorrectly.
This is caused by the intent doesn't contain the parameter BluetoothDevice.EXTRA_PAIRING_KEY.
Correct the pairing key by passing the pairing key to intent pairingDialogIntent.
Tag: #stability
Bug: 188614067
Test: make RunSettingsRoboTests ROBOTEST_FILTER=BluetoothPairingServiceTest
Change-Id: I3c91bf6ea51fa3fb77b4c4a5c17555606160603e
Remove setForeground() in BluetoothPairingService. Refactor
the behavior to not holding service in the background.
Bug: 184901840
Test: make RunSettingsRoboTests -j56
Change-Id: Iaeb96943971f55dbeb3dba4b06b28abe770ba3c2
- Android S+ to specify explicitly either FLAG_MUTABLE or FLAG_IMMUTABLE
when creating a PendingIntent.
- Suggest to use the FLAG_IMMUTABLE as default. Change it to
FLAG_MUTABLE while errors occur.
Fixes: 172207262
Fixes: 172207195
Fixes: 172205385
Fixes: 172204525
Fixes: 172205897
Test: build pass, manual test to paring blutooth device and doing
seamless transfer
Change-Id: Ic37b37bdbe6de6bdbad741985d3a920334240d80
Usecase:
1. Start advertising from DUT (using BLE Smartertooth app).
2. Scan and connect from central device.
3. Now initiate bond from central and accept pairing request.
(Consent Pairing Dialog will be shown on DUT)
4. Notification will be received for PASSKEY CONFIRMATION Dialog.
Do not open notification and let it timeout.
5. Repeat steps 2 and 3. At step 3, Passkey Confirmation pairing
dialog is show instead of Consent pairing dialog.
Issue:
Wrong Pairing Popup is shown. Passkey Confirmation pairing
dialog is show instead of Consent pairing dialog.
Reproducible Rate: 100%
Root Cause:
PendingIntent created for showing pairing notification are getting
reused as only FLAG_ONE_SHOT is used. This flag is not updating new
extra's in the pending intent.
Fix:
Use flag FLAG_UPDATE_CURRENT in pending Intent.
Test: Tested above mentioned testcase and pairing scenarios.
Bug: 129456113
Change-Id: I46813f355cd796cee1b472774b494c8580b39784
This will prevent them from showing up on external devices where they
would be less than useful.
Test: connect to watch and pair a device
Bug: 34612389
Change-Id: I8b02c20200ce78a73967b8121cf7d5653b68f356
Add actions to the pairing service notification so the user can dismiss
the pairing request if they want to.
Add some more information to logs when the user takes an action.
Reformat the file to match android style.
Test: pair from a remote device, dismiss using the new actions
Bug: 36036358
Change-Id: Ie110044bd4caf465f454452737000f01e7430925
(cherry picked from commit c79470d089)
Add actions to the pairing service notification so the user can dismiss
the pairing request if they want to.
Add some more information to logs when the user takes an action.
Reformat the file to match android style.
Test: pair from a remote device, dismiss using the new actions
Bug: 36036358
Change-Id: Ie110044bd4caf465f454452737000f01e7430925
We can get to onDestroy() without registering now.
Test: none
Fixes: 36501241
Change-Id: I90da3b350f9951993238d51f9fde86ccb335cafd
(cherry picked from commit af34ed06f1)
If BluetoothPairingService was stopped and restarted, it would receive
a null intent, and it also would not signal correctly when it needed to
be stopped.
Since restarts can happen, check that we are still bonding when starting.
Also prevent crashes when we might be called with a null intent.
Test: initiate pairing remotely, adb am kill service, notice no crash
Bug: 36130262
Change-Id: I408811935fdb36591826f4481d103cf4799db27e
Use a foreground service to show the notification, separating dialog
creation from the receiver.
Test: pair request from remote device while the screen is off
Bug: 35234069
Change-Id: Ia3be3e8efdacf465e095af5a498ef5eb0fca83cd