Authlib 1.6.11__tar.gz → 1.7.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {authlib-1.6.11 → authlib-1.7.0}/Authlib.egg-info/PKG-INFO +50 -48
- {authlib-1.6.11 → authlib-1.7.0}/Authlib.egg-info/SOURCES.txt +10 -1
- authlib-1.7.0/Authlib.egg-info/requires.txt +2 -0
- {authlib-1.6.11 → authlib-1.7.0}/PKG-INFO +50 -48
- {authlib-1.6.11 → authlib-1.7.0}/README.md +46 -45
- authlib-1.7.0/authlib/_joserfc_helpers.py +45 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/common/security.py +3 -1
- {authlib-1.6.11 → authlib-1.7.0}/authlib/consts.py +1 -1
- {authlib-1.6.11 → authlib-1.7.0}/authlib/deprecate.py +1 -4
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/base_client/async_app.py +1 -1
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/base_client/async_openid.py +56 -18
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/base_client/sync_app.py +6 -1
- authlib-1.7.0/authlib/integrations/base_client/sync_openid.py +122 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_client/apps.py +44 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth1/resource_protector.py +4 -2
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth2/resource_protector.py +5 -4
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_client/apps.py +42 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_client/integration.py +1 -1
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth1/resource_protector.py +4 -2
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth2/resource_protector.py +5 -4
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/starlette_client/apps.py +46 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/starlette_client/integration.py +3 -4
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/__init__.py +6 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7519/claims.py +1 -1
- authlib-1.7.0/authlib/oauth2/claims.py +76 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/__init__.py +4 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/authorization_server.py +53 -5
- authlib-1.7.0/authlib/oauth2/rfc6749/endpoint.py +90 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/grants/authorization_code.py +11 -1
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/grants/implicit.py +6 -1
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/requests.py +7 -4
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/token_endpoint.py +13 -15
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/wrappers.py +2 -2
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6750/errors.py +2 -2
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6750/token.py +17 -2
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7523/assertion.py +5 -3
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7523/auth.py +13 -2
- authlib-1.7.0/authlib/oauth2/rfc7523/client.py +170 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7523/jwt_bearer.py +81 -18
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7523/token.py +9 -5
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7523/validator.py +17 -14
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7591/claims.py +10 -13
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7591/endpoint.py +9 -6
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7592/endpoint.py +3 -1
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7636/challenge.py +9 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc8414/models.py +35 -2
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc8628/models.py +1 -1
- authlib-1.7.0/authlib/oauth2/rfc9068/claims.py +35 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9068/introspection.py +7 -5
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9068/token.py +10 -11
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9068/token_validator.py +17 -12
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9101/authorization_server.py +73 -50
- authlib-1.7.0/authlib/oauth2/rfc9101/discovery.py +21 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9101/registration.py +5 -6
- authlib-1.7.0/authlib/oauth2/rfc9207/__init__.py +4 -0
- authlib-1.7.0/authlib/oauth2/rfc9207/discovery.py +25 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9207/parameter.py +1 -3
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/claims.py +7 -35
- authlib-1.7.0/authlib/oidc/core/grants/_legacy.py +103 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/grants/code.py +51 -68
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/grants/implicit.py +52 -53
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/grants/util.py +9 -2
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/userinfo.py +18 -7
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/discovery/models.py +17 -11
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/registration/claims.py +5 -26
- authlib-1.7.0/authlib/oidc/rpinitiated/__init__.py +19 -0
- authlib-1.7.0/authlib/oidc/rpinitiated/discovery.py +13 -0
- authlib-1.7.0/authlib/oidc/rpinitiated/end_session.py +285 -0
- authlib-1.7.0/authlib/oidc/rpinitiated/registration.py +57 -0
- {authlib-1.6.11 → authlib-1.7.0}/pyproject.toml +23 -27
- authlib-1.6.11/Authlib.egg-info/requires.txt +0 -1
- authlib-1.6.11/authlib/integrations/base_client/sync_openid.py +0 -95
- authlib-1.6.11/authlib/oauth2/rfc7523/client.py +0 -124
- authlib-1.6.11/authlib/oauth2/rfc9068/claims.py +0 -64
- authlib-1.6.11/authlib/oauth2/rfc9101/discovery.py +0 -9
- authlib-1.6.11/authlib/oauth2/rfc9207/__init__.py +0 -3
- {authlib-1.6.11 → authlib-1.7.0}/Authlib.egg-info/dependency_links.txt +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/Authlib.egg-info/top_level.txt +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/LICENSE +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/MANIFEST.in +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/common/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/common/encoding.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/common/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/common/urls.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/base_client/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/base_client/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/base_client/framework_integration.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/base_client/registry.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_client/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_client/integration.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth1/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth1/authorization_server.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth1/nonce.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth2/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth2/authorization_server.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth2/endpoints.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth2/requests.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/django_oauth2/signals.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_client/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth1/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth1/authorization_server.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth1/cache.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth2/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth2/authorization_server.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth2/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth2/requests.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/flask_oauth2/signals.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/httpx_client/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/httpx_client/assertion_client.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/httpx_client/oauth1_client.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/httpx_client/oauth2_client.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/httpx_client/utils.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/requests_client/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/requests_client/assertion_session.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/requests_client/oauth1_session.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/requests_client/oauth2_session.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/requests_client/utils.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/sqla_oauth2/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/sqla_oauth2/client_mixin.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/sqla_oauth2/functions.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/sqla_oauth2/tokens_mixins.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/integrations/starlette_client/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/drafts/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/drafts/_jwe_algorithms.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/drafts/_jwe_enc_cryptodome.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/drafts/_jwe_enc_cryptography.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/jwk.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7515/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7515/jws.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7515/models.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7516/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7516/jwe.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7516/models.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7517/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7517/_cryptography_key.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7517/asymmetric_key.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7517/base_key.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7517/jwk.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7517/key_set.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7518/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7518/ec_key.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7518/jwe_algs.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7518/jwe_encs.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7518/jwe_zips.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7518/jws_algs.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7518/oct_key.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7518/rsa_key.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7518/util.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7519/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc7519/jwt.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc8037/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc8037/jws_eddsa.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/rfc8037/okp_key.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/jose/util.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/client.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/authorization_server.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/base_server.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/client_auth.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/models.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/parameters.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/resource_protector.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/rsa.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/signature.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/util.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth1/rfc5849/wrapper.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/auth.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/base.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/client.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/authenticate_client.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/grants/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/grants/base.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/grants/client_credentials.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/grants/refresh_token.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/grants/resource_owner_password_credentials.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/hooks.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/models.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/parameters.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/resource_protector.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6749/util.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6750/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6750/parameters.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc6750/validator.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7009/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7009/parameters.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7009/revocation.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7521/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7521/client.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7523/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7591/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7591/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7592/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7636/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7662/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7662/introspection.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7662/models.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc7662/token_validator.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc8414/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc8414/well_known.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc8628/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc8628/device_code.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc8628/endpoint.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc8628/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc8693/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9068/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9068/revocation.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9101/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oauth2/rfc9101/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/errors.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/grants/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/grants/hybrid.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/models.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/core/util.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/discovery/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/discovery/well_known.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/authlib/oidc/registration/__init__.py +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/setup.cfg +0 -0
- {authlib-1.6.11 → authlib-1.7.0}/setup.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: Authlib
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.7.0
|
|
4
4
|
Summary: The ultimate Python library in building OAuth and OpenID Connect servers and clients.
|
|
5
5
|
Author-email: Hsiaoming Yang <me@lepture.com>
|
|
6
6
|
License: BSD-3-Clause
|
|
@@ -18,21 +18,22 @@ Classifier: License :: OSI Approved :: BSD License
|
|
|
18
18
|
Classifier: Operating System :: OS Independent
|
|
19
19
|
Classifier: Programming Language :: Python
|
|
20
20
|
Classifier: Programming Language :: Python :: 3
|
|
21
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
22
21
|
Classifier: Programming Language :: Python :: 3.10
|
|
23
22
|
Classifier: Programming Language :: Python :: 3.11
|
|
24
23
|
Classifier: Programming Language :: Python :: 3.12
|
|
25
24
|
Classifier: Programming Language :: Python :: 3.13
|
|
25
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
26
26
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
27
27
|
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
28
28
|
Classifier: Topic :: Security
|
|
29
29
|
Classifier: Topic :: Security :: Cryptography
|
|
30
30
|
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
|
31
31
|
Classifier: Topic :: Internet :: WWW/HTTP :: WSGI :: Application
|
|
32
|
-
Requires-Python: >=3.
|
|
32
|
+
Requires-Python: >=3.10
|
|
33
33
|
Description-Content-Type: text/markdown
|
|
34
34
|
License-File: LICENSE
|
|
35
35
|
Requires-Dist: cryptography
|
|
36
|
+
Requires-Dist: joserfc>=1.6.0
|
|
36
37
|
Dynamic: license-file
|
|
37
38
|
|
|
38
39
|
<div align="center">
|
|
@@ -54,7 +55,7 @@ Dynamic: license-file
|
|
|
54
55
|
The ultimate Python library in building OAuth and OpenID Connect servers.
|
|
55
56
|
JWS, JWK, JWA, JWT are included.
|
|
56
57
|
|
|
57
|
-
Authlib is compatible with Python3.
|
|
58
|
+
Authlib is compatible with Python3.10+.
|
|
58
59
|
|
|
59
60
|
## Migrations
|
|
60
61
|
|
|
@@ -76,70 +77,71 @@ Authlib will deprecate `authlib.jose` module, please read:
|
|
|
76
77
|
</tr>
|
|
77
78
|
</table>
|
|
78
79
|
|
|
79
|
-
[**Fund Authlib to access additional features**](https://docs.authlib.org/en/
|
|
80
|
+
[**Fund Authlib to access additional features**](https://docs.authlib.org/en/stable/community/funding.html)
|
|
80
81
|
|
|
81
82
|
## Features
|
|
82
83
|
|
|
83
84
|
Generic, spec-compliant implementation to build clients and providers:
|
|
84
85
|
|
|
85
|
-
- [The OAuth 1.0 Protocol](https://docs.authlib.org/en/
|
|
86
|
-
- [RFC5849: The OAuth 1.0 Protocol](https://docs.authlib.org/en/
|
|
87
|
-
- [The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/
|
|
88
|
-
- [RFC6749: The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/
|
|
89
|
-
- [RFC6750: The OAuth 2.0 Authorization Framework: Bearer Token Usage](https://docs.authlib.org/en/
|
|
90
|
-
- [RFC7009: OAuth 2.0 Token Revocation](https://docs.authlib.org/en/
|
|
91
|
-
- [RFC7523: JWT Profile for OAuth 2.0 Client Authentication and Authorization Grants](https://docs.authlib.org/en/
|
|
92
|
-
- [RFC7591: OAuth 2.0 Dynamic Client Registration Protocol](https://docs.authlib.org/en/
|
|
93
|
-
- [RFC7592: OAuth 2.0 Dynamic Client Registration Management Protocol](https://docs.authlib.org/en/
|
|
94
|
-
- [RFC7636: Proof Key for Code Exchange by OAuth Public Clients](https://docs.authlib.org/en/
|
|
95
|
-
- [RFC7662: OAuth 2.0 Token Introspection](https://docs.authlib.org/en/
|
|
96
|
-
- [RFC8414: OAuth 2.0 Authorization Server Metadata](https://docs.authlib.org/en/
|
|
97
|
-
- [RFC8628: OAuth 2.0 Device Authorization Grant](https://docs.authlib.org/en/
|
|
98
|
-
- [RFC9068: JSON Web Token (JWT) Profile for OAuth 2.0 Access Tokens](https://docs.authlib.org/en/
|
|
99
|
-
- [RFC9101: The OAuth 2.0 Authorization Framework: JWT-Secured Authorization Request (JAR)](https://docs.authlib.org/en/
|
|
100
|
-
- [RFC9207: OAuth 2.0 Authorization Server Issuer Identification](https://docs.authlib.org/en/
|
|
101
|
-
- [Javascript Object Signing and Encryption](https://docs.authlib.org/en/
|
|
102
|
-
- [RFC7515: JSON Web Signature](https://docs.authlib.org/en/
|
|
103
|
-
- [RFC7516: JSON Web Encryption](https://docs.authlib.org/en/
|
|
104
|
-
- [RFC7517: JSON Web Key](https://docs.authlib.org/en/
|
|
105
|
-
- [RFC7518: JSON Web Algorithms](https://docs.authlib.org/en/
|
|
106
|
-
- [RFC7519: JSON Web Token](https://docs.authlib.org/en/
|
|
107
|
-
- [RFC7638: JSON Web Key (JWK) Thumbprint](https://docs.authlib.org/en/
|
|
86
|
+
- [The OAuth 1.0 Protocol](https://docs.authlib.org/en/stable/basic/oauth1.html)
|
|
87
|
+
- [RFC5849: The OAuth 1.0 Protocol](https://docs.authlib.org/en/stable/specs/rfc5849.html)
|
|
88
|
+
- [The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/stable/basic/oauth2.html)
|
|
89
|
+
- [RFC6749: The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/stable/specs/rfc6749.html)
|
|
90
|
+
- [RFC6750: The OAuth 2.0 Authorization Framework: Bearer Token Usage](https://docs.authlib.org/en/stable/specs/rfc6750.html)
|
|
91
|
+
- [RFC7009: OAuth 2.0 Token Revocation](https://docs.authlib.org/en/stable/specs/rfc7009.html)
|
|
92
|
+
- [RFC7523: JWT Profile for OAuth 2.0 Client Authentication and Authorization Grants](https://docs.authlib.org/en/stable/specs/rfc7523.html)
|
|
93
|
+
- [RFC7591: OAuth 2.0 Dynamic Client Registration Protocol](https://docs.authlib.org/en/stable/specs/rfc7591.html)
|
|
94
|
+
- [RFC7592: OAuth 2.0 Dynamic Client Registration Management Protocol](https://docs.authlib.org/en/stable/specs/rfc7592.html)
|
|
95
|
+
- [RFC7636: Proof Key for Code Exchange by OAuth Public Clients](https://docs.authlib.org/en/stable/specs/rfc7636.html)
|
|
96
|
+
- [RFC7662: OAuth 2.0 Token Introspection](https://docs.authlib.org/en/stable/specs/rfc7662.html)
|
|
97
|
+
- [RFC8414: OAuth 2.0 Authorization Server Metadata](https://docs.authlib.org/en/stable/specs/rfc8414.html)
|
|
98
|
+
- [RFC8628: OAuth 2.0 Device Authorization Grant](https://docs.authlib.org/en/stable/specs/rfc8628.html)
|
|
99
|
+
- [RFC9068: JSON Web Token (JWT) Profile for OAuth 2.0 Access Tokens](https://docs.authlib.org/en/stable/specs/rfc9068.html)
|
|
100
|
+
- [RFC9101: The OAuth 2.0 Authorization Framework: JWT-Secured Authorization Request (JAR)](https://docs.authlib.org/en/stable/specs/rfc9101.html)
|
|
101
|
+
- [RFC9207: OAuth 2.0 Authorization Server Issuer Identification](https://docs.authlib.org/en/stable/specs/rfc9207.html)
|
|
102
|
+
- [Javascript Object Signing and Encryption](https://docs.authlib.org/en/stable/jose/index.html)
|
|
103
|
+
- [RFC7515: JSON Web Signature](https://docs.authlib.org/en/stable/jose/jws.html)
|
|
104
|
+
- [RFC7516: JSON Web Encryption](https://docs.authlib.org/en/stable/jose/jwe.html)
|
|
105
|
+
- [RFC7517: JSON Web Key](https://docs.authlib.org/en/stable/jose/jwk.html)
|
|
106
|
+
- [RFC7518: JSON Web Algorithms](https://docs.authlib.org/en/stable/specs/rfc7518.html)
|
|
107
|
+
- [RFC7519: JSON Web Token](https://docs.authlib.org/en/stable/jose/jwt.html)
|
|
108
|
+
- [RFC7638: JSON Web Key (JWK) Thumbprint](https://docs.authlib.org/en/stable/specs/rfc7638.html)
|
|
108
109
|
- [ ] RFC7797: JSON Web Signature (JWS) Unencoded Payload Option
|
|
109
|
-
- [RFC8037: ECDH in JWS and JWE](https://docs.authlib.org/en/
|
|
110
|
+
- [RFC8037: ECDH in JWS and JWE](https://docs.authlib.org/en/stable/specs/rfc8037.html)
|
|
110
111
|
- [ ] draft-madden-jose-ecdh-1pu-04: Public Key Authenticated Encryption for JOSE: ECDH-1PU
|
|
111
|
-
- [OpenID Connect 1.0](https://docs.authlib.org/en/
|
|
112
|
+
- [OpenID Connect 1.0](https://docs.authlib.org/en/stable/specs/oidc.html)
|
|
112
113
|
- [x] OpenID Connect Core 1.0
|
|
113
114
|
- [x] OpenID Connect Discovery 1.0
|
|
114
115
|
- [x] OpenID Connect Dynamic Client Registration 1.0
|
|
116
|
+
- [x] [OpenID Connect RP-Initiated Logout 1.0](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)
|
|
115
117
|
|
|
116
118
|
Connect third party OAuth providers with Authlib built-in client integrations:
|
|
117
119
|
|
|
118
120
|
- Requests
|
|
119
|
-
- [OAuth1Session](https://docs.authlib.org/en/
|
|
120
|
-
- [OAuth2Session](https://docs.authlib.org/en/
|
|
121
|
-
- [OpenID Connect](https://docs.authlib.org/en/
|
|
122
|
-
- [AssertionSession](https://docs.authlib.org/en/
|
|
121
|
+
- [OAuth1Session](https://docs.authlib.org/en/stable/client/requests.html#requests-oauth-1-0)
|
|
122
|
+
- [OAuth2Session](https://docs.authlib.org/en/stable/client/requests.html#requests-oauth-2-0)
|
|
123
|
+
- [OpenID Connect](https://docs.authlib.org/en/stable/client/requests.html#requests-openid-connect)
|
|
124
|
+
- [AssertionSession](https://docs.authlib.org/en/stable/client/requests.html#requests-service-account)
|
|
123
125
|
- HTTPX
|
|
124
|
-
- [AsyncOAuth1Client](https://docs.authlib.org/en/
|
|
125
|
-
- [AsyncOAuth2Client](https://docs.authlib.org/en/
|
|
126
|
-
- [OpenID Connect](https://docs.authlib.org/en/
|
|
127
|
-
- [AsyncAssertionClient](https://docs.authlib.org/en/
|
|
128
|
-
- [Flask OAuth Client](https://docs.authlib.org/en/
|
|
129
|
-
- [Django OAuth Client](https://docs.authlib.org/en/
|
|
130
|
-
- [Starlette OAuth Client](https://docs.authlib.org/en/
|
|
131
|
-
- [FastAPI OAuth Client](https://docs.authlib.org/en/
|
|
126
|
+
- [AsyncOAuth1Client](https://docs.authlib.org/en/stable/client/httpx.html#httpx-oauth-1-0)
|
|
127
|
+
- [AsyncOAuth2Client](https://docs.authlib.org/en/stable/client/httpx.html#httpx-oauth-2-0)
|
|
128
|
+
- [OpenID Connect](https://docs.authlib.org/en/stable/client/httpx.html#httpx-oauth-2-0)
|
|
129
|
+
- [AsyncAssertionClient](https://docs.authlib.org/en/stable/client/httpx.html#async-service-account)
|
|
130
|
+
- [Flask OAuth Client](https://docs.authlib.org/en/stable/client/flask.html)
|
|
131
|
+
- [Django OAuth Client](https://docs.authlib.org/en/stable/client/django.html)
|
|
132
|
+
- [Starlette OAuth Client](https://docs.authlib.org/en/stable/client/starlette.html)
|
|
133
|
+
- [FastAPI OAuth Client](https://docs.authlib.org/en/stable/client/fastapi.html)
|
|
132
134
|
|
|
133
135
|
Build your own OAuth 1.0, OAuth 2.0, and OpenID Connect providers:
|
|
134
136
|
|
|
135
137
|
- Flask
|
|
136
|
-
- [Flask OAuth 1.0 Provider](https://docs.authlib.org/en/
|
|
137
|
-
- [Flask OAuth 2.0 Provider](https://docs.authlib.org/en/
|
|
138
|
-
- [Flask OpenID Connect 1.0 Provider](https://docs.authlib.org/en/
|
|
138
|
+
- [Flask OAuth 1.0 Provider](https://docs.authlib.org/en/stable/flask/1/)
|
|
139
|
+
- [Flask OAuth 2.0 Provider](https://docs.authlib.org/en/stable/flask/2/)
|
|
140
|
+
- [Flask OpenID Connect 1.0 Provider](https://docs.authlib.org/en/stable/flask/2/openid-connect.html)
|
|
139
141
|
- Django
|
|
140
|
-
- [Django OAuth 1.0 Provider](https://docs.authlib.org/en/
|
|
141
|
-
- [Django OAuth 2.0 Provider](https://docs.authlib.org/en/
|
|
142
|
-
- [Django OpenID Connect 1.0 Provider](https://docs.authlib.org/en/
|
|
142
|
+
- [Django OAuth 1.0 Provider](https://docs.authlib.org/en/stable/django/1/)
|
|
143
|
+
- [Django OAuth 2.0 Provider](https://docs.authlib.org/en/stable/django/2/)
|
|
144
|
+
- [Django OpenID Connect 1.0 Provider](https://docs.authlib.org/en/stable/django/2/openid-connect.html)
|
|
143
145
|
|
|
144
146
|
## Useful Links
|
|
145
147
|
|
|
@@ -9,6 +9,7 @@ Authlib.egg-info/dependency_links.txt
|
|
|
9
9
|
Authlib.egg-info/requires.txt
|
|
10
10
|
Authlib.egg-info/top_level.txt
|
|
11
11
|
authlib/__init__.py
|
|
12
|
+
authlib/_joserfc_helpers.py
|
|
12
13
|
authlib/consts.py
|
|
13
14
|
authlib/deprecate.py
|
|
14
15
|
authlib/common/__init__.py
|
|
@@ -121,10 +122,12 @@ authlib/oauth1/rfc5849/wrapper.py
|
|
|
121
122
|
authlib/oauth2/__init__.py
|
|
122
123
|
authlib/oauth2/auth.py
|
|
123
124
|
authlib/oauth2/base.py
|
|
125
|
+
authlib/oauth2/claims.py
|
|
124
126
|
authlib/oauth2/client.py
|
|
125
127
|
authlib/oauth2/rfc6749/__init__.py
|
|
126
128
|
authlib/oauth2/rfc6749/authenticate_client.py
|
|
127
129
|
authlib/oauth2/rfc6749/authorization_server.py
|
|
130
|
+
authlib/oauth2/rfc6749/endpoint.py
|
|
128
131
|
authlib/oauth2/rfc6749/errors.py
|
|
129
132
|
authlib/oauth2/rfc6749/hooks.py
|
|
130
133
|
authlib/oauth2/rfc6749/models.py
|
|
@@ -191,6 +194,7 @@ authlib/oauth2/rfc9101/discovery.py
|
|
|
191
194
|
authlib/oauth2/rfc9101/errors.py
|
|
192
195
|
authlib/oauth2/rfc9101/registration.py
|
|
193
196
|
authlib/oauth2/rfc9207/__init__.py
|
|
197
|
+
authlib/oauth2/rfc9207/discovery.py
|
|
194
198
|
authlib/oauth2/rfc9207/parameter.py
|
|
195
199
|
authlib/oidc/__init__.py
|
|
196
200
|
authlib/oidc/core/__init__.py
|
|
@@ -200,6 +204,7 @@ authlib/oidc/core/models.py
|
|
|
200
204
|
authlib/oidc/core/userinfo.py
|
|
201
205
|
authlib/oidc/core/util.py
|
|
202
206
|
authlib/oidc/core/grants/__init__.py
|
|
207
|
+
authlib/oidc/core/grants/_legacy.py
|
|
203
208
|
authlib/oidc/core/grants/code.py
|
|
204
209
|
authlib/oidc/core/grants/hybrid.py
|
|
205
210
|
authlib/oidc/core/grants/implicit.py
|
|
@@ -208,4 +213,8 @@ authlib/oidc/discovery/__init__.py
|
|
|
208
213
|
authlib/oidc/discovery/models.py
|
|
209
214
|
authlib/oidc/discovery/well_known.py
|
|
210
215
|
authlib/oidc/registration/__init__.py
|
|
211
|
-
authlib/oidc/registration/claims.py
|
|
216
|
+
authlib/oidc/registration/claims.py
|
|
217
|
+
authlib/oidc/rpinitiated/__init__.py
|
|
218
|
+
authlib/oidc/rpinitiated/discovery.py
|
|
219
|
+
authlib/oidc/rpinitiated/end_session.py
|
|
220
|
+
authlib/oidc/rpinitiated/registration.py
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: Authlib
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.7.0
|
|
4
4
|
Summary: The ultimate Python library in building OAuth and OpenID Connect servers and clients.
|
|
5
5
|
Author-email: Hsiaoming Yang <me@lepture.com>
|
|
6
6
|
License: BSD-3-Clause
|
|
@@ -18,21 +18,22 @@ Classifier: License :: OSI Approved :: BSD License
|
|
|
18
18
|
Classifier: Operating System :: OS Independent
|
|
19
19
|
Classifier: Programming Language :: Python
|
|
20
20
|
Classifier: Programming Language :: Python :: 3
|
|
21
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
22
21
|
Classifier: Programming Language :: Python :: 3.10
|
|
23
22
|
Classifier: Programming Language :: Python :: 3.11
|
|
24
23
|
Classifier: Programming Language :: Python :: 3.12
|
|
25
24
|
Classifier: Programming Language :: Python :: 3.13
|
|
25
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
26
26
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
27
27
|
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
28
28
|
Classifier: Topic :: Security
|
|
29
29
|
Classifier: Topic :: Security :: Cryptography
|
|
30
30
|
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
|
31
31
|
Classifier: Topic :: Internet :: WWW/HTTP :: WSGI :: Application
|
|
32
|
-
Requires-Python: >=3.
|
|
32
|
+
Requires-Python: >=3.10
|
|
33
33
|
Description-Content-Type: text/markdown
|
|
34
34
|
License-File: LICENSE
|
|
35
35
|
Requires-Dist: cryptography
|
|
36
|
+
Requires-Dist: joserfc>=1.6.0
|
|
36
37
|
Dynamic: license-file
|
|
37
38
|
|
|
38
39
|
<div align="center">
|
|
@@ -54,7 +55,7 @@ Dynamic: license-file
|
|
|
54
55
|
The ultimate Python library in building OAuth and OpenID Connect servers.
|
|
55
56
|
JWS, JWK, JWA, JWT are included.
|
|
56
57
|
|
|
57
|
-
Authlib is compatible with Python3.
|
|
58
|
+
Authlib is compatible with Python3.10+.
|
|
58
59
|
|
|
59
60
|
## Migrations
|
|
60
61
|
|
|
@@ -76,70 +77,71 @@ Authlib will deprecate `authlib.jose` module, please read:
|
|
|
76
77
|
</tr>
|
|
77
78
|
</table>
|
|
78
79
|
|
|
79
|
-
[**Fund Authlib to access additional features**](https://docs.authlib.org/en/
|
|
80
|
+
[**Fund Authlib to access additional features**](https://docs.authlib.org/en/stable/community/funding.html)
|
|
80
81
|
|
|
81
82
|
## Features
|
|
82
83
|
|
|
83
84
|
Generic, spec-compliant implementation to build clients and providers:
|
|
84
85
|
|
|
85
|
-
- [The OAuth 1.0 Protocol](https://docs.authlib.org/en/
|
|
86
|
-
- [RFC5849: The OAuth 1.0 Protocol](https://docs.authlib.org/en/
|
|
87
|
-
- [The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/
|
|
88
|
-
- [RFC6749: The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/
|
|
89
|
-
- [RFC6750: The OAuth 2.0 Authorization Framework: Bearer Token Usage](https://docs.authlib.org/en/
|
|
90
|
-
- [RFC7009: OAuth 2.0 Token Revocation](https://docs.authlib.org/en/
|
|
91
|
-
- [RFC7523: JWT Profile for OAuth 2.0 Client Authentication and Authorization Grants](https://docs.authlib.org/en/
|
|
92
|
-
- [RFC7591: OAuth 2.0 Dynamic Client Registration Protocol](https://docs.authlib.org/en/
|
|
93
|
-
- [RFC7592: OAuth 2.0 Dynamic Client Registration Management Protocol](https://docs.authlib.org/en/
|
|
94
|
-
- [RFC7636: Proof Key for Code Exchange by OAuth Public Clients](https://docs.authlib.org/en/
|
|
95
|
-
- [RFC7662: OAuth 2.0 Token Introspection](https://docs.authlib.org/en/
|
|
96
|
-
- [RFC8414: OAuth 2.0 Authorization Server Metadata](https://docs.authlib.org/en/
|
|
97
|
-
- [RFC8628: OAuth 2.0 Device Authorization Grant](https://docs.authlib.org/en/
|
|
98
|
-
- [RFC9068: JSON Web Token (JWT) Profile for OAuth 2.0 Access Tokens](https://docs.authlib.org/en/
|
|
99
|
-
- [RFC9101: The OAuth 2.0 Authorization Framework: JWT-Secured Authorization Request (JAR)](https://docs.authlib.org/en/
|
|
100
|
-
- [RFC9207: OAuth 2.0 Authorization Server Issuer Identification](https://docs.authlib.org/en/
|
|
101
|
-
- [Javascript Object Signing and Encryption](https://docs.authlib.org/en/
|
|
102
|
-
- [RFC7515: JSON Web Signature](https://docs.authlib.org/en/
|
|
103
|
-
- [RFC7516: JSON Web Encryption](https://docs.authlib.org/en/
|
|
104
|
-
- [RFC7517: JSON Web Key](https://docs.authlib.org/en/
|
|
105
|
-
- [RFC7518: JSON Web Algorithms](https://docs.authlib.org/en/
|
|
106
|
-
- [RFC7519: JSON Web Token](https://docs.authlib.org/en/
|
|
107
|
-
- [RFC7638: JSON Web Key (JWK) Thumbprint](https://docs.authlib.org/en/
|
|
86
|
+
- [The OAuth 1.0 Protocol](https://docs.authlib.org/en/stable/basic/oauth1.html)
|
|
87
|
+
- [RFC5849: The OAuth 1.0 Protocol](https://docs.authlib.org/en/stable/specs/rfc5849.html)
|
|
88
|
+
- [The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/stable/basic/oauth2.html)
|
|
89
|
+
- [RFC6749: The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/stable/specs/rfc6749.html)
|
|
90
|
+
- [RFC6750: The OAuth 2.0 Authorization Framework: Bearer Token Usage](https://docs.authlib.org/en/stable/specs/rfc6750.html)
|
|
91
|
+
- [RFC7009: OAuth 2.0 Token Revocation](https://docs.authlib.org/en/stable/specs/rfc7009.html)
|
|
92
|
+
- [RFC7523: JWT Profile for OAuth 2.0 Client Authentication and Authorization Grants](https://docs.authlib.org/en/stable/specs/rfc7523.html)
|
|
93
|
+
- [RFC7591: OAuth 2.0 Dynamic Client Registration Protocol](https://docs.authlib.org/en/stable/specs/rfc7591.html)
|
|
94
|
+
- [RFC7592: OAuth 2.0 Dynamic Client Registration Management Protocol](https://docs.authlib.org/en/stable/specs/rfc7592.html)
|
|
95
|
+
- [RFC7636: Proof Key for Code Exchange by OAuth Public Clients](https://docs.authlib.org/en/stable/specs/rfc7636.html)
|
|
96
|
+
- [RFC7662: OAuth 2.0 Token Introspection](https://docs.authlib.org/en/stable/specs/rfc7662.html)
|
|
97
|
+
- [RFC8414: OAuth 2.0 Authorization Server Metadata](https://docs.authlib.org/en/stable/specs/rfc8414.html)
|
|
98
|
+
- [RFC8628: OAuth 2.0 Device Authorization Grant](https://docs.authlib.org/en/stable/specs/rfc8628.html)
|
|
99
|
+
- [RFC9068: JSON Web Token (JWT) Profile for OAuth 2.0 Access Tokens](https://docs.authlib.org/en/stable/specs/rfc9068.html)
|
|
100
|
+
- [RFC9101: The OAuth 2.0 Authorization Framework: JWT-Secured Authorization Request (JAR)](https://docs.authlib.org/en/stable/specs/rfc9101.html)
|
|
101
|
+
- [RFC9207: OAuth 2.0 Authorization Server Issuer Identification](https://docs.authlib.org/en/stable/specs/rfc9207.html)
|
|
102
|
+
- [Javascript Object Signing and Encryption](https://docs.authlib.org/en/stable/jose/index.html)
|
|
103
|
+
- [RFC7515: JSON Web Signature](https://docs.authlib.org/en/stable/jose/jws.html)
|
|
104
|
+
- [RFC7516: JSON Web Encryption](https://docs.authlib.org/en/stable/jose/jwe.html)
|
|
105
|
+
- [RFC7517: JSON Web Key](https://docs.authlib.org/en/stable/jose/jwk.html)
|
|
106
|
+
- [RFC7518: JSON Web Algorithms](https://docs.authlib.org/en/stable/specs/rfc7518.html)
|
|
107
|
+
- [RFC7519: JSON Web Token](https://docs.authlib.org/en/stable/jose/jwt.html)
|
|
108
|
+
- [RFC7638: JSON Web Key (JWK) Thumbprint](https://docs.authlib.org/en/stable/specs/rfc7638.html)
|
|
108
109
|
- [ ] RFC7797: JSON Web Signature (JWS) Unencoded Payload Option
|
|
109
|
-
- [RFC8037: ECDH in JWS and JWE](https://docs.authlib.org/en/
|
|
110
|
+
- [RFC8037: ECDH in JWS and JWE](https://docs.authlib.org/en/stable/specs/rfc8037.html)
|
|
110
111
|
- [ ] draft-madden-jose-ecdh-1pu-04: Public Key Authenticated Encryption for JOSE: ECDH-1PU
|
|
111
|
-
- [OpenID Connect 1.0](https://docs.authlib.org/en/
|
|
112
|
+
- [OpenID Connect 1.0](https://docs.authlib.org/en/stable/specs/oidc.html)
|
|
112
113
|
- [x] OpenID Connect Core 1.0
|
|
113
114
|
- [x] OpenID Connect Discovery 1.0
|
|
114
115
|
- [x] OpenID Connect Dynamic Client Registration 1.0
|
|
116
|
+
- [x] [OpenID Connect RP-Initiated Logout 1.0](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)
|
|
115
117
|
|
|
116
118
|
Connect third party OAuth providers with Authlib built-in client integrations:
|
|
117
119
|
|
|
118
120
|
- Requests
|
|
119
|
-
- [OAuth1Session](https://docs.authlib.org/en/
|
|
120
|
-
- [OAuth2Session](https://docs.authlib.org/en/
|
|
121
|
-
- [OpenID Connect](https://docs.authlib.org/en/
|
|
122
|
-
- [AssertionSession](https://docs.authlib.org/en/
|
|
121
|
+
- [OAuth1Session](https://docs.authlib.org/en/stable/client/requests.html#requests-oauth-1-0)
|
|
122
|
+
- [OAuth2Session](https://docs.authlib.org/en/stable/client/requests.html#requests-oauth-2-0)
|
|
123
|
+
- [OpenID Connect](https://docs.authlib.org/en/stable/client/requests.html#requests-openid-connect)
|
|
124
|
+
- [AssertionSession](https://docs.authlib.org/en/stable/client/requests.html#requests-service-account)
|
|
123
125
|
- HTTPX
|
|
124
|
-
- [AsyncOAuth1Client](https://docs.authlib.org/en/
|
|
125
|
-
- [AsyncOAuth2Client](https://docs.authlib.org/en/
|
|
126
|
-
- [OpenID Connect](https://docs.authlib.org/en/
|
|
127
|
-
- [AsyncAssertionClient](https://docs.authlib.org/en/
|
|
128
|
-
- [Flask OAuth Client](https://docs.authlib.org/en/
|
|
129
|
-
- [Django OAuth Client](https://docs.authlib.org/en/
|
|
130
|
-
- [Starlette OAuth Client](https://docs.authlib.org/en/
|
|
131
|
-
- [FastAPI OAuth Client](https://docs.authlib.org/en/
|
|
126
|
+
- [AsyncOAuth1Client](https://docs.authlib.org/en/stable/client/httpx.html#httpx-oauth-1-0)
|
|
127
|
+
- [AsyncOAuth2Client](https://docs.authlib.org/en/stable/client/httpx.html#httpx-oauth-2-0)
|
|
128
|
+
- [OpenID Connect](https://docs.authlib.org/en/stable/client/httpx.html#httpx-oauth-2-0)
|
|
129
|
+
- [AsyncAssertionClient](https://docs.authlib.org/en/stable/client/httpx.html#async-service-account)
|
|
130
|
+
- [Flask OAuth Client](https://docs.authlib.org/en/stable/client/flask.html)
|
|
131
|
+
- [Django OAuth Client](https://docs.authlib.org/en/stable/client/django.html)
|
|
132
|
+
- [Starlette OAuth Client](https://docs.authlib.org/en/stable/client/starlette.html)
|
|
133
|
+
- [FastAPI OAuth Client](https://docs.authlib.org/en/stable/client/fastapi.html)
|
|
132
134
|
|
|
133
135
|
Build your own OAuth 1.0, OAuth 2.0, and OpenID Connect providers:
|
|
134
136
|
|
|
135
137
|
- Flask
|
|
136
|
-
- [Flask OAuth 1.0 Provider](https://docs.authlib.org/en/
|
|
137
|
-
- [Flask OAuth 2.0 Provider](https://docs.authlib.org/en/
|
|
138
|
-
- [Flask OpenID Connect 1.0 Provider](https://docs.authlib.org/en/
|
|
138
|
+
- [Flask OAuth 1.0 Provider](https://docs.authlib.org/en/stable/flask/1/)
|
|
139
|
+
- [Flask OAuth 2.0 Provider](https://docs.authlib.org/en/stable/flask/2/)
|
|
140
|
+
- [Flask OpenID Connect 1.0 Provider](https://docs.authlib.org/en/stable/flask/2/openid-connect.html)
|
|
139
141
|
- Django
|
|
140
|
-
- [Django OAuth 1.0 Provider](https://docs.authlib.org/en/
|
|
141
|
-
- [Django OAuth 2.0 Provider](https://docs.authlib.org/en/
|
|
142
|
-
- [Django OpenID Connect 1.0 Provider](https://docs.authlib.org/en/
|
|
142
|
+
- [Django OAuth 1.0 Provider](https://docs.authlib.org/en/stable/django/1/)
|
|
143
|
+
- [Django OAuth 2.0 Provider](https://docs.authlib.org/en/stable/django/2/)
|
|
144
|
+
- [Django OpenID Connect 1.0 Provider](https://docs.authlib.org/en/stable/django/2/openid-connect.html)
|
|
143
145
|
|
|
144
146
|
## Useful Links
|
|
145
147
|
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
The ultimate Python library in building OAuth and OpenID Connect servers.
|
|
18
18
|
JWS, JWK, JWA, JWT are included.
|
|
19
19
|
|
|
20
|
-
Authlib is compatible with Python3.
|
|
20
|
+
Authlib is compatible with Python3.10+.
|
|
21
21
|
|
|
22
22
|
## Migrations
|
|
23
23
|
|
|
@@ -39,70 +39,71 @@ Authlib will deprecate `authlib.jose` module, please read:
|
|
|
39
39
|
</tr>
|
|
40
40
|
</table>
|
|
41
41
|
|
|
42
|
-
[**Fund Authlib to access additional features**](https://docs.authlib.org/en/
|
|
42
|
+
[**Fund Authlib to access additional features**](https://docs.authlib.org/en/stable/community/funding.html)
|
|
43
43
|
|
|
44
44
|
## Features
|
|
45
45
|
|
|
46
46
|
Generic, spec-compliant implementation to build clients and providers:
|
|
47
47
|
|
|
48
|
-
- [The OAuth 1.0 Protocol](https://docs.authlib.org/en/
|
|
49
|
-
- [RFC5849: The OAuth 1.0 Protocol](https://docs.authlib.org/en/
|
|
50
|
-
- [The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/
|
|
51
|
-
- [RFC6749: The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/
|
|
52
|
-
- [RFC6750: The OAuth 2.0 Authorization Framework: Bearer Token Usage](https://docs.authlib.org/en/
|
|
53
|
-
- [RFC7009: OAuth 2.0 Token Revocation](https://docs.authlib.org/en/
|
|
54
|
-
- [RFC7523: JWT Profile for OAuth 2.0 Client Authentication and Authorization Grants](https://docs.authlib.org/en/
|
|
55
|
-
- [RFC7591: OAuth 2.0 Dynamic Client Registration Protocol](https://docs.authlib.org/en/
|
|
56
|
-
- [RFC7592: OAuth 2.0 Dynamic Client Registration Management Protocol](https://docs.authlib.org/en/
|
|
57
|
-
- [RFC7636: Proof Key for Code Exchange by OAuth Public Clients](https://docs.authlib.org/en/
|
|
58
|
-
- [RFC7662: OAuth 2.0 Token Introspection](https://docs.authlib.org/en/
|
|
59
|
-
- [RFC8414: OAuth 2.0 Authorization Server Metadata](https://docs.authlib.org/en/
|
|
60
|
-
- [RFC8628: OAuth 2.0 Device Authorization Grant](https://docs.authlib.org/en/
|
|
61
|
-
- [RFC9068: JSON Web Token (JWT) Profile for OAuth 2.0 Access Tokens](https://docs.authlib.org/en/
|
|
62
|
-
- [RFC9101: The OAuth 2.0 Authorization Framework: JWT-Secured Authorization Request (JAR)](https://docs.authlib.org/en/
|
|
63
|
-
- [RFC9207: OAuth 2.0 Authorization Server Issuer Identification](https://docs.authlib.org/en/
|
|
64
|
-
- [Javascript Object Signing and Encryption](https://docs.authlib.org/en/
|
|
65
|
-
- [RFC7515: JSON Web Signature](https://docs.authlib.org/en/
|
|
66
|
-
- [RFC7516: JSON Web Encryption](https://docs.authlib.org/en/
|
|
67
|
-
- [RFC7517: JSON Web Key](https://docs.authlib.org/en/
|
|
68
|
-
- [RFC7518: JSON Web Algorithms](https://docs.authlib.org/en/
|
|
69
|
-
- [RFC7519: JSON Web Token](https://docs.authlib.org/en/
|
|
70
|
-
- [RFC7638: JSON Web Key (JWK) Thumbprint](https://docs.authlib.org/en/
|
|
48
|
+
- [The OAuth 1.0 Protocol](https://docs.authlib.org/en/stable/basic/oauth1.html)
|
|
49
|
+
- [RFC5849: The OAuth 1.0 Protocol](https://docs.authlib.org/en/stable/specs/rfc5849.html)
|
|
50
|
+
- [The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/stable/basic/oauth2.html)
|
|
51
|
+
- [RFC6749: The OAuth 2.0 Authorization Framework](https://docs.authlib.org/en/stable/specs/rfc6749.html)
|
|
52
|
+
- [RFC6750: The OAuth 2.0 Authorization Framework: Bearer Token Usage](https://docs.authlib.org/en/stable/specs/rfc6750.html)
|
|
53
|
+
- [RFC7009: OAuth 2.0 Token Revocation](https://docs.authlib.org/en/stable/specs/rfc7009.html)
|
|
54
|
+
- [RFC7523: JWT Profile for OAuth 2.0 Client Authentication and Authorization Grants](https://docs.authlib.org/en/stable/specs/rfc7523.html)
|
|
55
|
+
- [RFC7591: OAuth 2.0 Dynamic Client Registration Protocol](https://docs.authlib.org/en/stable/specs/rfc7591.html)
|
|
56
|
+
- [RFC7592: OAuth 2.0 Dynamic Client Registration Management Protocol](https://docs.authlib.org/en/stable/specs/rfc7592.html)
|
|
57
|
+
- [RFC7636: Proof Key for Code Exchange by OAuth Public Clients](https://docs.authlib.org/en/stable/specs/rfc7636.html)
|
|
58
|
+
- [RFC7662: OAuth 2.0 Token Introspection](https://docs.authlib.org/en/stable/specs/rfc7662.html)
|
|
59
|
+
- [RFC8414: OAuth 2.0 Authorization Server Metadata](https://docs.authlib.org/en/stable/specs/rfc8414.html)
|
|
60
|
+
- [RFC8628: OAuth 2.0 Device Authorization Grant](https://docs.authlib.org/en/stable/specs/rfc8628.html)
|
|
61
|
+
- [RFC9068: JSON Web Token (JWT) Profile for OAuth 2.0 Access Tokens](https://docs.authlib.org/en/stable/specs/rfc9068.html)
|
|
62
|
+
- [RFC9101: The OAuth 2.0 Authorization Framework: JWT-Secured Authorization Request (JAR)](https://docs.authlib.org/en/stable/specs/rfc9101.html)
|
|
63
|
+
- [RFC9207: OAuth 2.0 Authorization Server Issuer Identification](https://docs.authlib.org/en/stable/specs/rfc9207.html)
|
|
64
|
+
- [Javascript Object Signing and Encryption](https://docs.authlib.org/en/stable/jose/index.html)
|
|
65
|
+
- [RFC7515: JSON Web Signature](https://docs.authlib.org/en/stable/jose/jws.html)
|
|
66
|
+
- [RFC7516: JSON Web Encryption](https://docs.authlib.org/en/stable/jose/jwe.html)
|
|
67
|
+
- [RFC7517: JSON Web Key](https://docs.authlib.org/en/stable/jose/jwk.html)
|
|
68
|
+
- [RFC7518: JSON Web Algorithms](https://docs.authlib.org/en/stable/specs/rfc7518.html)
|
|
69
|
+
- [RFC7519: JSON Web Token](https://docs.authlib.org/en/stable/jose/jwt.html)
|
|
70
|
+
- [RFC7638: JSON Web Key (JWK) Thumbprint](https://docs.authlib.org/en/stable/specs/rfc7638.html)
|
|
71
71
|
- [ ] RFC7797: JSON Web Signature (JWS) Unencoded Payload Option
|
|
72
|
-
- [RFC8037: ECDH in JWS and JWE](https://docs.authlib.org/en/
|
|
72
|
+
- [RFC8037: ECDH in JWS and JWE](https://docs.authlib.org/en/stable/specs/rfc8037.html)
|
|
73
73
|
- [ ] draft-madden-jose-ecdh-1pu-04: Public Key Authenticated Encryption for JOSE: ECDH-1PU
|
|
74
|
-
- [OpenID Connect 1.0](https://docs.authlib.org/en/
|
|
74
|
+
- [OpenID Connect 1.0](https://docs.authlib.org/en/stable/specs/oidc.html)
|
|
75
75
|
- [x] OpenID Connect Core 1.0
|
|
76
76
|
- [x] OpenID Connect Discovery 1.0
|
|
77
77
|
- [x] OpenID Connect Dynamic Client Registration 1.0
|
|
78
|
+
- [x] [OpenID Connect RP-Initiated Logout 1.0](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)
|
|
78
79
|
|
|
79
80
|
Connect third party OAuth providers with Authlib built-in client integrations:
|
|
80
81
|
|
|
81
82
|
- Requests
|
|
82
|
-
- [OAuth1Session](https://docs.authlib.org/en/
|
|
83
|
-
- [OAuth2Session](https://docs.authlib.org/en/
|
|
84
|
-
- [OpenID Connect](https://docs.authlib.org/en/
|
|
85
|
-
- [AssertionSession](https://docs.authlib.org/en/
|
|
83
|
+
- [OAuth1Session](https://docs.authlib.org/en/stable/client/requests.html#requests-oauth-1-0)
|
|
84
|
+
- [OAuth2Session](https://docs.authlib.org/en/stable/client/requests.html#requests-oauth-2-0)
|
|
85
|
+
- [OpenID Connect](https://docs.authlib.org/en/stable/client/requests.html#requests-openid-connect)
|
|
86
|
+
- [AssertionSession](https://docs.authlib.org/en/stable/client/requests.html#requests-service-account)
|
|
86
87
|
- HTTPX
|
|
87
|
-
- [AsyncOAuth1Client](https://docs.authlib.org/en/
|
|
88
|
-
- [AsyncOAuth2Client](https://docs.authlib.org/en/
|
|
89
|
-
- [OpenID Connect](https://docs.authlib.org/en/
|
|
90
|
-
- [AsyncAssertionClient](https://docs.authlib.org/en/
|
|
91
|
-
- [Flask OAuth Client](https://docs.authlib.org/en/
|
|
92
|
-
- [Django OAuth Client](https://docs.authlib.org/en/
|
|
93
|
-
- [Starlette OAuth Client](https://docs.authlib.org/en/
|
|
94
|
-
- [FastAPI OAuth Client](https://docs.authlib.org/en/
|
|
88
|
+
- [AsyncOAuth1Client](https://docs.authlib.org/en/stable/client/httpx.html#httpx-oauth-1-0)
|
|
89
|
+
- [AsyncOAuth2Client](https://docs.authlib.org/en/stable/client/httpx.html#httpx-oauth-2-0)
|
|
90
|
+
- [OpenID Connect](https://docs.authlib.org/en/stable/client/httpx.html#httpx-oauth-2-0)
|
|
91
|
+
- [AsyncAssertionClient](https://docs.authlib.org/en/stable/client/httpx.html#async-service-account)
|
|
92
|
+
- [Flask OAuth Client](https://docs.authlib.org/en/stable/client/flask.html)
|
|
93
|
+
- [Django OAuth Client](https://docs.authlib.org/en/stable/client/django.html)
|
|
94
|
+
- [Starlette OAuth Client](https://docs.authlib.org/en/stable/client/starlette.html)
|
|
95
|
+
- [FastAPI OAuth Client](https://docs.authlib.org/en/stable/client/fastapi.html)
|
|
95
96
|
|
|
96
97
|
Build your own OAuth 1.0, OAuth 2.0, and OpenID Connect providers:
|
|
97
98
|
|
|
98
99
|
- Flask
|
|
99
|
-
- [Flask OAuth 1.0 Provider](https://docs.authlib.org/en/
|
|
100
|
-
- [Flask OAuth 2.0 Provider](https://docs.authlib.org/en/
|
|
101
|
-
- [Flask OpenID Connect 1.0 Provider](https://docs.authlib.org/en/
|
|
100
|
+
- [Flask OAuth 1.0 Provider](https://docs.authlib.org/en/stable/flask/1/)
|
|
101
|
+
- [Flask OAuth 2.0 Provider](https://docs.authlib.org/en/stable/flask/2/)
|
|
102
|
+
- [Flask OpenID Connect 1.0 Provider](https://docs.authlib.org/en/stable/flask/2/openid-connect.html)
|
|
102
103
|
- Django
|
|
103
|
-
- [Django OAuth 1.0 Provider](https://docs.authlib.org/en/
|
|
104
|
-
- [Django OAuth 2.0 Provider](https://docs.authlib.org/en/
|
|
105
|
-
- [Django OpenID Connect 1.0 Provider](https://docs.authlib.org/en/
|
|
104
|
+
- [Django OAuth 1.0 Provider](https://docs.authlib.org/en/stable/django/1/)
|
|
105
|
+
- [Django OAuth 2.0 Provider](https://docs.authlib.org/en/stable/django/2/)
|
|
106
|
+
- [Django OpenID Connect 1.0 Provider](https://docs.authlib.org/en/stable/django/2/openid-connect.html)
|
|
106
107
|
|
|
107
108
|
## Useful Links
|
|
108
109
|
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
from typing import Any
|
|
2
|
+
|
|
3
|
+
from joserfc.jwk import KeySet
|
|
4
|
+
from joserfc.jwk import import_key
|
|
5
|
+
|
|
6
|
+
from authlib.common.encoding import json_loads
|
|
7
|
+
from authlib.deprecate import deprecate
|
|
8
|
+
from authlib.jose import ECKey
|
|
9
|
+
from authlib.jose import OctKey
|
|
10
|
+
from authlib.jose import OKPKey
|
|
11
|
+
from authlib.jose import RSAKey
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
def import_any_key(data: Any):
|
|
15
|
+
if isinstance(data, (OctKey, RSAKey, ECKey, OKPKey)):
|
|
16
|
+
deprecate("Please use joserfc to import keys.", version="2.0.0")
|
|
17
|
+
return import_key(data.as_dict(is_private=not data.public_only))
|
|
18
|
+
|
|
19
|
+
if (
|
|
20
|
+
isinstance(data, str)
|
|
21
|
+
and data.strip().startswith("{")
|
|
22
|
+
and data.strip().endswith("}")
|
|
23
|
+
):
|
|
24
|
+
deprecate(
|
|
25
|
+
"Please use OctKey, RSAKey, ECKey, OKPKey, and KeySet directly.",
|
|
26
|
+
version="2.0.0",
|
|
27
|
+
)
|
|
28
|
+
data = json_loads(data)
|
|
29
|
+
|
|
30
|
+
if isinstance(data, (str, bytes)):
|
|
31
|
+
deprecate(
|
|
32
|
+
"Please use OctKey, RSAKey, ECKey, OKPKey, and KeySet directly.",
|
|
33
|
+
version="2.0.0",
|
|
34
|
+
)
|
|
35
|
+
return import_key(data)
|
|
36
|
+
|
|
37
|
+
elif isinstance(data, dict):
|
|
38
|
+
if "keys" in data:
|
|
39
|
+
deprecate(
|
|
40
|
+
"Please `KeySet.import_key_set` from `joserfc.jwk` to import jwks.",
|
|
41
|
+
version="2.0.0",
|
|
42
|
+
)
|
|
43
|
+
return KeySet.import_key_set(data)
|
|
44
|
+
return import_key(data)
|
|
45
|
+
return data
|
|
@@ -8,11 +8,8 @@ class AuthlibDeprecationWarning(DeprecationWarning):
|
|
|
8
8
|
warnings.simplefilter("always", AuthlibDeprecationWarning)
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
def deprecate(message, version=None,
|
|
11
|
+
def deprecate(message, version=None, stacklevel=3):
|
|
12
12
|
if version:
|
|
13
13
|
message += f"\nIt will be compatible before version {version}."
|
|
14
14
|
|
|
15
|
-
if link_uid and link_file:
|
|
16
|
-
message += f"\nRead more <https://git.io/{link_uid}#file-{link_file}-md>"
|
|
17
|
-
|
|
18
15
|
warnings.warn(AuthlibDeprecationWarning(message), stacklevel=stacklevel)
|
|
@@ -75,7 +75,7 @@ class AsyncOAuth2Mixin(OAuth2Base):
|
|
|
75
75
|
|
|
76
76
|
async def load_server_metadata(self):
|
|
77
77
|
if self._server_metadata_url and "_loaded_at" not in self.server_metadata:
|
|
78
|
-
async with self.
|
|
78
|
+
async with self._get_session() as client:
|
|
79
79
|
resp = await client.request(
|
|
80
80
|
"GET", self._server_metadata_url, withhold_token=True
|
|
81
81
|
)
|