• Johan Hedberg's avatar
    Bluetooth: Fix incorrect removing of IRKs · cff10ce7
    Johan Hedberg authored
    The commit cad20c27 was supposed to
    fix handling of devices first using public addresses and then
    switching to RPAs after pairing. Unfortunately it missed a couple of
    key places in the code.
    
    1. When evaluating which devices should be removed from the existing
    white list we also need to consider whether we have an IRK for them or
    not, i.e. a call to hci_find_irk_by_addr() is needed.
    
    2. In smp_notify_keys() we should not be requiring the knowledge of
    the RPA, but should simply keep the IRK around if the other conditions
    require it.
    Signed-off-by: default avatarJohan Hedberg <johan.hedberg@intel.com>
    Signed-off-by: default avatarMarcel Holtmann <marcel@holtmann.org>
    Cc: stable@vger.kernel.org # 4.4+
    cff10ce7
hci_request.c 56.9 KB