HEX
Server: LiteSpeed
System: Linux php-prod-1.spaceapp.ru 5.15.0-157-generic #167-Ubuntu SMP Wed Sep 17 21:35:53 UTC 2025 x86_64
User: xnsbb3110 (1041)
PHP: 8.1.33
Disabled: NONE
Upload Files
File: //usr/local/CyberCP/lib/python3.10/site-packages/nacl/__pycache__/utils.cpython-310.pyc
o

�h%	�	@s�ddlZddlmZmZmZddlZddlmZeddd�ZGdd�de	�Z
Gdd	�d	�Zd
e	defdd
�Z
ddede	fdd�Zejfdede	dejde	fdd�ZdS)�N)�
SupportsBytes�Type�TypeVar)�encoding�_EncryptedMessage�EncryptedMessage)�boundc@sleZdZUdZeed<eed<edeededededef
d	d
��Z	e
defdd��Ze
defd
d��ZdS)rze
    A bytes subclass that holds a messaged that has been encrypted by a
    :class:`SecretBox`.
    �_nonce�_ciphertext�cls�nonce�
ciphertext�combined�returncCs||�}||_||_|S�N)r	r
)rrr
r�obj�r�=/usr/local/CyberCP/lib/python3.10/site-packages/nacl/utils.py�_from_parts"szEncryptedMessage._from_partscC�|jS)zX
        The nonce used during the encryption of the :class:`EncryptedMessage`.
        )r	��selfrrrr.�zEncryptedMessage.noncecCr)zP
        The ciphertext contained within the :class:`EncryptedMessage`.
        )r
rrrrr
5rzEncryptedMessage.ciphertextN)
�__name__�
__module__�__qualname__�__doc__�bytes�__annotations__�classmethodrrr�propertyrr
rrrrrs(
�����c@seZdZdedefdd�ZdS)�StringFixerrrcCst|���Sr)�str�	__bytes__rrrr�__str__>szStringFixer.__str__N)rrrrr"r$rrrrr!=sr!�bytes_inrcCs
|�d�S)N�ascii)�decode)r%rrr�bytes_as_stringB�
r(� �sizecCs
t�|�Sr)�os�urandom)r+rrr�randomFr)r.�seed�encodercCstj�||�}|�|�S)z�
    Returns ``size`` number of deterministically generated pseudorandom bytes
    from a seed

    :param size: int
    :param seed: bytes
    :param encoder: The encoder class used to encode the produced bytes
    :rtype: bytes
    )�nacl�bindings�randombytes_buf_deterministic�encode)r+r/r0�raw_datarrr�randombytes_deterministicJs
r6)r*)r,�typingrrr�
nacl.bindingsr1rrrrr!r"r(�intr.�
RawEncoder�Encoderr6rrrr�<module>s&$�����