Skip to content
Permalink
Browse files

Bluetooth: SMP: Fix SMP identity distributing IRK for ID 0 always

Fix an issue in the SMP identity distribution where the IRK for the
default identity was always distributed.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
  • Loading branch information...
joerchan authored and carlescufi committed Aug 6, 2019
1 parent 167eb53 commit ccbb18c9acf429af68cebe2ad2b86535af19d1da
Showing with 2 additions and 2 deletions.
  1. +2 −2 subsys/bluetooth/host/smp.c
@@ -938,7 +938,7 @@ static void smp_br_distribute_keys(struct bt_smp_br *smp)
}

id_info = net_buf_add(buf, sizeof(*id_info));
memcpy(id_info->irk, bt_dev.irk, 16);
memcpy(id_info->irk, bt_dev.irk[conn->id], 16);

smp_br_send(smp, buf, NULL);

@@ -1828,7 +1828,7 @@ static void bt_smp_distribute_keys(struct bt_smp *smp)
}

id_info = net_buf_add(buf, sizeof(*id_info));
memcpy(id_info->irk, bt_dev.irk, 16);
memcpy(id_info->irk, bt_dev.irk[conn->id], 16);

smp_send(smp, buf, NULL, NULL);

0 comments on commit ccbb18c

Please sign in to comment.
You can’t perform that action at this time.