%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/lib/python3.9/site-packages/passlib/utils/__pycache__/
Upload File :
Create Path :
Current File : //usr/lib/python3.9/site-packages/passlib/utils/__pycache__/__init__.cpython-39.pyc

a

f�Wc���@sFdZddlmZddlmZmZmZddlm	Z	m
Z
zddlmZddlm
Z
Wn*eyzddlmZddlm
Z
Yn0ddlmZddlmZdd	lZdd	lZdd	lZe�e�Zdd	lZdd	lZdd	lZdd	lZdd	lZe�rzdd	l Z Wne�yd	Z d
Z!Yn0ndd	l Z dd	l"Z"e �r.dd	l#Z#zdd	l$Z$Wne�yRd	Z$Yn0dd	l%Z%dd	l&Z&ddl'm(Z(ddl)m*Z*m+Z+m,Z,m-Z-m.Z.m/Z/m0Z0m1Z1m2Z2m3Z3m4Z4m5Z5m6Z6dd
l7m8Z8m9Z9m:Z:m;Z;m<Z<ddl=m>Z>m?Z?ddlm@Z@mAZAmBZBmCZCmDZDmEZEmFZFmGZGmHZHmIZImJZJmKZKmLZLmMZMmNZNmOZOmPZPgd�ZQeRe�eF�r>ejSnejTd�d�ZUgd�ZVddgZWddl=mXZXdZYeGd�ZZeGd�Z[eRej\�]d��p�d�Z^Gdd�de_�Z`eF�r�ejajbZcedecejajeg�Zfdd�Zgnd d�Zgd�d"d#�Zhd$d%�Zid&d'�ZjejZkzdd(llmmZjWne�yYn0d�d*d+�Znd�d-d.�Zoe d	u�r@d�d/d.�Zod0d1�ZpeF�r`d2d3�Zqd4d5�Zrn dd6lmsZsmtZtd7d3�Zqd8d5�Zre@eqd9�e@erd:�d;d<�Zud=d>�Zvd?d@�ZwdAZxeGdB�Zyd�dCdD�ZzdEdF�Z{dGZ|e|�}dH�Z~dIdJ�ZdKdL�Z�dMZ�eGdN�Z�dOdP�Z�d�dRdS�Z�d�dTdU�Z�eF�r"d�dVdW�Z�n
d�dXdW�Z�e@e�dY�e8dZd[d\�d�d]d^��Z�edd_����Z�edd`����Z�edddag�Z�d�dcdd�Z�dedf�Z�zddgl�m�Z�Wn0e�y�d	Z�d!Z�d!Z�d!Z�d	Z�dhdi�Z�Yn�0djZ�dBZ�e$�reP�rdkej�k�r�dlk�rnne$���Z�djZ�nddmlm�Z�e��Z�d!Z�eGdn�Z�eF�rhdjZ�ze�dodp�Wn"e��yRd!Z�YnYn0dqdi�Z�ndjZ�drdi�Z�e@e�ds�dtdu�Z�e%j�Z�e�Z�dvdw�Z�ze��dx�djZ�Wne��y�d!Z�Yn0d�dydz�Z�e��r�e���Z�ne��e���Z�d{d|�Z�d}d~�Z�dZ�e8d[d�d�d��d�e�fd�d���Z�d�Z�d�d��Z�d�Z�d�d��Z�d�d��Z�d�d��Z�d	S)�z4passlib.utils -- helpers for writing password hashes�)�JYTHON)�
b2a_base64�
a2b_base64�Error)�	b64encode�	b64decode)�Sequence)�Iterable)�lookup)�update_wrapperNznot present under Jython)�warn)
�BASE64_CHARS�
AB64_CHARS�HASH64_CHARS�BCRYPT_CHARS�Base64Engine�LazyBase64Engine�h64�h64big�bcrypt64�ab64_encode�ab64_decode�b64s_encode�b64s_decode)�deprecated_function�deprecated_method�memoized_property�
classproperty�
hybrid_method)�ExpectedStringError�ExpectedTypeError)�add_doc�
join_bytes�join_byte_values�join_byte_elems�irange�imap�PY3�u�join_unicode�unicode�byte_elem_value�
nextgetter�unicode_or_str�unicode_or_bytes_types�get_method_function�suppress_cause�PYPY)r�sys_bits�unix_crypt_schemes�rounds_cost_values�consteq�saslprep�	xor_bytes�render_bytes�
is_same_codec�
is_ascii_safe�to_bytes�
to_unicode�
to_native_str�	has_crypt�
test_crypt�
safe_crypt�tick�rng�getrandbytes�
getrandstr�generate_password�is_crypt_handler�is_crypt_context�has_rounds_info�
has_salt_info�g�?)Zsha512_cryptZsha256_cryptZ
sha1_cryptZbcryptZ	md5_cryptZ
bsdi_cryptZ	des_cryptZlinearZlog2)�MissingBackendError��� ZPASSLIB_MAX_PASSWORD_SIZEic@sHeZdZdZdd�Zdd�Zdd�Zdd	�Zd
d�Zdd
�Z	dd�Z
dS)�
SequenceMixinz�
    helper which lets result object act like a fixed-length sequence.
    subclass just needs to provide :meth:`_as_tuple()`.
    cCstd��dS)Nzimplement in subclass)�NotImplementedError��self�rS�:/usr/lib/python3.9/site-packages/passlib/utils/__init__.py�	_as_tuple�szSequenceMixin._as_tuplecCst|���S�N)�reprrUrQrSrSrT�__repr__�szSequenceMixin.__repr__cCs|��|SrV�rU)rR�idxrSrSrT�__getitem__�szSequenceMixin.__getitem__cCst|���SrV)�iterrUrQrSrSrT�__iter__�szSequenceMixin.__iter__cCst|���SrV)�lenrUrQrSrSrT�__len__�szSequenceMixin.__len__cCs|��|kSrVrY�rR�otherrSrSrT�__eq__�szSequenceMixin.__eq__cCs|�|�SrV)rbr`rSrSrT�__ne__�szSequenceMixin.__ne__N)�__name__�
__module__�__qualname__�__doc__rUrXr[r]r_rbrcrSrSrSrTrO�srOcCsJt�t|��j}|sdS|�|�}|r4|jtvr4dS|t|�djtkS)�*test if function accepts specified keywordFT���)	�inspectZ	signaturer/�
parameters�get�kind�_VAR_ANY_SET�list�_VAR_KEYWORD)�func�key�params�argrSrSrT�accepts_keyword�s
rucCs"t�t|��}||jvp |jduS)rhN)rjZ
getargspecr/�args�keywords)rqrr�specrSrSrTru�sFcs8t|t�r|g}t|j�}|rXt|t�r.|g}|D]$�|rD�|vrDq2�|vr2|���q2|�r$|D]��t�fdd�|D��r~qb|r�t|�D](\}}	t�|	�r�q�|r�t|	|�r�q�q�t|�}nX|�rtt	|��D]:\}
}	t|	|�r�t|�|
}||d|	k�sJ��qq�d}nd}|�
|��qb|�s4t|�|_dS)a
    helper to update mixin classes installed in target class.

    :param target:
        target class whose bases will be modified.

    :param add:
        class / classes to install into target's base class list.

    :param remove:
        class / classes to remove from target's base class list.

    :param append:
        by default, prepends mixins to front of list.
        if True, appends to end of list instead.

    :param after:
        optionally make sure all mixins are inserted after
        this class / classes.

    :param before:
        optionally make sure all mixins are inserted before
        this class / classes.

    :param dryrun:
        optionally perform all calculations / raise errors,
        but don't actually modify the class.
    c3s|]}t|��VqdSrV)�
issubclass)�.0�base�ZmixinrSrT�	<genexpr>�rLz'update_mixin_classes.<locals>.<genexpr>�rN)�
isinstance�typero�	__bases__�remove�any�	enumerateryr^�reversed�insert�tuple)�target�addr��append�beforeZafterZdryrun�basesrZr{Zend_idxrSr|rT�update_mixin_classes�sB





r�ccs�|dkrtd��t|t�rLt|�}d}||kr�||}|||�V|}q&n^t|t�r�t|�}t�||�}zt|�}Wnt	y�Yq�Yn0t�
|f|�Vq^ntd��dS)z8
    split iterable into chunks of <size> elements.
    r~zsize must be positive integerrzsource must be iterableN)�
ValueErrorrrr^r	r\�	itertools�islice�next�
StopIteration�chain�	TypeError)�source�size�end�i�n�itrZ	chunk_itr�firstrSrSrT�batchs$


r�cCs�t|t�r"t|t�std��d}n*t|t�rDt|t�s>td��t}ntd��t|�t|�k}|rh|}d}|st|}d}|r�t||�D]\}}|||AO}q�n(t||�D]\}}|t|�t|�AO}q�|dkS)a�Check two strings/bytes for equality.

    This function uses an approach designed to prevent
    timing analysis, making it appropriate for cryptography.
    a and b must both be of the same type: either str (ASCII only),
    or any type that supports the buffer protocol (e.g. bytes).

    Note: If a and b are of different lengths, or if an error occurs,
    a timing attack could theoretically reveal information about the
    types and lengths of a and b--but not their values.
    z)inputs must be both unicode or both bytesFrr~)rr*r��bytesr'r^�zip�ord)�left�rightZis_py3_bytesZ	same_size�tmp�result�l�rrSrSrTr5;s,



r5)�compare_digest�,cCs:|��}|�|�r|dd�}|s&gSdd�|�|�D�S)zRsplit comma-separated string into list of elements,
    stripping whitespace.
    NricSsg|]}|���qSrS)�strip�rz�elemrSrSrT�
<listcomp>�rLzsplitcomma.<locals>.<listcomp>)r��endswith�split)r��seprSrSrT�
splitcomma�s
r��valuecs�t|t�stdt|�f��tj�tj�t��fdd�|D��}t�	d|�}|sTt
Stj}||d�r�||d�s~td|��tj
}n|}tj}tj}tj}tj}tj}	tj}
tj}tj}tj}
|D]�}�|�r�Jd���|�r�Jd	��||�r�td
|��||��rtd|��||��r(td|��||��r>td
|��|	|��rTtd|��|
|��rjtd|��||��r�td|��||��r�td|��|
|��r�td|��||�r�td|��q�|S)aNormalizes unicode strings using SASLPrep stringprep profile.

    The SASLPrep profile is defined in :rfc:`4013`.
    It provides a uniform scheme for normalizing unicode usernames
    and passwords before performing byte-value sensitive operations
    such as hashing. Among other things, it normalizes diacritic
    representations, removes non-printing characters, and forbids
    invalid characters such as ``\n``. Properly internationalized
    applications should run user passwords through this function
    before hashing.

    :arg source:
        unicode string to normalize & validate

    :param param:
        Optional noun identifying source parameter in error messages
        (Defaults to the string ``"value"``). This is mainly useful to make the caller's error
        messages make more sense contextually.

    :raises ValueError:
        if any characters forbidden by the SASLPrep profile are encountered.

    :raises TypeError:
        if input is not :class:`!unicode`

    :returns:
        normalized unicode string

    .. note::

        This function is not available under Jython,
        as the Jython stdlib is missing the :mod:`!stringprep` module
        (`Jython issue 1758320 <http://bugs.jython.org/issue1758320>`_).

    .. versionadded:: 1.6
    z$input must be unicode string, not %sc3s&|]}�|�s�|�rtn|VqdSrV)�_USPACE�rz�c��in_table_b1�in_table_c12rSrTr}�s�zsaslprep.<locals>.<genexpr>�NFKCrrizmalformed bidi sequence in z$failed to strip B.1 in mapping stagez(failed to replace C.1.2 in mapping stagez$unassigned code points forbidden in z control characters forbidden in z$private use characters forbidden in z"non-char code points forbidden in zsurrogate codes forbidden in z!non-plaintext chars forbidden in z!non-canonical chars forbidden in z1display-modifying / deprecated chars forbidden inztagged characters forbidden in zforbidden bidi character in )rr*r�r��
stringprepr�r�r)�unicodedata�	normalize�_UEMPTYZin_table_d1r�Zin_table_d2�in_table_a1�in_table_c21_c22�in_table_c3�in_table_c4�in_table_c5�in_table_c6�in_table_c7�in_table_c8�in_table_c9)r��param�dataZis_ral_charZis_forbidden_bidi_charr�r�r�r�r�r�r�r�r�r�rSr�rTr6�sj,
��






�
r6cCstdt��dS)zstub for saslprep()z>saslprep() support requires the 'stringprep' module, which is N)rP�_stringprep_missing_reason)r�r�rSrSrTr6s�cGs4t|t�r|�d�}|tdd�|D��}|�d�S)a�Peform ``%`` formating using bytes in a uniform manner across Python 2/3.

    This function is motivated by the fact that
    :class:`bytes` instances do not support ``%`` or ``{}`` formatting under Python 3.
    This function is an attempt to provide a replacement:
    it converts everything to unicode (decoding bytes instances as ``latin-1``),
    performs the required formatting, then encodes the result to ``latin-1``.

    Calling ``render_bytes(source, *args)`` should function roughly the same as
    ``source % args`` under Python 2.

    .. todo::
        python >= 3.5 added back limited support for bytes %,
        can revisit when 3.3/3.4 is dropped.
    �latin-1css&|]}t|t�r|�d�n|VqdS)r�N)rr��decode)rzrtrSrSrTr},s�zrender_bytes.<locals>.<genexpr>)rr�r�r��encode)r�rvr�rSrSrTr8s


�
r8cCst�|d�S�NZbig)�int�
from_bytes�r�rSrSrT�bytes_to_int2sr�cCs|�|d�Sr�)r;�r��countrSrSrT�int_to_bytes4sr�)�hexlify�	unhexlifycCstt|�d�S)N�)r�r�r�rSrSrTr�9scCstd|d>|�S)Nz%%0%dxr~)r�r�rSrSrTr�;sz/decode byte string as single big-endian integerz/encode integer as single big-endian byte stringcCstt|�t|�At|��S)z;Perform bitwise-xor of two byte strings (must be same size))r�r�r^�r�r�rSrSrTr7Asr7cCs$d|dt|�}||d|�S)zE
    repeat or truncate <source> string, so it has length <size>
    r~N)r^�r�r�ZmultrSrSrT�
repeat_stringEsr�cCs"d|dt|�}t|||�S)zN
    variant of repeat_string() which truncates to nearest UTF8 boundary.
    r~)r^�
utf8_truncater�rSrSrT�utf8_repeat_stringMsr���cCsJt|�}||kr:|dur*t|t�r&tnt}||||S|d|�SdS)z>right-pad or truncate <source> string, so it has length <size>N)r^rr*�_UNULL�_BNULL)r�r�ZpadZcurrSrSrT�right_pad_stringXsr�cs�t�t�st�td��t��}|dkr4td||�}||kr@�St|d|�}||krvt�|�d@dkrlq�|d7}qN||ks�J��d|����fdd	�}|�s�J��S)
a�
    helper to truncate UTF8 byte string to nearest character boundary ON OR AFTER <index>.
    returned prefix will always have length of at least <index>, and will stop on the
    first byte that's not a UTF8 continuation byte (128 - 191 inclusive).
    since utf8 should never take more than 4 bytes to encode known unicode values,
    we can stop after ``index+3`` is reached.

    :param bytes source:
    :param int index:
    :rtype: bytes
    r�r���r~Ncs<z��d�}Wnty"YdS0|���d��s8J�dS)N�utf-8T)r��UnicodeDecodeError�
startswith)�text�r�r�rSrT�sanity_check�sz#utf8_truncate.<locals>.sanity_check)rr�r r^�max�minr+)r��indexr�r�rSr�rTr�cs"


r�s	
 aA:#!�asciicCst�|�tkS)zRTest if codec is compatible with 7-bit ascii (e.g. latin-1, utf-8; but not utf-16))�_ASCII_TEST_UNICODEr��_ASCII_TEST_BYTES)�codecrSrSrT�is_ascii_codec�sr�cCs,||krdS|r|sdSt|�jt|�jkS)z3Check if two codec names are aliases for same codecTF)�
_lookup_codec�namer�rSrSrTr9�s
r9r��€cs(t|t�rtnt�t�fdd�|D��S)z<Check if string (bytes or unicode) contains only 7-bit asciic3s|]}|�kVqdSrVrSr��r�rSrTr}�rLz is_ascii_safe.<locals>.<genexpr>)rr��_B80�_U80�all)r�rSr�rTr:�sr:r�cCsX|sJ�t|t�r6|r0t||�s0|�|��|�S|Snt|t�rJ|�|�St||��dS)aHelper to normalize input to bytes.

    :arg source:
        Source bytes/unicode to process.

    :arg encoding:
        Target encoding (defaults to ``"utf-8"``).

    :param param:
        Optional name of variable/noun to reference when raising errors

    :param source_encoding:
        If this is specified, and the source is bytes,
        the source will be transcoded from *source_encoding* to *encoding*
        (via unicode).

    :raises TypeError: if source is not unicode or bytes.

    :returns:
        * unicode strings will be encoded using *encoding*, and returned.
        * if *source_encoding* is not specified, byte strings will be
          returned unchanged.
        * if *source_encoding* is specified, byte strings will be transcoded
          to *encoding*.
    N)rr�r9r�r�r*r)r��encodingr�Zsource_encodingrSrSrTr;�s


r;cCs8|sJ�t|t�r|St|t�r*|�|�St||��dS)a�Helper to normalize input to unicode.

    :arg source:
        source bytes/unicode to process.

    :arg encoding:
        encoding to use when decoding bytes instances.

    :param param:
        optional name of variable/noun to reference when raising errors.

    :raises TypeError: if source is not unicode or bytes.

    :returns:
        * returns unicode strings unchanged.
        * returns bytes strings decoded using *encoding*
    N)rr*r�r�r�r�r�r�rSrSrTr<�s


r<cCs0t|t�r|�|�St|t�r"|St||��dSrV)rr�r�r*rr�rSrSrTr=�s



r=cCs0t|t�r|St|t�r"|�|�St||��dSrV)rr�r*r�rr�rSrSrTr=s



a>Take in unicode or bytes, return native string.

    Python 2: encodes unicode using specified encoding, leaves bytes alone.
    Python 3: leaves unicode alone, decodes bytes using specified encoding.

    :raises TypeError: if source is not unicode or bytes.

    :arg source:
        source unicode or bytes string.

    :arg encoding:
        encoding to use when encoding unicode or decoding bytes.
        this defaults to ``"utf-8"``.

    :param param:
        optional name of variable/noun to reference when raising errors.

    :returns: :class:`str` instance
    z1.6z1.7)�
deprecated�removedcCst||dd�S)z'deprecated, use to_native_str() instead�hash)r�)r=)r�r�rSrSrT�to_hash_str$sr�z true t yes y on 1 enable enabledz#false f no n off 0 disable disabled�none�booleancCs~|dvsJ�t|t�rX|����}|tvr.dS|tvr:dS|tvrF|Std||f��n"t|t�rf|S|durr|St|�SdS)z\
    helper to convert value to boolean.
    recognizes strings such as "true", "false"
    )TFNTFzunrecognized %s value: %rN)	rr.�lowerr��	_true_set�
_false_set�	_none_setr��bool)r�r�r�ZcleanrSrSrT�as_bool-s

rcCs<tst|t�sdSz|�d�WdSty6YdS0dS)z�
    UT helper --
    test if value is safe to pass to crypt.crypt();
    under PY3, can't pass non-UTF8 bytes to crypt.crypt.
    Tr�FN)�crypt_accepts_bytesrr�r�r�r�rSrSrT�is_safe_crypt_inputGs
r)�cryptcCsdSrVrS��secretr�rSrSrTr@]sr@T)�rJr)rr�r�)�nullcontextz*:!���xxcCs$tr>t|t�r|�d�}t|vr(td��t|t�r�|�d�}nlt|t�r�|}z|�d�}WntynYdS0|�d�|ks�Jd��t	|vr�td��t|t�r�|�d�}z2t
�t||�}Wd�n1s�0YWnty�YdS0t|t��r|�d�}|�r|dt
v�r dS|S)Nr��null character in secretr�z"utf-8 spec says this can't happen!r)rrr*r�r�r�r�r�r��_NULL�_safe_crypt_lock�_crypt�OSError�_invalid_prefixes)r
r�Zorigr�rSrSrTr@�s<



�

,
cCs�t|t�r|�d�}t|vr$td��t|t�r8|�d�}t�t||�}Wd�n1s\0Y|sndS|�d�}|dtvr�dS|S)Nr�rr�r)	rr*r�rr�rrr�r)r
r�r�rSrSrTr@�s



(
a�Wrapper around stdlib's crypt.

    This is a wrapper around stdlib's :func:`!crypt.crypt`, which attempts
    to provide uniform behavior across Python 2 and 3.

    :arg secret:
        password, as bytes or unicode (unicode will be encoded as ``utf-8``).

    :arg hash:
        hash or config string, as ascii bytes or unicode.

    :returns:
        resulting hash as ascii unicode; or ``None`` if the password
        couldn't be hashed due to one of the issues:

        * :func:`crypt()` not available on platform.

        * Under Python 3, if *secret* is specified as bytes,
          it must be use ``utf-8`` or it can't be passed
          to :func:`crypt()`.

        * Some OSes will return ``None`` if they don't recognize
          the algorithm being used (though most will simply fall
          back to des-crypt).

        * Some OSes will return an error string if the input config
          is recognized but malformed; current code converts these to ``None``
          as well.
    cCs4t|t�sJdt|���|s&Jd��t||�|kS)z�check if :func:`crypt.crypt` supports specific hash
    :arg secret: password to test
    :arg hash: known hash of password to use as reference
    :returns: True or False
    z#hash must be unicode_or_str, got %szhash must be non-empty)rr-r�r@r	rSrSrTr?�s


�r?cCs2t�d|�}|r.tdd�|�d��d�D��SdS)zhelper to parse version stringz(\d+(?:\.\d+)+)css|]}t|�VqdSrV)r�r�rSrSrTr}�rLz parse_version.<locals>.<genexpr>r~�.N)�re�searchr��groupr�)r��mrSrSrT�
parse_version�srr~c	Cs�ddlm}t|d�rJt|d�rJz|��}WntyH|�d�}Yn0td�|ttd�rdt��ndt	t
��t��t�t
r�t�d	��d
�ndf}t||�d����d�S)
z.generate prng seed value from system resourcesr)�sha512�getstate�getrandbitsi�z%s %s %s %.15f %.15f %s�getpidN� r�r�r�)Zhashlibr�hasattrrrPrr(�osr�id�object�timerA�has_urandom�urandomr�r�r��	hexdigest)r�rr�rSrSrT�genseeds�r(cs �stS��fdd�}t|��S)z]return byte-string containing *count* number of randomly generated bytes, using specified rngc3s:���d>�}d}|�kr6|d@V|dL}|d7}qdS)Nr�r�r~)r�r�r��r�rBrSrT�helperMs
zgetrandbytes.<locals>.helper)�_BEMPTYr#)rBr�r,rSr+rTrCBs	rCcsl�dkrtd��t����dkr(td���dkr8��S����fdd�}t�t�r^t|��St|��SdS)z|return string containing *count* number of chars/bytes, whose elements are drawn from specified charset, using specified rngrzcount must be >= 0zalphabet must not be emptyr~c3s@��d���}d}|�kr<�|�V|�}|d7}qdS)Nrr~)Z	randranger*��charsetr�ZlettersrBrSrTr,fszgetrandstr.<locals>.helperN)r�r^rr*r)r$)rBr/r�r,rSr.rTrDWs	

rDZ42346789ABCDEFGHJKMNPQRTUVWXYZabcdefghjkmnpqrstuvwxyzz2.0z/passlib.pwd.genword() / passlib.pwd.genphrase())r�r�Zreplacement�
cCstt||�S)awgenerate random password using given length & charset

    :param size:
        size of password.

    :param charset:
        optional string specified set of characters to draw from.

        the default charset contains all normal alphanumeric characters,
        except for the characters ``1IiLl0OoS5``, which were omitted
        due to their visual similarity.

    :returns: :class:`!str` containing randomly generated password.

    .. note::

        Using the default character set, on a OS with :class:`!SystemRandom` support,
        this function should generate passwords with 5.7 bits of entropy per character.
    )rDrB)r�r/rSrSrTrEvsrE)r��setting_kwdsZcontext_kwds�verifyr��identifycst�fdd�tD��S)z4check if object follows the :ref:`password-hash-api`c3s|]}t�|�VqdSrV�r �rzr���objrSrTr}�rLz#is_crypt_handler.<locals>.<genexpr>)r��_handler_attrsr6rSr6rTrF�srF)Zneeds_updateZ	genconfigZgenhashr2Zencryptr3cst�fdd�tD��S)zOcheck if object appears to be a :class:`~passlib.context.CryptContext` instancec3s|]}t�|�VqdSrVr4r5r6rSrTr}�rLz#is_crypt_context.<locals>.<genexpr>)r��_context_attrsr6rSr6rTrG�srGcCsd|jvot|dd�duS)z_check if handler provides the optional :ref:`rounds information <rounds-attributes>` attributes�roundsZ
min_roundsN�r1�getattr�ZhandlerrSrSrTrH�s
�rHcCsd|jvot|dd�duS)z[check if handler provides the optional :ref:`salt information <salt-attributes>` attributesZsaltZ
min_salt_sizeNr;r=rSrSrTrI�s
�rI)NNFNNF)r�)r�)r�)N)r�r�N)r�r�)r�r�)r�r�)r�)Nr�)N)�rgZpasslib.utils.compatrZbinasciirrrZ_BinAsciiError�base64rr�collections.abcrr	�ImportError�collections�codecsr
r��	functoolsrr�rjZloggingZ	getLoggerrd�logZmathr!�sysZrandomrr�r�r$r��	threadingZtimeit�types�warningsrZpasslib.utils.binaryr
rrrrrrrrrrrrZpasslib.utils.decorrrrrrZpasslib.excrr r!r"r#r$r%r&r'r(r)r*r+r,r-r.r/r0r1�__all__r��maxsizeZmaxintr2r3r4rKr-r�r��environrlZMAX_PASSWORD_SIZEr#rOZ	ParameterZVAR_KEYWORDrp�setZVAR_POSITIONALrnrur�r�r5Zstr_consteqZhmacr�r�r6r8r�r�r�r�r7r�r�r�r�r�r�r�r�r�r�r9r�r�r:r;r<r=r�r�rrrrrrrr>rZcrypt_needs_lockrr@rZpypy_version_info�Lockrrr�r?Z
default_timerZtimerrArr&r%rPr(ZSystemRandomrBZRandomrCrDZ
_52charsetrEr8rFr9rGrHrIrSrSrSrT�<module>sH
<L."	

�
W>







F

%

�

*
/



!
�


Zerion Mini Shell 1.0