diff options
author | David Goulet <dgoulet@torproject.org> | 2016-12-12 16:45:28 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2016-12-14 15:18:40 -0500 |
commit | 118691cd47e53521319cdcbf994f29ecca3db4d1 (patch) | |
tree | 78d64377d8a03653091601e18c3db6fc6424e65b /src/common/crypto.h | |
parent | 7a204ae8f9c54c15e9bc05b9c2bd62c7e46d6ebb (diff) | |
download | tor-118691cd47e53521319cdcbf994f29ecca3db4d1.tar.gz tor-118691cd47e53521319cdcbf994f29ecca3db4d1.zip |
crypto: Change crypto_mac_sha3_256 to use the key length in the construction
Signed-off-by: David Goulet <dgoulet@torproject.org>
Diffstat (limited to 'src/common/crypto.h')
-rw-r--r-- | src/common/crypto.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/common/crypto.h b/src/common/crypto.h index 32b6531456..bf2fa06aaa 100644 --- a/src/common/crypto.h +++ b/src/common/crypto.h @@ -255,9 +255,10 @@ void crypto_digest_assign(crypto_digest_t *into, void crypto_hmac_sha256(char *hmac_out, const char *key, size_t key_len, const char *msg, size_t msg_len); -void crypto_mac_sha3_256(char *mac_out, size_t mac_out_len, - const char *key, size_t key_len, - const char *msg, size_t msg_len); +void crypto_mac_sha3_256(uint8_t *mac_out, size_t len_out, + const uint8_t *key, size_t key_len, + const uint8_t *msg, size_t msg_len); + crypto_xof_t *crypto_xof_new(void); void crypto_xof_add_bytes(crypto_xof_t *xof, const uint8_t *data, size_t len); void crypto_xof_squeeze_bytes(crypto_xof_t *xof, uint8_t *out, size_t len); |