From 0548f849a87309da67d628ce8b0f847ea8e6edd8 Mon Sep 17 00:00:00 2001 From: Andrzej Kaczmarek Date: Mon, 12 Feb 2018 20:51:59 +0100 Subject: [PATCH] nimble/ll: Add note about InitA when initiating connection with privacy Even with privacy enabled we have to use our identity address as InitA when peer is not on our resolving list. Since this is a bit counter- intuitive, let's add a note with spec reference so we do not need to waste time in future figuring out why it is implemented like this. X-Original-Commit: 19cf6a3f92b9111f05fcd2f05cfa21bb62991cb9 --- nimble/controller/src/ble_ll_conn.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/nimble/controller/src/ble_ll_conn.c b/nimble/controller/src/ble_ll_conn.c index 909083a10..9123cf629 100644 --- a/nimble/controller/src/ble_ll_conn.c +++ b/nimble/controller/src/ble_ll_conn.c @@ -2728,6 +2728,11 @@ ble_ll_conn_req_pdu_update(struct os_mbuf *m, uint8_t *adva, uint8_t addr_type, } } + /* + * If peer in on resolving list, we use RPA generated with Local IRK + * from resolving list entry. In other case, we need to use our identity + * address (see Core 5.0, Vol 6, Part B, section 6.4). + */ if (rl) { hdr |= BLE_ADV_PDU_HDR_TXADD_RAND; ble_ll_resolv_gen_priv_addr(rl, 1, dptr);