diff options
author | Mattias Andrée <maandree@kth.se> | 2019-02-10 20:57:56 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@kth.se> | 2019-02-10 20:57:56 +0100 |
commit | 15f132722cae63775dd7b2fef866d477c54c7b8e (patch) | |
tree | 27359241e0a1a0b6f304060bc0a9e7c9287efd06 /hmac_marshal.c | |
parent | First commit (diff) | |
download | libsha1-15f132722cae63775dd7b2fef866d477c54c7b8e.tar.gz libsha1-15f132722cae63775dd7b2fef866d477c54c7b8e.tar.bz2 libsha1-15f132722cae63775dd7b2fef866d477c54c7b8e.tar.xz |
Implement SHA-0 and remove .chunk_size1.0
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r-- | hmac_marshal.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/hmac_marshal.c b/hmac_marshal.c index 70d030b..95f4277 100644 --- a/hmac_marshal.c +++ b/hmac_marshal.c @@ -30,12 +30,12 @@ libsha1_hmac_marshal(const struct libsha1_hmac_state *restrict state, void *rest off += sizeof(unsigned char); if (buf) - memcpy(&buf[off], state->ipad, state->sha1_state.chunk_size); - off += state->sha1_state.chunk_size; + memcpy(&buf[off], state->ipad, sizeof(state->ipad)); + off += sizeof(state->ipad); if (buf) - memcpy(&buf[off], state->opad, state->sha1_state.chunk_size); - off += state->sha1_state.chunk_size; + memcpy(&buf[off], state->opad, sizeof(state->opad)); + off += sizeof(state->opad); return off; } |