관리-도구
편집 파일: hmac.cpython-37.opt-2.pyc
B YI~du � @ s� d dl Zd dlmZ yd dlZW n ek r< dZdZY nX e ej �Zd dlZedd� e d�D ��Zedd� e d�D ��ZdZG dd� d�Zd d d �Zdd� ZdS )� N)�_compare_digestc c s | ]}|d A V qdS )�\ N� )�.0�xr r �)/opt/alt/python37/lib64/python3.7/hmac.py� <genexpr> s r � c c s | ]}|d A V qdS )�6 Nr )r r r r r r s c @ sN e Zd ZdZddd�Zedd� �Zdd� Zd d � Zdd� Z d d� Z dd� ZdS )�HMAC�@ Nc sV t |ttf�s tdt|�j ��� d kr<t�dtd� t j � t� �rL� | _n,t � t �rhd � fdd� | _nd� fdd� | _| �� | _| �� | _| jj| _t| jd�r�| jj}|d k r�t�d || jf td� | j}nt�d| j td� | j}|| _t|�|k�r| �|��� }|�|d�}| j�|�t�� | j�|�t�� |d k �rR| �|� d S )Nz,key: expected bytes or bytearray, but got %rzhHMAC() without an explicit digestmod argument is deprecated since Python 3.4, and will be removed in 3.8� � c s t �� | �S )N)�_hashlib�new)�d)� digestmodr r �<lambda>= r zHMAC.__init__.<locals>.<lambda>c s � � | �S )N)r )r )r r r r ? r � block_size� z:block_size of %d seems too small; using our default of %d.z<No block_size attribute on given digest object; Assuming %d.� )r )r )� isinstance�bytes� bytearray� TypeError�type�__name__� _warnings�warn�DeprecationWarningr Zmd5�callable�digest_cons�str�outer�inner�digest_size�hasattrr � blocksize�RuntimeWarning�len�digest�ljust�update� translate�trans_5C�trans_36)�self�key�msgr r'