Connect and paring issues

When the phone and controller bonding gets out of sync we are having issues. By out of
sync I mean that either the controller (customer board with a nRF52840) or the phone
no longer has the bond information. For example if a phone and a controller are bonded
and the controller is “Unpaired” in the phone bluetooth settings we have issues reestablishing the connection. In this case we have a crude workout around where we
send a ble command through a SEC_OPEN ble characteristic where the controller on
receipt of the command enters the function below

void delete_bonds(void)
{
    ret_code_t err_code;
    NRF_LOG_INFO("Erase bonds!");
    err_code = pm_peers_delete();
    APP_ERROR_CHECK(err_code);
}


When successful the connect between the phone and controller can be re-established
with issue.
However in the case where bonding has been made between the controller and the
phone and the bond broken as described above that phone will not be able to reestablish a connection to the controller. So another phone needs to be used in order to
send the delete_bonds() command.

Parents
  • Hi, 

    That's the correct flow. Instead of allowing to repair you delete bonds, so that the peer would have to connect again, and then pairing would succeed. This does not provide better security, as the security issue with allowing repairing is that an attacker can spoof a peered device and that way replace it's bond. This would also be the case here. If you want to allow to repair the bond, see this post.

    Regards,
    Amanda

Reply
  • Hi, 

    That's the correct flow. Instead of allowing to repair you delete bonds, so that the peer would have to connect again, and then pairing would succeed. This does not provide better security, as the security issue with allowing repairing is that an attacker can spoof a peered device and that way replace it's bond. This would also be the case here. If you want to allow to repair the bond, see this post.

    Regards,
    Amanda

Children
No Data
Related