From 9b83b11376ad0cb7bd6b3aea5a4ae475d6f01ce7 Mon Sep 17 00:00:00 2001 From: Sumeet Singh Date: Fri, 29 Mar 2024 18:19:41 +0530 Subject: [PATCH] fix(nimble): Removed code for termination upon signed write operation failure --- nimble/host/src/ble_att_svr.c | 1 - nimble/host/src/ble_gap.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/nimble/host/src/ble_att_svr.c b/nimble/host/src/ble_att_svr.c index 88eb9b16e..e3d856dc8 100644 --- a/nimble/host/src/ble_att_svr.c +++ b/nimble/host/src/ble_att_svr.c @@ -2438,7 +2438,6 @@ ble_att_svr_rx_signed_write(uint16_t conn_handle, struct os_mbuf **rxom) return 0; err: if(message != NULL) nimble_platform_mem_free(message); - ble_gap_terminate(conn_handle, BLE_ERR_AUTH_FAIL); return rc; } diff --git a/nimble/host/src/ble_gap.c b/nimble/host/src/ble_gap.c index f27359a73..16188ec5b 100644 --- a/nimble/host/src/ble_gap.c +++ b/nimble/host/src/ble_gap.c @@ -6792,7 +6792,7 @@ ble_gap_unpair(const ble_addr_t *peer_addr) } } - if (value.sec.ltk_present || value.sec.irk_present) { + if (value.sec.ltk_present || value.sec.irk_present || value.sec.csrk_present) { // Delete the Peer record from store as LTK is present ltk_rc = ble_store_util_delete_peer(&key.sec.peer_addr); if (ltk_rc != 0) {