llHMAC: Make more elaborate tests and allow running them

This commit is contained in:
Sei Lisa 2023-03-08 19:32:49 +01:00
parent 500a8bb751
commit e4c9627772
4 changed files with 26 additions and 3 deletions

View file

@ -1325,7 +1325,7 @@ def llHMAC(pwd, data, alg):
elif alg == u'sha512':
hash = hashlib.sha512()
if hash is None:
raise ELSLCantCompute # we don't have info on how it behaves yet
raise ELSLCantCompute # spews error
# Calculate the HMAC here, to avoid requiring yet another module
if len(pwd) > hash.block_size:
tmp = hash.copy()