Message ID | 20220929110344.26130-3-isak.westin@loytec.com (mailing list archive) |
---|---|
State | Accepted |
Commit | 7d050890f01f32ebb394140cf3206ad5a5548d79 |
Headers | show |
Series | Mesh: Fix IV update and KeyRefresh procedures | expand |
Context | Check | Description |
---|---|---|
tedd_an/pre-ci_am | success | Success |
tedd_an/checkpatch | success | Checkpatch PASS |
tedd_an/gitlint | success | Gitlint PASS |
diff --git a/mesh/net.c b/mesh/net.c index dc3d1fd80..c225fdb9a 100644 --- a/mesh/net.c +++ b/mesh/net.c @@ -2671,6 +2671,10 @@ static bool update_iv_ivu_state(struct mesh_net *net, uint32_t iv_index, if (iv_index == net->iv_index) return false; + /* Ignore beacon with invalid IV index value */ + if (net->iv_update && iv_index == net->iv_index + 1) + return false; + if (!net->iv_update) { l_debug("iv_upd_state = IV_UPD_UPDATING"); net->iv_upd_state = IV_UPD_UPDATING;