diff options
author | Mattias Andrée <maandree@kth.se> | 2024-09-06 20:00:21 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@kth.se> | 2024-09-06 20:00:21 +0200 |
commit | e08dff210507b3a56e8aa1cd14d653ecfb3228f9 (patch) | |
tree | 66771aef79dd8e5da0d88035cf601d0219d7010d /libhashsum_init_keccak__.c | |
parent | Document standard_partial_byte_{in,out}put_encoding in man pages (diff) | |
download | libhashsum-e08dff210507b3a56e8aa1cd14d653ecfb3228f9.tar.gz libhashsum-e08dff210507b3a56e8aa1cd14d653ecfb3228f9.tar.bz2 libhashsum-e08dff210507b3a56e8aa1cd14d653ecfb3228f9.tar.xz |
Add hash_excess_bits
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'libhashsum_init_keccak__.c')
-rw-r--r-- | libhashsum_init_keccak__.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libhashsum_init_keccak__.c b/libhashsum_init_keccak__.c index 6e1abf7..f9c8be1 100644 --- a/libhashsum_init_keccak__.c +++ b/libhashsum_init_keccak__.c @@ -151,6 +151,7 @@ libhashsum_init_keccak__(struct libhashsum_hasher *this, size_t hashbits, void * this->supports_non_whole_bytes = 1; this->standard_partial_byte_input_encoding = LIBHASHSUM_LEAST_SIGNIFICANT; this->standard_partial_byte_output_encoding = LIBHASHSUM_LEAST_SIGNIFICANT; + this->hash_excess_bits = (8U - (hashbits & 7U)) & 7U; this->state.keccak.squeezes = squeezes; this->state.keccak.suffix = suffix; |