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੐)|#o0aڱ$I>}k&1`U#V?YsV x>{t1[I~D&(I$I/{H0fw"q"y%4 IXyE~M3 8XψL}qE$I[> nD?~sf ]o΁ cT6"?'_Ἣ $I>~.f|'!N?⟩0G KkXZE]ޡ;/&?k OۘH$IRۀwXӨ<7@PnS04aӶp.:@\IWQJ6sS%I$e5ڑv`3:x';wq_vpgHyXZ 3gЂ7{{EuԹn±}$I$8t;b|591nءQ"P6O5i }iR̈́%Q̄p!I䮢]O{H$IRϻ9s֧ a=`- aB\X0"+5"C1Hb?߮3x3&gşggl_hZ^,`5?ߎvĸ%̀M!OZC2#0x LJ0 Gw$I$I}<{Eb+y;iI,`ܚF:5ܛA8-O-|8K7s|#Z8a&><a&/VtbtLʌI$I$I$I$I$I$IRjDD%tEXtdate:create2022-05-31T04:40:26+00:00!Î%tEXtdate:modify2022-05-31T04:40:26+00:00|{2IENDB`Mini Shell

HOME


Mini Shell 1.0
DIR:/usr/lib/python3/dist-packages/oauthlib/oauth2/rfc6749/clients/__pycache__/
Upload File :
Current File : //usr/lib/python3/dist-packages/oauthlib/oauth2/rfc6749/clients/__pycache__/base.cpython-311.pyc
�

�ch���dZddlZddlZddlZddlZddlZddlZddlmZddl	m
Z
ddlmZm
Z
ddlmZmZmZddlmZdZd	Zd
ZddiZGd
�d��ZdS)z�
oauthlib.oauth2.rfc6749
~~~~~~~~~~~~~~~~~~~~~~~

This module is an implementation of various logic needed
for consuming OAuth 2.0 RFC6749.
�N)�generate_token)�tokens)�InsecureTransportError�TokenExpiredError)�parse_token_response�prepare_token_request� prepare_token_revocation_request)�is_secure_transport�auth_header�query�bodyzContent-Typez!application/x-www-form-urlencodedc���eZdZdZdZedddddddddedddfd�Zed���Z	d�Z
d�Zd	�Z		dd�Z
		dd�Z		dd�Z		dd�Z	dd�Zd d�Zd!d�Z		dd�Zd�Zd d�Zd
ddedfd�Zd�Zd�Zd�ZdS)"�Clienta�Base OAuth2 client responsible for access token management.

    This class also acts as a generic interface providing methods common to all
    client types such as ``prepare_authorization_request`` and
    ``prepare_token_revocation_request``. The ``prepare_x_request`` methods are
    the recommended way of interacting with clients (as opposed to the abstract
    prepare uri/body/etc methods). They are recommended over the older set
    because they are easier to use (more consistent) and add a few additional
    security checks, such as HTTPS and state checking.

    Some of these methods require further implementation only provided by the
    specific purpose clients such as
    :py:class:`oauthlib.oauth2.MobileApplicationClient` and thus you should always
    seek to use the client class matching the OAuth workflow you need. For
    Python, this is usually :py:class:`oauthlib.oauth2.WebApplicationClient`.

    �
refresh_token�BearerNc�:�||_||_||_||_||_||_||_|pi|_|	|_||_	|
|_
||_|
|_||_
||_d|_d|_d|_|�|j��dS)aeInitialize a client with commonly used attributes.

        :param client_id: Client identifier given by the OAuth provider upon
        registration.

        :param default_token_placement: Tokens can be supplied in the Authorization
        header (default), the URL query component (``query``) or the request
        body (``body``).

        :param token_type: OAuth 2 token type. Defaults to Bearer. Change this
        if you specify the ``access_token`` parameter and know it is of a
        different token type, such as a MAC, JWT or SAML token. Can
        also be supplied as ``token_type`` inside the ``token`` dict parameter.

        :param access_token: An access token (string) used to authenticate
        requests to protected resources. Can also be supplied inside the
        ``token`` dict parameter.

        :param refresh_token: A refresh token (string) used to refresh expired
        tokens. Can also be supplied inside the ``token`` dict parameter.

        :param mac_key: Encryption key used with MAC tokens.

        :param mac_algorithm:  Hashing algorithm for MAC tokens.

        :param token: A dict of token attributes such as ``access_token``,
        ``token_type`` and ``expires_at``.

        :param scope: A list of default scopes to request authorization for.

        :param state: A CSRF protection string used during authorization.

        :param redirect_url: The redirection endpoint on the client side to which
        the user returns after authorization.

        :param state_generator: A no argument state generation callable. Defaults
        to :py:meth:`oauthlib.common.generate_token`.

        :param code_verifier: PKCE parameter. A cryptographically random string that is used to correlate the
        authorization request to the token request.

        :param code_challenge: PKCE parameter. A challenge derived from the code verifier that is sent in the
        authorization request, to be verified against later.

        :param code_challenge_method: PKCE parameter. A method that was used to derive code challenge.
        Defaults to "plain" if not present in the request.
        N)�	client_id�default_token_placement�
token_type�access_tokenr�mac_key�
mac_algorithm�token�scope�state_generator�state�redirect_url�
code_verifier�code_challenge�code_challenge_method�code�
expires_in�_expires_at�populate_token_attributes)�selfrrrrrrrrrrrrrrr �kwargss                 �F/usr/lib/python3/dist-packages/oauthlib/oauth2/rfc6749/clients/base.py�__init__zClient.__init__8s���@#���'>��$�$���(���*������*����[�b��
���
�.�����
�(���*���,���%:��"���	��������&�&�t�z�2�2�2�2�2�c� �|j|jd�S)aOSupported token types and their respective methods

        Additional tokens can be supported by extending this dictionary.

        The Bearer token spec is stable and safe to use.

        The MAC token spec is not yet stable and support for MAC tokens
        is experimental and currently matching version 00 of the spec.
        )r�MAC)�_add_bearer_token�_add_mac_token)r%s r'�token_typeszClient.token_types�s���,��&�
�
�	
r)c� �td���)z,Abstract method used to create request URIs.�*Must be implemented by inheriting classes.��NotImplementedError�r%�argsr&s   r'�prepare_request_urizClient.prepare_request_uri����!�"N�O�O�Or)c� �td���)z.Abstract method used to create request bodies.r0r1r3s   r'�prepare_request_bodyzClient.prepare_request_body�r6r)c� �td���)z4Abstract method used to parse redirection responses.r0r1r3s   r'�parse_request_uri_responsez!Client.parse_request_uri_response�r6r)�GETc��t|��st���|p|j}d�|j���D��}|j���|vrtd|jz���|js)|j	�
d��std���|jr*|jtj��krt���||j���|||||fi|��S)acAdd token to the request uri, body or authorization header.

        The access token type provides the client with the information
        required to successfully utilize the access token to make a protected
        resource request (along with type-specific attributes).  The client
        MUST NOT use an access token if it does not understand the token
        type.

        For example, the "bearer" token type defined in
        [`I-D.ietf-oauth-v2-bearer`_] is utilized by simply including the access
        token string in the request:

        .. code-block:: http

            GET /resource/1 HTTP/1.1
            Host: example.com
            Authorization: Bearer mF_9.B5f-4.1JqM

        while the "mac" token type defined in [`I-D.ietf-oauth-v2-http-mac`_] is
        utilized by issuing a MAC key together with the access token which is
        used to sign certain components of the HTTP requests:

        .. code-block:: http

            GET /resource/1 HTTP/1.1
            Host: example.com
            Authorization: MAC id="h480djs93hd8",
                                nonce="274312:dj83hs9s",
                                mac="kDZvddkndxvhGRXZhvuDjEWhGeE="

        .. _`I-D.ietf-oauth-v2-bearer`: https://tools.ietf.org/html/rfc6749#section-12.2
        .. _`I-D.ietf-oauth-v2-http-mac`: https://tools.ietf.org/html/rfc6749#section-12.2
        c�>�i|]\}}|���|��S�)�lower)�.0�k�vs   r'�
<dictcomp>z$Client.add_token.<locals>.<dictcomp>�s3��(?�(?�(?�!�Q��A�G�G�I�I�q�(?�(?�(?r)zUnsupported token type: %srzMissing access token.)r
rrr.�itemsrr?�
ValueErrorrr�getr#�timer)r%�uri�http_methodr
�headers�token_placementr&�case_insensitive_token_typess        r'�	add_tokenzClient.add_token�s+��F#�3�'�'�	+�(�*�*�*�)�I�T�-I��(?�(?�%)�%5�%;�%;�%=�%=�(?�(?�(?�$���$�$�&�&�*F�F�F��9�D�O�K�L�L�L��!�	6�T�Z�^�^�N�%C�%C�	6��4�5�5�5���	&�� 0�4�9�;�;� >� >�#�%�%�%�D�+�D�O�,A�,A�,C�,C�D�S�+�W[�EL�o�i�i�ag�i�i�	ir)c���t|��st���|p|���|_|p|j|_|�|jn|}|j|f|j||jd�|��}|tdfS)aePrepare the authorization request.

        This is the first step in many OAuth flows in which the user is
        redirected to a certain authorization URL. This method adds
        required parameters to the authorization URL.

        :param authorization_url: Provider authorization endpoint URL.
        :param state: CSRF protection string. Will be automatically created if
            not provided. The generated state is available via the ``state``
            attribute. Clients should verify that the state is unchanged and
            present in the authorization response. This verification is done
            automatically if using the ``authorization_response`` parameter
            with ``prepare_token_request``.
        :param redirect_url: Redirect URL to which the user will be returned
            after authorization. Must be provided unless previously setup with
            the provider. If provided then it must also be provided in the
            token request.
        :param scope: List of scopes to request. Must be equal to
            or a subset of the scopes granted when obtaining the refresh
            token. If none is provided, the ones provided in the constructor are
            used.
        :param kwargs: Additional parameters to included in the request.
        :returns: The prepared request tuple with (url, headers, body).
        N)�redirect_urirr�)r
rrrrrr5�FORM_ENC_HEADERS)r%�authorization_urlrrrr&�auth_urls       r'�prepare_authorization_requestz$Client.prepare_authorization_request�s���4#�#4�5�5�	+�(�*�*�*��4�d�2�2�4�4��
�(�=�D�,=���#�m��
�
���+�4�+��5�,0�,=��t�z�5�5�-3�5�5���)�2�-�-r)rPc���t|��st���|p|j}|r|�||���|p|j|_|jd||jd�|��}|t|fS)a�Prepare a token creation request.

        Note that these requests usually require client authentication, either
        by including client_id or a set of provider specific authentication
        credentials.

        :param token_url: Provider token creation endpoint URL.
        :param authorization_response: The full redirection URL string, i.e.
            the location to which the user was redirected after successful
            authorization. Used to mine credentials needed to obtain a token
            in this step, such as authorization code.
        :param redirect_url: The redirect_url supplied with the authorization
            request (if there was one).
        :param state:
        :param body: Existing request body (URL encoded string) to embed parameters
                     into. This may contain extra parameters. Default ''.
        :param kwargs: Additional parameters to included in the request.
        :returns: The prepared request tuple with (url, headers, body).
        )r)r
rOr>)r
rrr:rr8rQ)r%�	token_url�authorization_responserrr
r&s       r'rzClient.prepare_token_requests���*#�9�-�-�	+�(�*�*�*��#����!�	5��+�+�&�e�
,�
5�
5�
5�(�=�D�,=���(�t�(�S�d�6:�6G�S�S�KQ�S�S���*�D�0�0r)c��t|��st���|�|jn|}|jd|||d�|��}|t|fS)a�Prepare an access token refresh request.

        Expired access tokens can be replaced by new access tokens without
        going through the OAuth dance if the client obtained a refresh token.
        This refresh token and authentication credentials can be used to
        obtain a new access token, and possibly a new refresh token.

        :param token_url: Provider token refresh endpoint URL.
        :param refresh_token: Refresh token string.
        :param body: Existing request body (URL encoded string) to embed parameters
            into. This may contain extra parameters. Default ''.
        :param scope: List of scopes to request. Must be equal to
            or a subset of the scopes granted when obtaining the refresh
            token. If none is provided, the ones provided in the constructor are
            used.
        :param kwargs: Additional parameters to included in the request.
        :returns: The prepared request tuple with (url, headers, body).
        N)r
rrr>)r
rr�prepare_refresh_bodyrQ)r%rVrr
rr&s      r'�prepare_refresh_token_requestz$Client.prepare_refresh_token_request&sq��(#�9�-�-�	+�(�*�*�*�$�m��
�
���(�t�(�]�d�7D�E�]�]�U[�]�]���*�D�0�0r)rc�`�t|��st���t||f|||d�|��S)aUPrepare a token revocation request.

        :param revocation_url: Provider token revocation endpoint URL.
        :param token: The access or refresh token to be revoked (string).
        :param token_type_hint: ``"access_token"`` (default) or
            ``"refresh_token"``. This is optional and if you wish to not pass it you
            must provide ``token_type_hint=None``.
        :param body:
        :param callback: A jsonp callback such as ``package.callback`` to be invoked
            upon receiving the response. Not that it should not include a () suffix.
        :param kwargs: Additional parameters to included in the request.
        :returns: The prepared request tuple with (url, headers, body).

        Note that JSONP request may use GET requests as the parameters will
        be added to the request URL query as opposed to the request body.

        An example of a revocation request

        .. code-block:: http

            POST /revoke HTTP/1.1
            Host: server.example.com
            Content-Type: application/x-www-form-urlencoded
            Authorization: Basic czZCaGRSa3F0MzpnWDFmQmF0M2JW

            token=45ghiukldjahdnhzdauz&token_type_hint=refresh_token

        An example of a jsonp revocation request

        .. code-block:: http

            GET /revoke?token=agabcdefddddafdd&callback=package.myCallback HTTP/1.1
            Host: server.example.com
            Content-Type: application/x-www-form-urlencoded
            Authorization: Basic czZCaGRSa3F0MzpnWDFmQmF0M2JW

        and an error response

        .. code-block:: javascript

            package.myCallback({"error":"unsupported_token_type"});

        Note that these requests usually require client credentials, client_id in
        the case for public clients and provider specific authentication
        credentials for confidential clients.
        )�token_type_hintr
�callback)r
rr	)r%�revocation_urlrr\r
r]r&s       r'r	z'Client.prepare_token_revocation_requestCsR��`#�>�2�2�	+�(�*�*�*�/���:�@O�VZ�em�:�:�28�:�:�	:r)c��|�|jn|}t||���|_|�|j��|jS)a�Parse the JSON response body.

        If the access token request is valid and authorized, the
        authorization server issues an access token as described in
        `Section 5.1`_.  A refresh token SHOULD NOT be included.  If the request
        failed client authentication or is invalid, the authorization server
        returns an error response as described in `Section 5.2`_.

        :param body: The response body from the token request.
        :param scope: Scopes originally requested. If none is provided, the ones
            provided in the constructor are used.
        :return: Dictionary of token parameters.
        :raises: Warning if scope has changed. :py:class:`oauthlib.oauth2.errors.OAuth2Error`
            if response is invalid.

        These response are json encoded and could easily be parsed without
        the assistance of OAuthLib. However, there are a few subtle issues
        to be aware of regarding the response which are helpfully addressed
        through the raising of various errors.

        A successful response should always contain

        **access_token**
                The access token issued by the authorization server. Often
                a random string.

        **token_type**
            The type of the token issued as described in `Section 7.1`_.
            Commonly ``Bearer``.

        While it is not mandated it is recommended that the provider include

        **expires_in**
            The lifetime in seconds of the access token.  For
            example, the value "3600" denotes that the access token will
            expire in one hour from the time the response was generated.
            If omitted, the authorization server SHOULD provide the
            expiration time via other means or document the default value.

         **scope**
            Providers may supply this in all responses but are required to only
            if it has changed since the authorization request.

        .. _`Section 5.1`: https://tools.ietf.org/html/rfc6749#section-5.1
        .. _`Section 5.2`: https://tools.ietf.org/html/rfc6749#section-5.2
        .. _`Section 7.1`: https://tools.ietf.org/html/rfc6749#section-7.1
        N)r)rrrr$)r%r
rr&s    r'�parse_request_body_responsez"Client.parse_request_body_responsezsF��`$�m��
�
���)�$�e�<�<�<��
��&�&�t�z�2�2�2��z�r)c�V�|p|j}|�|jn|}t|jf|||d�|��S)aOPrepare an access token request, using a refresh token.

        If the authorization server issued a refresh token to the client, the
        client makes a refresh request to the token endpoint by adding the
        following parameters using the `application/x-www-form-urlencoded`
        format in the HTTP request entity-body:

        :param refresh_token: REQUIRED.  The refresh token issued to the client.
        :param scope:  OPTIONAL.  The scope of the access request as described by
            Section 3.3.  The requested scope MUST NOT include any scope
            not originally granted by the resource owner, and if omitted is
            treated as equal to the scope originally granted by the
            resource owner. Note that if none is provided, the ones provided
            in the constructor are used if any.
        N)r
rr)rrr�refresh_token_key)r%r
rrr&s     r'rYzClient.prepare_refresh_body�sV�� &�;��);�
�#�m��
�
���$�T�%;�L�$�e�3@�L�L�DJ�L�L�	Lr)c��|tkrtj|j|��}n[|tkrtj|j|��}n5|tkrtj|j|��}ntd���|||fS)zDAdd a bearer token to the request uri, body or authorization header.�Invalid token placement.)	�AUTH_HEADERr�prepare_bearer_headersr�	URI_QUERY�prepare_bearer_uri�BODY�prepare_bearer_bodyrE)r%rHrIr
rJrKs      r'r,zClient._add_bearer_token�s����k�)�)��3�D�4E�w�O�O�G�G�
�	�
)�
)��+�D�,=�s�C�C�C�C�
��
$�
$��-�d�.?��F�F�D�D��7�8�8�8��G�T�!�!r)c��d}|dkstd���|dkstd���tjd��}tj|��}tj||��std���||_|S)a�Create PKCE **code_verifier** used in computing **code_challenge**. 
        See `RFC7636 Section 4.1`_

        :param length: REQUIRED. The length of the code_verifier.

        The client first creates a code verifier, "code_verifier", for each
        OAuth 2.0 [RFC6749] Authorization Request, in the following manner:

        .. code-block:: text

               code_verifier = high-entropy cryptographic random STRING using the
               unreserved characters [A-Z] / [a-z] / [0-9] / "-" / "." / "_" / "~"
               from Section 2.3 of [RFC3986], with a minimum length of 43 characters
               and a maximum length of 128 characters.

        .. _`RFC7636 Section 4.1`: https://tools.ietf.org/html/rfc7636#section-4.1
        N�+z*Length must be greater than or equal to 43�z(Length must be less than or equal to 128z^[A-Zaa-z0-9-._~]z)code_verifier contains invalid characters)rE�re�compile�secrets�
token_urlsafe�searchr)r%�lengthr�allowed_characterss    r'�create_code_verifierzClient.create_code_verifier�s���$�
���|�|��I�J�J�J���}�}��G�H�H�H��Z�(;�<�<���-�f�5�5�
��y�+�]�;�;�	J��H�I�I�I�*����r)c���d}|dkrtd���|dkrd}||_|}||_|dkr�tj��}|�|�d�����|���}t�	tj|����}|�dd���d	d
���dd��}||_|S)
aZCreate PKCE **code_challenge** derived from the  **code_verifier**.
        See `RFC7636 Section 4.2`_

        :param code_verifier: REQUIRED. The **code_verifier** generated from `create_code_verifier()`.
        :param code_challenge_method: OPTIONAL. The method used to derive the **code_challenge**. Acceptable values include `S256`. DEFAULT is `plain`.

               The client then creates a code challenge derived from the code
               verifier by using one of the following transformations on the code
               verifier::

                   plain
                      code_challenge = code_verifier
                   S256
                      code_challenge = BASE64URL-ENCODE(SHA256(ASCII(code_verifier)))

               If the client is capable of using `S256`, it MUST use `S256`, as
               `S256` is Mandatory To Implement (MTI) on the server.  Clients are
               permitted to use `plain` only if they cannot support `S256` for some
               technical reason and know via out-of-band configuration that the
               server supports `plain`.

               The plain transformation is for compatibility with existing
               deployments and for constrained environments that can't use the S256 transformation.

        .. _`RFC7636 Section 4.2`: https://tools.ietf.org/html/rfc7636#section-4.2
        NzInvalid code_verifier�plain�S256�ascii)�encoding�+�-�/�_�=rP)
rEr r�hashlib�sha256�update�encode�digest�bytes�decode�base64�urlsafe_b64encode�replace)r%rr r�h�
sha256_vals      r'�create_code_challengezClient.create_code_challenge�s���6���D� � ��4�5�5�5� �D�(�(�$+�!�)>�D�&�*�N�"0�D�� �F�*�*��� � �A�
�H�H�]�)�)�7�)�;�;�<�<�<������J�"�\�\�&�*B�:�*N�*N�O�O�N�+�3�3�C��=�=�E�E�c�3�O�O�W�W�X[�]_�`�`�N�"0�D���r)c��|tkrtd���tj|j||j|f||||jd�|��}|||fS)z�Add a MAC token to the request authorization header.

        Warning: MAC token support is experimental as the spec is not yet stable.
        rd)rJr
�ext�hash_algorithm)rerEr�prepare_mac_headerrrr)r%rHrIr
rJrKr�r&s        r'r-zClient._add_mac_token)ss���k�)�)��7�8�8�8��+�D�,=�s�,0�L�+�Y�OV�]a�gj�;?�;M�Y�Y�QW�Y�Y���G�T�!�!r)c�`�tjdt��|�|��S)Nz=Please switch to the public method populate_token_attributes.)�warnings�warn�DeprecationWarningr$�r%�responses  r'�_populate_attributeszClient._populate_attributes7s5���
�3�4F�	H�	H�	H��-�-�h�7�7�7r)c�F�d|vr|�d��|_dSdS)z2Add attributes from an auth code response to self.r!N)rFr!r�s  r'�populate_code_attributeszClient.populate_code_attributes<s.���X��� ���V�,�,�D�I�I�I��r)c�B�d|vr|�d��|_d|vr|�d��|_d|vr|�d��|_d|vrG|�d��|_tj��t
|j��z|_d|vr7	t
|�d����|_n#d|_YnxYwd|vr|�d��|_d|vr|�d��|_	dSdS)	z6Add attributes from a token exchange response to self.rrrr"�
expires_atNrr)
rFrrrr"rG�intr#rrr�s  r'r$z Client.populate_token_attributesBs,���X�%�%� (���^� <� <�D���h�&�&�!)���o�!>�!>�D���8�#�#�&�l�l�<�8�8�D�O��8�#�#�&�l�l�<�8�8�D�O�#�y�{�{�S���-A�-A�A�D���8�#�#�
(�#&�x�|�|�L�'A�'A�#B�#B�� � ��
(�#'�� � � ������ � �#�<�<�	�2�2�D�L��h�&�&�!)���o�!>�!>�D����'�&s�+'C�	C)r;NNN)NNN)NNNrP)NrPN)rrPN)N)rPNN)�__name__�
__module__�__qualname__�__doc__rbrerr(�propertyr.r5r8r:rMrTrrZr	r`rYr,rur�r-r�r�r$r>r)r'rr$s��������"(��*5�$�"�#��#����"�!/�#� $�'+�R3�R3�R3�R3�h�

�

��X�

�P�P�P�P�P�P�P�P�P�DH�"&�4i�4i�4i�4i�lFJ�?C�$.�$.�$.�$.�LGK�BD� 1� 1� 1� 1�DFJ�59�1�1�1�1�<\`�5:�5:�5:�5:�n3�3�3�3�jL�L�L�L�*>B�8<�"�"�"�"� "�"�"�H/�/�/�/�b/4�$�#�[�d�"�"�"�"�8�8�8�
-�-�-�?�?�?�?�?r)r)r�r�r�rnrprGr��oauthlib.commonr�oauthlib.oauth2.rfc6749r�oauthlib.oauth2.rfc6749.errorsrr�"oauthlib.oauth2.rfc6749.parametersrrr	�oauthlib.oauth2.rfc6749.utilsr
rergrirQrr>r)r'�<module>r�s4�����
�
�
�����	�	�	�	�������������*�*�*�*�*�*�*�*�*�*�*�*�������������������>�=�=�=�=�=����	�
���7���
x?�x?�x?�x?�x?�x?�x?�x?�x?�x?r)