From 8d9ea52be9e7de1373641d3afaed9b292cb03f43 Mon Sep 17 00:00:00 2001 From: Paul Kehrer Date: Thu, 17 Jan 2019 09:41:25 -0600 Subject: support byteslike in hmac update (#4705) needed for some KDF keying material --- tests/hazmat/primitives/test_hmac.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/hazmat/primitives/test_hmac.py b/tests/hazmat/primitives/test_hmac.py index b6d18ff1..0e2fe688 100644 --- a/tests/hazmat/primitives/test_hmac.py +++ b/tests/hazmat/primitives/test_hmac.py @@ -84,7 +84,7 @@ class TestHMAC(object): def test_buffer_protocol(self, backend): key = bytearray(b"2b7e151628aed2a6abf7158809cf4f3c") h = hmac.HMAC(key, hashes.SHA256(), backend) - h.update(b"6bc1bee22e409f96e93d7e117393172a") + h.update(bytearray(b"6bc1bee22e409f96e93d7e117393172a")) assert h.finalize() == binascii.unhexlify( b"a1bf7169c56a501c6585190ff4f07cad6e492a3ee187c0372614fb444b9fc3f0" ) -- cgit v1.2.3