관리-도구
편집 파일: utils.cpython-311.pyc
� �Dg_� � �f � d Z ddlZddlZddlZddlZddlZddlZddlZddlZddl Z ddl Z ddlZddlm Z ddlmZmZ ddlmZ ddlmZ ddlmZmZmZmZ dd lmZmZmZmZmZmZ dd lm Z! ddlm"Z"m#Z#m$Z$m%Z%m&Z&m'Z'm(Z( ddl)m*Z* dd l+m,Z,m-Z-m.Z.m/Z/ ddl0m1Z1 dZ2 ej3 � � Z4ddd�Z5d�6 ej7 d ed�� � d � � � � Z8ej9 dk rd� Z:d� Z"d� Z;d� Z<dJd�Z=d� Z>d � Z?ej@ d!� � � ZAd"� ZBd#� ZCd$� ZDd%� ZEdJd&�ZFd'� ZGd(� ZHd)� ZId*� ZJd+� ZKd,� ZLd-� ZMd.� ZN eOd/� � ZPd0� ZQd1� ZRd2� ZSd3� ZTd4� ZUd5� ZVej@ d6� � � ZWd7� ZXdKd8�ZYd9� ZZdLd:�Z[dMd<�Z\d=� Z]d>� Z^d?�_ d@� � Z`e`dAz Zae`dBz ZbdC� ZcdD� ZddE� ZedF� ZfdG� ZgdH� ZhdI� ZidS )Nz� requests.utils ~~~~~~~~~~~~~~ This module provides utility functions that are used within Requests that are also useful for external consumption. � N)�OrderedDict)�make_headers� parse_url� )�certs��__version__)�_HEADER_VALIDATORS_BYTE�_HEADER_VALIDATORS_STR�HEADER_VALIDATORS�to_native_string)�Mapping� basestring�bytes� getproxies�getproxies_environment� integer_types)�parse_http_list)�proxy_bypass�proxy_bypass_environment�quote�str�unquote�urlparse� urlunparse��cookiejar_from_dict)�FileModeWarning� InvalidHeader� InvalidURL�UnrewindableBodyError)�CaseInsensitiveDict)z.netrc�_netrc�P i� )�http�httpsz, z,\s*T)�accept_encodingzaccept-encoding�win32c �l � dd l }n# t $ r Y dS w xY w |� |j d� � }t |� |d� � d � � }|� |d� � d }n# t t f$ r Y dS w xY w|r|sdS |� d� � }t d |� � }|D ]t}|dk rd| vr d S |� dd � � }|� dd� � }|� d d� � }t j || t j � � r d S �udS )Nr Fz;Software\Microsoft\Windows\CurrentVersion\Internet Settings�ProxyEnable� ProxyOverride�;z<local>�.Tz\.�*z.*�?)�winreg�ImportError�OpenKey�HKEY_CURRENT_USER�int�QueryValueEx�OSError� ValueError�split�filter�replace�re�match�I)�hostr0 �internetSettings�proxyEnable� proxyOverride�tests �z/builddir/build/BUILD/imunify360-venv-2.4.0/opt/imunify360/venv/lib/python3.11/site-packages/pip/_vendor/requests/utils.py�proxy_bypass_registryrD L s� � � ��M�M�M�M��� � � ��5�5� ���� �%�~�~��(�N� � �� �f�1�1�2B�M�R�R�ST�U�V�V�K�"�/�/�0@�/�R�R�ST�U�M�M����$� � � ��5�5� ����� �-� ��5� &�+�+�C�0�0� ��t�]�3�3� �!� � �D��y� � ��d�?�?��4�4��<�<��U�+�+�D��<�<��U�+�+�D��<�<��T�*�*�D��x��d�B�D�)�)� ��t�t� ��us � � ��A A: �:B�Bc �Z � t � � rt | � � S t | � � S )z�Return True, if the host should be bypassed. Checks proxy settings gathered from the environment, if specified, or the registry. )r r rD )r>