diff options
author | Paolo Abeni <pabeni@redhat.com> | 2020-01-21 16:56:30 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-01-24 13:44:08 +0100 |
commit | 65492c5a6ab5df5091a77562dbcca2d2dc3877c0 (patch) | |
tree | ce025683cbfca0696b85d62a73cc01f28500bf89 /net/mptcp/protocol.h | |
parent | 048d19d444be1e42abca19a6b969343954ae4e17 (diff) |
mptcp: move from sha1 (v0) to sha256 (v1)
For simplicity's sake use directly sha256 primitives (and pull them
as a required build dep).
Add optional, boot-time self-tests for the hmac function.
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Christoph Paasch <cpaasch@apple.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/mptcp/protocol.h')
-rw-r--r-- | net/mptcp/protocol.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/mptcp/protocol.h b/net/mptcp/protocol.h index a8fad7d78565..a355bb1cf31b 100644 --- a/net/mptcp/protocol.h +++ b/net/mptcp/protocol.h @@ -43,7 +43,7 @@ #define MPTCP_VERSION_MASK (0x0F) #define MPTCP_CAP_CHECKSUM_REQD BIT(7) #define MPTCP_CAP_EXTENSIBILITY BIT(6) -#define MPTCP_CAP_HMAC_SHA1 BIT(0) +#define MPTCP_CAP_HMAC_SHA256 BIT(0) #define MPTCP_CAP_FLAG_MASK (0x3F) /* MPTCP DSS flags */ @@ -216,7 +216,7 @@ static inline void mptcp_crypto_key_gen_sha(u64 *key, u32 *token, u64 *idsn) } void mptcp_crypto_hmac_sha(u64 key1, u64 key2, u32 nonce1, u32 nonce2, - u32 *hash_out); + void *hash_out); static inline struct mptcp_ext *mptcp_get_ext(struct sk_buff *skb) { |