summaryrefslogtreecommitdiffstats
path: root/crypto/evp/mac_lib.c
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2020-01-15 01:04:37 +0100
committerRichard Levitte <levitte@openssl.org>2020-01-17 08:59:41 +0100
commite4a1d0230016d090ba78bc7092384315f85b0e72 (patch)
tree518e1155d0185622e42d10918b9b0ca9a2317c3a /crypto/evp/mac_lib.c
parent9bb3e5fd87905e3e9f5f7edcc2e22d98360510ab (diff)
Modify EVP_CIPHER_is_a() and EVP_MD_is_a() to handle legacy methods too
These functions would only handle provided methods, but there are cases where the caller just passes along a received method without knowing the underlying method tech, so might pass along a legacy method. We therefore need to have them handle this case as well so they don't cause any unnecessary surprises. Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/10845)
Diffstat (limited to 'crypto/evp/mac_lib.c')
-rw-r--r--crypto/evp/mac_lib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/evp/mac_lib.c b/crypto/evp/mac_lib.c
index 07ed1c8749..bf52aaff8c 100644
--- a/crypto/evp/mac_lib.c
+++ b/crypto/evp/mac_lib.c
@@ -165,7 +165,7 @@ int EVP_MAC_number(const EVP_MAC *mac)
int EVP_MAC_is_a(const EVP_MAC *mac, const char *name)
{
- return evp_is_a(mac->prov, mac->name_id, name);
+ return evp_is_a(mac->prov, mac->name_id, NULL, name);
}
void EVP_MAC_names_do_all(const EVP_MAC *mac,