[trel] bugfix for MAC security failure on key sequence change (#9371)

In multi-radio scenarios, any key sequence change currently resets the
MAC frame counter for the PHY link over which the first frame (with
new keyId and frame counter) is received. Since the neighbor key
sequence is already modified, any subsequent frame received over the
alternate PHY would have match the neighbor key sequence, but
potentially smaller frame counter, which leads to drops due to
security failure.
This commit is contained in:
sarveshkumarv3
2023-08-24 09:19:03 -07:00
committed by GitHub
parent c10f650468
commit 6009decd43
+1
View File
@@ -1603,6 +1603,7 @@ Error Mac::ProcessReceiveSecurity(RxFrame &aFrame, const Address &aSrcAddr, Neig
{
aNeighbor->SetKeySequence(keySequence);
aNeighbor->SetMleFrameCounter(0);
aNeighbor->GetLinkFrameCounters().Reset();
}
#if OPENTHREAD_CONFIG_MULTI_RADIO