SHA3-224¶
SHA3-224 belongs to the SHA-3 family of cryptographic hashes, as specified in FIPS 202.
The hash function produces the 224 bit digest of a message:
>>> from Crypto.Hash import SHA3_224
>>>
>>> h_obj = SHA3_224.new()
>>> h_obj.update(b'Some data')
>>> print h_obj.hexdigest()
SHA stands for Secure Hash Algorithm.
-
class
Crypto.Hash.SHA3_224.
SHA3_224_Hash
(data, update_after_digest)¶ A SHA3-224 hash object. Do not instantiate directly. Use the
new()
function.- Variables
oid (string) – ASN.1 Object ID
digest_size (integer) – the size in bytes of the resulting hash
-
digest
()¶ Return the binary (non-printable) digest of the message that has been hashed so far.
- Returns
The hash digest, computed over the data processed so far. Binary form.
- Return type
byte string
-
hexdigest
()¶ Return the printable digest of the message that has been hashed so far.
- Returns
The hash digest, computed over the data processed so far. Hexadecimal encoded.
- Return type
string
-
new
()¶ Create a fresh SHA3-224 hash object.
-
update
(data)¶ Continue hashing of a message by consuming the next chunk of data.
- Parameters
data (byte string/byte array/memoryview) – The next chunk of the message being hashed.
-
Crypto.Hash.SHA3_224.
new
(*args, **kwargs)¶ Create a new hash object.
- Parameters
- Return
A
SHA3_224_Hash
hash object