+# These two functions are renamed in OpenSSL 1.1.0
+if hasattr(libcrypto,"EVP_MD_CTX_create"):
+ Digest.newctx = libcrypto.EVP_MD_CTX_create
+ Digest.freectx = libcrypto.EVP_MD_CTX_destroy
+else:
+ Digest.newctx = libcrypto.EVP_MD_CTX_new
+ Digest.freectx = libcrypto.EVP_MD_CTX_free
+Digest.newctx.restype = c_void_p
+Digest.freectx.argtypes = (c_void_p, )