Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b84f13ec authored by Łukasz Rymanowski's avatar Łukasz Rymanowski
Browse files

csis: Do not verify SIRK for device which is not joining any group

Bug: 303260283
Test: atest bluetooth_csis_test
Tag: #feature

Change-Id: I727449391600958a7e6ae0ac821287bac679ee6d
parent 1e1b6892
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -2282,6 +2282,18 @@ class CsisClientImpl : public CsisClient {
      return;
    }

    auto group_id_to_join = device->GetExpectedGroupIdMember();
    if (group_id_to_join == bluetooth::groups::kGroupUnknown) {
      LOG_WARN(
          "Device %s (conn_id=0x%04x) is already known to CSIS (# of "
          "instances=%d) but it is "
          "not scheduled to join any group.",
          ADDRESS_TO_LOGGABLE_CSTR(address), device->conn_id,
          device->GetNumberOfCsisInstances());
      BTA_DmSirkConfirmDeviceReply(address, true);
      return;
    }

    if (!gatt_cl_read_sirk_req(
            address,
            base::BindOnce(&CsisClientImpl::SirkValueReadCompleteDuringPairing,