MCPcopy Create free account
hub / github.com/python/cpython / test_sha3_224_nist

Method test_sha3_224_nist

Lib/test/test_hmac.py:616–636  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

614 })
615
616 def test_sha3_224_nist(self):
617 for key, msg, hexdigest in [
618 (
619 bytes(range(28)),
620 b'Sample message for keylen<blocklen',
621 '332cfd59347fdb8e576e77260be4aba2d6dc53117b3bfb52c6d18c04'
622 ), (
623 bytes(range(144)),
624 b'Sample message for keylen=blocklen',
625 'd8b733bcf66c644a12323d564e24dcf3fc75f231f3b67968359100c7'
626 ), (
627 bytes(range(172)),
628 b'Sample message for keylen>blocklen',
629 '078695eecc227c636ad31d063a15dd05a7e819a66ec6d8de1e193e59'
630 )
631 ]:
632 self.assert_hmac(
633 key, msg, hexdigest,
634 hashfunc=self.sha3_224, hashname='sha3_224',
635 digest_size=28, block_size=144
636 )
637
638 def test_sha3_256_nist(self):
639 for key, msg, hexdigest in [

Callers

nothing calls this directly

Calls 1

assert_hmacMethod · 0.80

Tested by

no test coverage detected