Only exist in OpenSSL 1.1.0. They were
renamed from EVP_MD_CTX_create() and
EVP_MD_CTX_destroy().
Followup to r1728979.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@
1729037 13f79535-47bb-0310-9956-
ffa450edef68
return APR_EINVAL;
}
+#if OPENSSL_VERSION_NUMBER < 0x10100000L
+ ctx = EVP_MD_CTX_create();
+#else
ctx = EVP_MD_CTX_new();
+#endif
ap_assert(1 == EVP_VerifyInit(ctx, EVP_sha256()));
ap_assert(1 == EVP_VerifyUpdate(ctx, sctf->signed_data,
sctf->signed_data_len));
rc = EVP_VerifyFinal(ctx, sctf->sig, sctf->siglen, pkey);
+#if OPENSSL_VERSION_NUMBER < 0x10100000L
+ EVP_MD_CTX_destroy(ctx);
+#else
EVP_MD_CTX_free(ctx);
+#endif
return rc == 1 ? APR_SUCCESS : APR_EINVAL;
}