Skip to content

Commit

Permalink
incoming_data AES-CBC: use right offset
Browse files Browse the repository at this point in the history
  • Loading branch information
reynir committed Sep 30, 2024
1 parent 9f5b4f9 commit 4456378
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/engine.ml
Original file line number Diff line number Diff line change
Expand Up @@ -1400,7 +1400,7 @@ let incoming_data ?(add_timestamp = false) err (ctx : keys) hmac_algorithm
Log.debug (fun m ->
m "received replay packet id is %lu" (String.get_int32_be dec 0));
(* TODO validate ts if provided (avoid replay) *)
unpad AES.CBC.block_size dec off
unpad AES.CBC.block_size dec hdr_len
| AES_GCM { their_key; their_implicit_iv; _ } ->
let tag_len = Mirage_crypto.AES.GCM.tag_size in
let* () =
Expand Down

0 comments on commit 4456378

Please sign in to comment.