Skip to content

Commit d59ce64

Browse files
committed
bpo-40479: Fix typo, flag must be set for OpenSSL < 3.0.0
1 parent 1a4d1c1 commit d59ce64

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Modules/_hashopenssl.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -883,7 +883,7 @@ py_evp_fromname(PyObject *module, const char *digestname, PyObject *data_obj,
883883
goto exit;
884884
}
885885

886-
#if defined(EVP_MD_CTX_FLAG_NON_FIPS_ALLOW) && OPENSSL_VERSION_NUMBER >= 0x30000000L
886+
#if defined(EVP_MD_CTX_FLAG_NON_FIPS_ALLOW) && OPENSSL_VERSION_NUMBER < 0x30000000L
887887
// In OpenSSL 1.1.1 the non FIPS allowed flag is context specific while
888888
// in 3.0.0 it is a different EVP_MD provider.
889889
if (!usedforsecurity) {

0 commit comments

Comments
 (0)