Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
adamierymenko committed May 4, 2017
1 parent 13edbd2 commit bd23740
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions speck_hash.h
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@ static void speck_hash_finalize(struct speck_hash *h,uint8_t digest[16])
speck_encrypt(h->digest,tmp,h->nextblk);

/* Merkle–Damgård length padding */
pad[0] = h->totallen;
pad[1] = ~h->totallen;
pad[0] = (uint64_t)h->totallen;
pad[1] = ~((uint64_t)h->totallen);
speck_encrypt(h->digest,tmp,pad);
h->digest[0] ^= tmp[0];
h->digest[1] ^= tmp[1];
Expand Down

0 comments on commit bd23740

Please sign in to comment.