Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
Fixes a memory leak in ``Hacl_Streaming_HMAC_digest`` by freeing the
``snd`` and ``thd`` fields of ``tmp_block_state1``.
2 changes: 2 additions & 0 deletions Modules/_hacl/Hacl_Streaming_HMAC.c
Original file line numberDiff line numberDiff line change
Expand Up@@ -2378,6 +2378,8 @@ Hacl_Streaming_HMAC_digest(
Hacl_Agile_Hash_state_s *s11 = tmp_block_state1.snd;
update_last(s11, prev_len_last, buf_last, r);
finish0(tmp_block_state1, output);
free_(tmp_block_state1.snd);
free_(tmp_block_state1.thd);
return Hacl_Streaming_Types_Success;
}
KRML_HOST_EPRINTF("KaRaMeL abort at %s:%d\n%s\n",
Expand Down
Loading