관리-도구
편집 파일: KMAC256.cpython-311.pyc
� O�DgZ � �0 � d dl mZ ddlmZ ddlmZ d� ZdS )� )�is_bytes� )� KMAC_Hash)� cSHAKE256c �� � | � dd� � }t |� � st d� � �t |� � dk rt d� � �| � dd� � }| � dd� � }|d k rt d � � �| � dd� � }| rt d t | � � z � � �t ||||dt d� � S )a� Create a new KMAC256 object. Args: key (bytes/bytearray/memoryview): The key to use to compute the MAC. It must be at least 256 bits long (32 bytes). data (bytes/bytearray/memoryview): Optional. The very first chunk of the message to authenticate. It is equivalent to an early call to :meth:`KMAC_Hash.update`. mac_len (integer): Optional. The size of the authentication tag, in bytes. Default is 64. Minimum is 8. custom (bytes/bytearray/memoryview): Optional. A customization byte string (``S`` in SP 800-185). Returns: A :class:`KMAC_Hash` hash object �keyNzYou must pass a key to KMAC256� z1The key must be at least 256 bits long (32 bytes)�data�mac_len�@ � z!'mac_len' must be 8 bytes or more�custom� zUnknown parameters: �20� )�popr � TypeError�len� ValueError�strr r )�kwargsr r r r s �u/builddir/build/BUILD/imunify360-venv-2.4.0/opt/imunify360/venv/lib64/python3.11/site-packages/Crypto/Hash/KMAC256.py�newr % s� � �( �*�*�U�D� !� !�C��C�=�=� :��8�9�9�9� �3�x�x�"�}�}��L�M�M�M��:�:�f�d�#�#�D��j�j��B�'�'�G���{�{��<�=�=�=� �Z�Z��#� &� &�F� � >��.��V���<�=�=�=��T�3����y�#�F�F�Fr N)�Crypto.Util.py3compatr �KMAC128r � r r � r r �<module>r s[ ��>