If we want AUTHENTICATED_ENCRYPTED_TRANSPORT, temporary link key is not
sufficient. Pair again.
Test: cert/run --host
Tag: #gd-refactor
Bug:
141555841
Change-Id: I9a5b4b08fdd22d6c453443f6315b3f136913b516
switch (policy) {
case l2cap::classic::SecurityPolicy::BEST:
case l2cap::classic::SecurityPolicy::AUTHENTICATED_ENCRYPTED_TRANSPORT:
- if (!record->IsPaired()) {
+ if (!record->IsPaired() || record->IsTemporary()) {
need_to_pair = true;
} else if (record->IsAuthenticated()) {
// if paired with MITM, only encryption is missing, so we just need to wait for encryption change callback