g7 d dl mZ d dlmZmZ d dlmZ d dlmZm Z m
Z
mZmZm
Z
mZ edd Z G d de Zd Zd
S ) ) unhexlify)bordtobytes)get_random_bytes)load_pycryptodome_raw_libVoidPointerSmartPointercreate_string_bufferget_raw_bufferc_size_tc_uint8_ptrzCrypto.Hash._BLAKE2sa
int blake2s_init(void **state,
const uint8_t *key,
size_t key_size,
size_t digest_size);
int blake2s_destroy(void *state);
int blake2s_update(void *state,
const uint8_t *buf,
size_t len);
int blake2s_digest(const void *state,
uint8_t digest[32]);
int blake2s_copy(const void *src, void *dst);
c @ e Zd ZdZdZd Zd Zd Zd Zd Z d Z
d Zd
S )BLAKE2s_Hasha A BLAKE2s hash object.
Do not instantiate directly. Use the :func:`new` function.
:ivar oid: ASN.1 Object ID
:vartype oid: string
:ivar block_size: the size in bytes of the internal message block,
input to the compression function
:vartype block_size: integer
:ivar digest_size: the size in bytes of the resulting hash
:vartype digest_size: integer
c || _ || _ d| _ |dv r|sdt | z | _ t }t | t | t t | t | }|rt d|z t | t j | _ |r| | d S d S )NF) r z1.3.6.1.4.1.1722.12.2.2.z$Error %d while instantiating BLAKE2s)digest_size_update_after_digest_digest_donestroidr _raw_blake2s_libblake2s_init
address_ofr
r len
ValueErrorr getblake2s_destroy_stateupdate)selfdatakeydigest_bytesupdate_after_digeststateresults u/builddir/build/BUILD/imunify360-venv-2.6.2/opt/imunify360/venv/lib64/python3.11/site-packages/Crypto/Hash/BLAKE2s.py__init__zBLAKE2s_Hash.__init__L s ($7!! +++C+1C4E4EEDH
!..u/?/?/A/A/:3/?/?/7C/A/A/7/E/E1 1
NCfLMMM"599;;#3#CE E KK c | j r| j st d t | j t | t t | }|rt d|z | S )zContinue hashing of a message by consuming the next chunk of data.
Args:
data (byte string/byte array/memoryview): The next chunk of the message being hashed.
z8You can only call 'digest' or 'hexdigest' on this objectz#Error %d while hashing BLAKE2s data)r r TypeErrorr blake2s_updater! r r
r r r )r# r$ r) s r* r" zBLAKE2s_Hash.updatef s XT%> XVWWW!001B1B1