fix: do not override sequence counter after window processing

This commit is contained in:
Lucien Zuercher authored and Jon Shallow committed 2026-03-19 14:48:16 +00:00
1 parent 66f465a022
commit 5b5b6972ec
1 file changed
+5 -4
+5 -4
View File
@@ -1122,10 +1122,11 @@ coap_oscore_decrypt_pdu(coap_session_t *session,
0);
goto error_no_ack;
}
incoming_seq =
coap_decode_var_bytes8(cose->partial_iv.s, cose->partial_iv.length);
rcp_ctx->last_seq = incoming_seq;
if (rcp_ctx->initial_state == 1) {
incoming_seq =
coap_decode_var_bytes8(cose->partial_iv.s, cose->partial_iv.length);
rcp_ctx->last_seq = incoming_seq;
}
} else { /* !coap_request */
/*
* 8.4 Step 2