]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-40791: Use CRYPTO_memcmp() for compare_digest (#20456)
authorChristian Heimes <christian@python.org>
Wed, 27 May 2020 19:50:06 +0000 (21:50 +0200)
committerGitHub <noreply@github.com>
Wed, 27 May 2020 19:50:06 +0000 (21:50 +0200)
commitdb5aed931f8a617f7b63e773f62db468fe9c5ca1
tree64a2a3bf0865ac93b92d8361b6d3b51f1123cb0a
parent210a137396979d747c2602eeef46c34fc4955448
bpo-40791: Use CRYPTO_memcmp() for compare_digest (#20456)

hashlib.compare_digest uses OpenSSL's CRYPTO_memcmp() function
when OpenSSL is available.

Note: The _operator module is a builtin module. I don't want to add
libcrypto dependency to libpython. Therefore I duplicated the wrapper
function and added a copy to _hashopenssl.c.
Doc/library/hmac.rst
Lib/hmac.py
Lib/test/test_hmac.py
Misc/NEWS.d/next/Library/2020-05-27-18-04-52.bpo-40791.IzpNor.rst [new file with mode: 0644]
Modules/_hashopenssl.c
Modules/_operator.c
Modules/clinic/_hashopenssl.c.h