/usr/lib/python3.9/site-packages/requests/__pycache__
Edit: /usr/lib/python3.9/site-packages/requests/__pycache__/auth.cpython-39.pyc (8283B)
a
¥/�hß' ã @ sÌ d Z ddlZddlZddlZddlZddlZddlZddlmZ ddl m
Z
mZmZ ddl
mZ ddlmZ ddlmZ d Zd
Zdd„ ZG d
d„ deƒZG dd„ deƒZG dd„ deƒZG dd„ deƒZdS )z]
requests.auth
~~~~~~~~~~~~~
This module contains the authentication handlers for Requests.
é N)Ú b64encodeé )ÚurlparseÚstrÚ
basestring)Úextract_cookies_to_jar)Úto_native_string)Úparse_dict_headerz!application/x-www-form-urlencodedzmultipart/form-datac C sš t | tƒs&tjd | ¡td� t| ƒ} t |tƒsPtjd t|ƒ¡td� t|ƒ}t | tƒrd| d¡} t |tƒrx| d¡}dt t
d | |f¡ƒ ¡ ƒ }|S )zReturns a Basic Auth string.z·Non-string usernames will no longer be supported in Requests 3.0.0. Please convert the object you've passed in ({!r}) to a string or bytes object in the near future to avoid problems.)Úcategoryz·Non-string passwords will no longer be supported in Requests 3.0.0. Please convert the object you've passed in ({!r}) to a string or bytes object in the near future to avoid problems.Úlatin1zBasic ó :)
Ú
isinstancer ÚwarningsÚwarnÚformatÚDeprecationWarningr ÚtypeÚencoder r ÚjoinÚstrip)ÚusernameÚpasswordZauthstr© r ú1/usr/lib/python3.9/site-packages/requests/auth.pyÚ_basic_auth_str s0
ýû
ýû
ÿr c @ s e Zd ZdZdd„ ZdS )ÚAuthBasez4Base class that all auth implementations derive fromc C s t dƒ‚d S )NzAuth hooks must be callable.)ÚNotImplementedError©ÚselfÚrr r r Ú__call__K s zAuthBase.__call__N©Ú__name__Ú
__module__Ú__qualname__Ú__doc__r r r r r r H s r c @ s0 e Zd ZdZdd„ Zdd„ Zdd„ Zdd „ Zd
S )Ú
HTTPBasicAuthz?Attaches HTTP Basic Authentication to the given Request object.c C s || _ || _d S ©N)r r ©r r r r r r Ú__init__R s zHTTPBasicAuth.__init__c C s( t | jt|dd ƒk| jt|dd ƒkgƒS ©Nr r ©Úallr Úgetattrr ©r Úotherr r r Ú__eq__V s þzHTTPBasicAuth.__eq__c C s
| |k S r' r r. r r r Ú__ne__\ s zHTTPBasicAuth.__ne__c C s t | j| jƒ|jd<