pycryptodome
pycryptodome copied to clipboard
BLAKE2 oid error
It seems that in the file BLAKE2b.py instead of the lines
# See https://tools.ietf.org/html/rfc7693
if digest_bytes in (20, 32, 48, 64) and not key:
self.oid = "1.3.6.1.4.1.1722.12.2.1." + str(digest_bytes)
there should be the lines
# See https://tools.ietf.org/html/rfc7693
if digest_bytes in (20, 32, 48, 64) and not key:
self.oid = "1.3.6.1.4.1.1722.12.2.1." + str(digest_bytes // 4)
There is a similar problem with the file BLAKE2s.py
Thanks, fixed with 2816c3e3d6718c236851e3abed74a94dabf4f07e