fix: do not override sequence counter after window processing

This commit is contained in:
Lucien Zuercher authored and Jon Shallow committed 2026-03-24 17:22:07 +00:00
1 parent 60545f2d72
commit 22ffdb0702
1 file changed
+5 -4
+5 -4
View File
@@ -1048,10 +1048,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