Skip to content

Commit

Permalink
mesh: Allow Key Refresh Phase 0 to 3 transition
Browse files Browse the repository at this point in the history
Transition to Phase 3 from Phase 0 does not cause any state change, but
is a valid transition. See MshPRFv1.0.1 section 4.2.14.
  • Loading branch information
iwestin authored and bgix committed Oct 3, 2022
1 parent 9d22d54 commit 291cff0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mesh/cfgmod-server.c
Expand Up @@ -436,6 +436,10 @@ static uint16_t cfg_key_refresh_phase(struct mesh_node *node,
return 0;
}

if (pkt[2] == KEY_REFRESH_TRANS_THREE &&
phase == KEY_REFRESH_PHASE_NONE)
goto done;

status = mesh_net_key_refresh_phase_set(net, idx, pkt[2]);
l_debug("Set KR Phase: net=%3.3x transition=%d", idx, pkt[2]);

Expand Down

0 comments on commit 291cff0

Please sign in to comment.