summaryrefslogtreecommitdiffstats
path: root/include/crypto/evp.h
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2020-02-05 12:55:43 +0100
committerRichard Levitte <levitte@openssl.org>2020-03-02 03:27:03 +0100
commit1e9101c404b92b1fd32e8f0308ddc20742285135 (patch)
treec079330956bbf65069928a624b6d77bcbf591ea7 /include/crypto/evp.h
parentbee5d6cd3fa2f8bcc7e1153e4dc26aa26144bee0 (diff)
EVP: Add support for comparing provided EVP_PKEYs
This adds evp_keymgmt_util_match() and affects EVP_PKEY_cmp() and EVP_PKEY_cmp_parameters(). The word 'match' was used for the new routines because many associate 'cmp' with comparison functions that allows sorting, i.e. return -1, 0 or 1 depending on the order in which the two compared elements should be sorted. EVP_PKEY_cmp() and EVP_PKEY_cmp_parameters() don't quite do that. Reviewed-by: Shane Lontis <shane.lontis@oracle.com> (Merged from https://github.com/openssl/openssl/pull/11158)
Diffstat (limited to 'include/crypto/evp.h')
-rw-r--r--include/crypto/evp.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/crypto/evp.h b/include/crypto/evp.h
index 74d0c4b345..f9c67d2a71 100644
--- a/include/crypto/evp.h
+++ b/include/crypto/evp.h
@@ -620,6 +620,7 @@ void evp_keymgmt_util_cache_keyinfo(EVP_PKEY *pk);
void *evp_keymgmt_util_fromdata(EVP_PKEY *target, EVP_KEYMGMT *keymgmt,
int selection, const OSSL_PARAM params[]);
int evp_keymgmt_util_has(EVP_PKEY *pk, int selection);
+int evp_keymgmt_util_match(EVP_PKEY *pk1, EVP_PKEY *pk2, int selection);
/*