diff options
author | Tomas Mraz <tomas@openssl.org> | 2021-04-22 12:45:39 +0200 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2021-04-23 16:12:22 +0200 |
commit | ccfe5ec8fe6c36e10aea373d44dcf04f65d94ef0 (patch) | |
tree | 4e3bb5f12d68ee62d8d6505bb13dad78f5eddf85 /crypto/siphash/siphash_ameth.c | |
parent | fff6d5966d00a9e2cb5270e0f7e49abbfce0c9bf (diff) |
Correct the return value on match and mismatch for MAC pkeys
Fixes #14147
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/14982)
Diffstat (limited to 'crypto/siphash/siphash_ameth.c')
-rw-r--r-- | crypto/siphash/siphash_ameth.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/siphash/siphash_ameth.c b/crypto/siphash/siphash_ameth.c index 2da6dfec80..68331ab4c4 100644 --- a/crypto/siphash/siphash_ameth.c +++ b/crypto/siphash/siphash_ameth.c @@ -44,7 +44,7 @@ static int siphash_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2) static int siphash_pkey_public_cmp(const EVP_PKEY *a, const EVP_PKEY *b) { - return ASN1_OCTET_STRING_cmp(EVP_PKEY_get0(a), EVP_PKEY_get0(b)); + return ASN1_OCTET_STRING_cmp(EVP_PKEY_get0(a), EVP_PKEY_get0(b)) == 0; } static int siphash_set_priv_key(EVP_PKEY *pkey, const unsigned char *priv, |