Usecase:
1) Install the same system version and CtsVerifier.apk on 2 DUT's
2) Pair both DUT's using BT Settings Menu.
3) On DUT execute Bluetooth Test -> Bluetooth LE Secure Server Test ->
Bluetooth LE Sever Test.
4) On remote device execute Bluetooth Test-> Bluetooth LE Secure Client
Test -> Bluetooth LE Client Test
Expected Result:
All test cases can be passed.
Observed Result:
All test cases cannot be passed.
Root Cause:
DUT supports secure connection & LE privacy and during BR/EDR pairing LTK is
derived from LK, but device type is not updated and is still BR/EDR instead of LE.
Later when Gatt server starts advertisement with random address so while creating
LE connection from gatt client to gatt server, gatt client is not able to resolve
random address due to incorrect device type, It re-initiate LE paring with
gatt server.
Fix:
Updating device type as BLE while deriving LTK from LK.
Test: CTS test case can pass with above steps.
Fixes:
74728232
Change-Id: I1f2c5b54d17a58615f7c2ceb954e54619b165489
return;
}
+ tBTM_SEC_DEV_REC* p_dev_rec = btm_find_dev(p_cb->pairing_bda);
+ if (p_dev_rec) {
+ SMP_TRACE_DEBUG("%s: dev_type = %d ", __func__, p_dev_rec->device_type);
+ p_dev_rec->device_type |= BT_DEVICE_TYPE_BLE;
+ } else {
+ SMP_TRACE_ERROR("%s failed to find Security Record", __func__);
+ }
+
SMP_TRACE_DEBUG("%s: LTK derivation from LK successfully completed",
__func__);
smp_save_secure_connections_long_term_key(p_cb);