diff options
author | Dr. David von Oheimb <David.von.Oheimb@siemens.com> | 2020-12-28 11:27:31 +0100 |
---|---|---|
committer | Dr. David von Oheimb <dev@ddvo.net> | 2021-01-13 09:09:36 +0100 |
commit | bf973d0697e61a44dc46d08b0421a08a8cb61887 (patch) | |
tree | 023ed993172263fa1c261e8321d77b325380d95f /include | |
parent | 5a2d0ef36f4c130758a9d5e84f93004458e3ce60 (diff) | |
download | openssl-bf973d0697e61a44dc46d08b0421a08a8cb61887.tar.gz |
Add X509_NAME_hash_ex() to be able to check if it failed due to unsupported SHA1
Deprecate X509_NAME_hash()
Document X509_NAME_hash_ex(), X509_NAME_hash(), X509_{subject,issuer}_name_hash()
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/13762)
Diffstat (limited to 'include')
-rw-r--r-- | include/openssl/x509.h.in | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/include/openssl/x509.h.in b/include/openssl/x509.h.in index 825c941aeb..1d9ca63405 100644 --- a/include/openssl/x509.h.in +++ b/include/openssl/x509.h.in @@ -824,7 +824,11 @@ int X509_add_certs(STACK_OF(X509) *sk, STACK_OF(X509) *certs, int flags); int X509_cmp(const X509 *a, const X509 *b); int X509_NAME_cmp(const X509_NAME *a, const X509_NAME *b); -unsigned long X509_NAME_hash(const X509_NAME *x); +#ifndef OPENSSL_NO_DEPRECATED_3_0 +# define X509_NAME_hash(x) X509_NAME_hash_ex(x, NULL, NULL, NULL) +#endif +unsigned long X509_NAME_hash_ex(const X509_NAME *x, OSSL_LIB_CTX *libctx, + const char *propq, int *ok); unsigned long X509_NAME_hash_old(const X509_NAME *x); int X509_CRL_cmp(const X509_CRL *a, const X509_CRL *b); |