Skip to content

Commit 6a3f3d1

Browse files
committed
BLE - Conditionnally remove LESC and privacy event processing.
1 parent 20c4e4c commit 6a3f3d1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

features/FEATURE_BLE/targets/TARGET_CORDIO/source/CordioPalSecurityManager.tpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -773,13 +773,15 @@ bool CordioSecurityManager<EventHandler>::sm_handler(const wsfMsgHdr_t* msg) {
773773
return true;
774774
}
775775

776+
#if BLE_FEATURE_SECURE_CONNECTIONS
776777
case DM_SEC_ECC_KEY_IND: {
777778
secEccMsg_t* evt = (secEccMsg_t*) msg;
778779
DmSecSetEccKey(&evt->data.key);
779780
memcpy(self._public_key_x, evt->data.key.pubKey_x, sizeof(self._public_key_x));
780781
self._lesc_keys_generated = true;
781782
return true;
782783
}
784+
#endif // BLE_FEATURE_SECURE_CONNECTIONS
783785

784786
case DM_SEC_COMPARE_IND: {
785787
dmSecCnfIndEvt_t* evt = (dmSecCnfIndEvt_t*) msg;
@@ -800,6 +802,7 @@ bool CordioSecurityManager<EventHandler>::sm_handler(const wsfMsgHdr_t* msg) {
800802
return true;
801803
}
802804

805+
#if BLE_FEATURE_PRIVACY
803806
// Privacy
804807
case DM_PRIV_ADD_DEV_TO_RES_LIST_IND: // Device added to resolving list
805808
case DM_PRIV_REM_DEV_FROM_RES_LIST_IND: // Device removed from resolving list
@@ -809,6 +812,7 @@ bool CordioSecurityManager<EventHandler>::sm_handler(const wsfMsgHdr_t* msg) {
809812
self.process_privacy_control_blocks(true);
810813
return true;
811814
}
815+
#endif // BLE_FEATURE_PRIVACY
812816
default:
813817
return false;
814818
}

0 commit comments

Comments
 (0)