+
    ÝÆi  ã                  óÖ   € R t ^ RIHt ^ RIHt ^ RIHtHt ^ RIH	t	H
t
 ^RIHtHtHt . ROt]
P                   t  ! R R]4      t]3R R	 llt]3R
 R lltR R ltR R ltR R ltR# )a>  
Low-level functions if you want to build your own higher level abstractions.

.. warning::
    This is a "Hazardous Materials" module.  You should **ONLY** use it if
    you're 100% absolutely sure that you know what you're doing because this
    module is full of land mines, dragons, and dinosaurs with laser guns.
)Úannotations)ÚEnum)ÚAnyÚLiteral)ÚffiÚlib)ÚHashingErrorÚVerificationErrorÚVerifyMismatchErrorÚTypec                  ób   € ] tR t^(tRt]P                  t]P                  t	]P                  tRtR# )r   zL
Enum of Argon2 variants.

Please see :doc:`parameters` on how to pick one.
© N)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   ÚArgon2_dÚDÚArgon2_iÚIÚ	Argon2_idÚIDÚ__static_attributes__r   ó    Ú5/usr/lib/python3.14/site-packages/argon2/low_level.pyr   r   (   s$   † ñð 	�‰€AØ�‰€AØ	�‰„Br   c               ó<   € V ^8„  d   QhRRRRRRRRRRRRR	R
RRRR/	# ©é   ÚsecretÚbytesÚsaltÚ	time_costÚintÚmemory_costÚparallelismÚhash_lenÚtyper   ÚversionÚreturnr   )Úformats   "r   Ú__annotate__r+   4   sm   € ÷ Dñ DØðDà
ðDð ðDð ð	Dð
 ðDð ðDð ðDð ðDð ñDr   c                ó  € \         P                  ! VVV\        V4      VVP                  4      ^,           p\        P
                  ! RV4      p	\         P                  ! VVV\        P
                  ! RV 4      \        V 4      \        P
                  ! RV4      \        V4      \        P                  VV	VVP                  V4      p
V
\         P                  8w  d   \        \        V
4      4      h\        P                  ! V	4      # )ae  
Hash *secret* and return an **encoded** hash.

An encoded hash can be directly passed into :func:`verify_secret` as it
contains all parameters and the salt.

Args:
    secret: Secret to hash.

    salt: A salt_. Should be random and different for each secret.

    type: Which Argon2 variant to use.

    version: Which Argon2 version to use.

For an explanation of the Argon2 parameters see
:class:`argon2.PasswordHasher`.

Returns:
    An encoded Argon2 hash.

Raises:
    argon2.exceptions.HashingError: If hashing fails.

.. versionadded:: 16.0.0

.. _salt: https://en.wikipedia.org/wiki/Salt_(cryptography)
úchar[]ú	uint8_t[])r   Úargon2_encodedlenÚlenÚvaluer   ÚnewÚargon2_hashÚNULLÚ	ARGON2_OKr   Úerror_to_strÚstring)r   r!   r"   r$   r%   r&   r'   r(   ÚsizeÚbufÚrvs   &&&&&&&&   r   Úhash_secretr;   4   sÕ   € ôN 	×ÒØØØÜ�‹IØØ�J‰Jó	
ð õ	ð 	ô �'Š'�(˜DÓ
!€CÜ	�ŠØØØÜ�Š�˜VÓ$ÜˆF‹Ü�Š�˜TÓ"ÜˆD‹	Ü�‰ØØØØ�
‰
Øó
€Bð 
ŒS�]‰]ÔÜœ<¨Ó+Ó,Ð,ä�:Š:�c‹?Ðr   c               ó<   € V ^8„  d   QhRRRRRRRRRRRRR	R
RRRR/	# r   r   )r*   s   "r   r+   r+   {   sb   € ÷ %,ñ %,Øð%,à
ð%,ð ð%,ð ð	%,ð
 ð%,ð ð%,ð ð%,ð ð%,ð ñ%,r   c                ó¬  € \         P                  ! RV4      p\        P                  ! VVV\         P                  ! RV 4      \	        V 4      \         P                  ! RV4      \	        V4      VV\         P
                  ^ VP                  V4      p	V	\        P                  8w  d   \        \        V	4      4      h\        \         P                  ! W…4      4      # )z‡
Hash *password* and return a **raw** hash.

This function takes the same parameters as :func:`hash_secret`.

.. versionadded:: 16.0.0
r.   )r   r2   r   r3   r0   r4   r1   r5   r   r6   r    Úbuffer)
r   r!   r"   r$   r%   r&   r'   r(   r9   r:   s
   &&&&&&&&  r   Úhash_secret_rawr?   {   s¡   € ô" �'Š'�+˜xÓ
(€Cä	�ŠØØØÜ�Š�˜VÓ$ÜˆF‹Ü�Š�˜TÓ"ÜˆD‹	ØØÜ�‰Ø	Ø�
‰
Øó
€Bð 
ŒS�]‰]ÔÜœ<¨Ó+Ó,Ð,ä”—’˜CÓ*Ó+Ð+r   c               ó(   € V ^8„  d   QhRRRRRRRR/# )r   Úhashr    r   r'   r   r)   zLiteral[True]r   )r*   s   "r   r+   r+   £   s(   € ÷ +.ñ +.˜ð +. uð +.°Dð +.¸]ñ +.r   c                óV  € \         P                  ! \        P                  ! RV 4      \        P                  ! RV4      \	        V4      VP
                  4      pV\         P                  8X  d   R# V\         P                  8X  d   \        \        V4      4      h\        \        V4      4      h)aî  
Verify whether *secret* is correct for *hash* of *type*.

Args:
    hash:
        An encoded Argon2 hash as returned by :func:`hash_secret`.

    secret:
        The secret to verify whether it matches the one in *hash*.

    type: Type for *hash*.

Raises:
    argon2.exceptions.VerifyMismatchError:
        If verification fails because *hash* is not valid for *secret* of
        *type*.

    argon2.exceptions.VerificationError:
        If verification fails for other reasons.

Returns:
    ``True`` on success, raise :exc:`~argon2.exceptions.VerificationError`
    otherwise.

.. versionadded:: 16.0.0
.. versionchanged:: 16.1.0
    Raise :exc:`~argon2.exceptions.VerifyMismatchError` on mismatches
    instead of its more generic superclass.
r-   r.   T)r   Úargon2_verifyr   r2   r0   r1   r5   ÚARGON2_VERIFY_MISMATCHr
   r6   r	   )rA   r   r'   r:   s   &&& r   Úverify_secretrE   £   s}   € ô< 
×	Ò	Ü�Š�˜$ÓÜ�Š�˜VÓ$ÜˆF‹Ø�
‰
ó	
€Bð 
ŒS�]‰]ÔÙà	ŒS×'Ñ'Ô'Ü!¤,¨rÓ"2Ó3Ð3ä
œL¨Ó,Ó
-Ð-r   c               ó$   € V ^8„  d   QhRRRRRR/# )r   Úcontextr   r'   r#   r)   r   )r*   s   "r   r+   r+   Ñ   s!   € ÷ )ñ )�#ð )˜Sð ) Sñ )r   c                ó.   € \         P                  ! W4      # )aR  
Direct binding to the ``argon2_ctx`` function.

.. warning::
    This is a strictly advanced function working on raw C data structures.
    Both Argon2's and *argon2-cffi*'s higher-level bindings do a lot of
    sanity checks and housekeeping work that *you* are now responsible for
    (e.g. clearing buffers). The structure of the *context* object can,
    has, and will change with *any* release!

    Use at your own peril; *argon2-cffi* does *not* use this binding
    itself.

Args:
    context:
        A CFFI Argon2 context object (i.e. an ``struct Argon2_Context`` /
        ``argon2_context``).

    type:
        Which Argon2 variant to use.  You can use the ``value`` field of
        :class:`Type`'s fields.

Returns:
    An Argon2 error code.  Can be transformed into a string using
    :func:`error_to_str`.

.. versionadded:: 16.0.0
)r   Ú
argon2_ctx)rG   r'   s   &&r   ÚcorerJ   Ñ   s   € ô: �>Š>˜'Ó(Ð(r   c               ó    € V ^8„  d   QhRRRR/# )r   Úerrorr#   r)   Ústrr   )r*   s   "r   r+   r+   ñ   s   € ÷ Gñ G˜ð G ñ Gr   c                ót   € \         P                  ! \        P                  ! V 4      4      P	                  R4      # )zÎ
Convert an Argon2 error code into a native string.

Args:
    error: An Argon2 error code as returned by :func:`core`.

Returns:
    A human-readable string describing the error.

.. versionadded:: 16.0.0
Úascii)r   r7   r   Úargon2_error_messageÚdecode)rL   s   &r   r6   r6   ñ   s)   € ô �:Š:”c×.Ò.¨uÓ5Ó6×=Ñ=¸gÓFÐFr   N)ÚARGON2_VERSIONr   r   r;   r?   rE   )r   Ú
__future__r   Úenumr   Útypingr   r   Ú_argon2_cffi_bindingsr   r   Ú
exceptionsr   r	   r
   Ú__all__ÚARGON2_VERSION_NUMBERrR   r   r;   r?   rE   rJ   r6   r   r   r   Ú<module>rZ      sl   ðñõ #å ß ç *ç LÑ Lò€ð ×*Ñ*€ðô	ˆ4ô 	ð( "÷Dð^ "÷%,õP+.õ\)÷@Gr   