File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
features/FEATURE_BLE/targets/TARGET_CORDIO/source Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -96,7 +96,13 @@ ble_error_t CordioSecurityManager::clear_resolving_list()
96
96
ble_error_t CordioSecurityManager::set_secure_connections_support (
97
97
bool enabled, bool secure_connections_only
98
98
) {
99
- return BLE_ERROR_NOT_IMPLEMENTED;
99
+ // secure connection support is enabled automatically at the stack level.
100
+ if (secure_connections_only) {
101
+ pSmpCfg->auth |= SMP_AUTH_SC_FLAG;
102
+ } else {
103
+ pSmpCfg->auth &= ~SMP_AUTH_SC_FLAG;
104
+ }
105
+ return BLE_ERROR_NONE;
100
106
}
101
107
102
108
ble_error_t CordioSecurityManager::get_secure_connections_support (
@@ -289,9 +295,6 @@ ble_error_t CordioSecurityManager::send_pairing_request(
289
295
KeyDistribution initiator_dist,
290
296
KeyDistribution responder_dist
291
297
) {
292
- // FIXME: understand if this is required
293
- pSmpCfg->auth = authentication_requirements.value ();
294
-
295
298
DmSecPairReq (
296
299
connection,
297
300
oob_data_flag,
You can’t perform that action at this time.
0 commit comments