Skip to content

Commit 8cbacaa

Browse files
apps: bttester: handle GAP authorization event
BLE_GAP_AUTHORIZE_REJECT is always returned when authorized attribute is being accessed. This is needed for GATT/SR tests that requires rejecting ATT requests with insufficient authorization error.
1 parent 129408d commit 8cbacaa

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

apps/bttester/src/btp_gap.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1594,6 +1594,10 @@ gap_event_cb(struct ble_gap_event *event, void *arg)
15941594
periodic_transfer_received(event);
15951595
break;
15961596
#endif
1597+
case BLE_GAP_EVENT_AUTHORIZE:
1598+
console_printf("Authorize event: conn_handle=%d",
1599+
event->authorize.conn_handle);
1600+
return BLE_GAP_AUTHORIZE_REJECT;
15971601
default:
15981602
break;
15991603
}

0 commit comments

Comments
 (0)