temporary code for use during verification before we integrate with gap

pull/6188/head
paul-szczepanek-arm 2018-01-23 10:47:16 +00:00
parent 10b5e648fd
commit 4aa7158c4b
1 changed files with 11 additions and 0 deletions

View File

@ -117,9 +117,15 @@ public:
if (!entry) {
return BLE_ERROR_INVALID_PARAM;
}
/* TODO: remove */
db.get_entry(connection)->master = true;
/* end temp code */
if (!legacy_pairing_allowed && !default_authentication.get_secure_connections()) {
return BLE_ERROR_OPERATION_NOT_PERMITTED;
}
AuthenticationMask link_authentication(default_authentication);
link_authentication.set_mitm(entry->mitm_requested);
@ -622,10 +628,15 @@ public:
KeyDistribution initiator_dist,
KeyDistribution responder_dist
) {
/* TODO: remove */
db.get_entry(connection)->master = false;
/* end temp code */
/* cancel pairing if secure connection paring is not possible */
if (!legacy_pairing_allowed && !authentication.get_secure_connections()) {
canceltPairingRequest(connection);
}
set_mitm_performed(connection, false);
if (pairing_authorisation_required) {