MCPcopy Create free account

hub / github.com/authlib/authlib / functions

Functions2,764 in github.com/authlib/authlib

↓ 286 callersMethodpost
Invoke POST http request. If ``api_base_url`` configured, shortcut is available:: client.post("timeline", json={"text": "Hi"})
authlib/integrations/base_client/sync_app.py:31
↓ 261 callersMethodget
Invoke GET http request. If ``api_base_url`` configured, shortcut is available:: client.get("users/lepture")
authlib/integrations/base_client/sync_app.py:22
↓ 162 callersMethodget
(self, key)
tests/flask/cache.py:35
↓ 110 callersMethodimport_key
Import a key from bytes, string, or dict data.
authlib/jose/rfc7518/oct_key.py:98
↓ 93 callersMethodget
(self, key)
tests/clients/test_starlette/test_oauth_client.py:24
↓ 92 callersMethodencode
Encode a JWT with the given header, payload and key. :param header: A dict of JWS header :param payload: A dict to be encoded
authlib/jose/rfc7519/jwt.py:53
↓ 88 callersMethoddecode
Decode the JWT with the given key. This is similar with :meth:`verify`, except that it will raise BadSignatureError when signature doe
authlib/jose/rfc7519/jwt.py:80
↓ 85 callersMethodregister
(self, name, overwrite=False, **kwargs)
authlib/integrations/flask_client/__init__.py:45
↓ 84 callersFunctioncreate_basic_header
(username, password)
tests/flask/test_oauth2/oauth2_server.py:79
↓ 75 callersMethodset_client_metadata
(self, value)
authlib/integrations/sqla_oauth2/client_mixin.py:44
↓ 75 callersFunctionurl_decode
Decode a query string in x-www-form-urlencoded format into a sequence of two-element tuples. Unlike urlparse.parse_qsl(..., strict_parsing=Tr
authlib/common/urls.py:28
↓ 72 callersFunctionread_file_path
(name)
tests/util.py:14
↓ 60 callersMethodgenerate_key
(cls, crv="P-256", options=None, is_private=False)
authlib/jose/rfc7518/ec_key.py:99
↓ 46 callersMethodfetch_token
Generic method for fetching an access token from the token endpoint. :param url: Access Token endpoint URL, if not configured,
authlib/oauth2/client.py:207
↓ 44 callersFunctionadd_params_to_uri
Add a list of two-tuples to the uri query components.
authlib/common/urls.py:91
↓ 43 callersFunctionto_bytes
(x, charset="utf-8", errors="strict")
authlib/common/encoding.py:6
↓ 40 callersMethoddelete
(self, key)
tests/flask/cache.py:49
↓ 39 callersMethodpatch
Invoke PATCH http request. If ``api_base_url`` configured, shortcut is available:: client.patch("profile", json={"name": "Hsiaom
authlib/integrations/base_client/sync_app.py:40
↓ 38 callersMethodserialize_compact
Generate a JWE Compact Serialization. The JWE Compact Serialization represents encrypted content as a compact, URL-safe string. This
authlib/jose/rfc7516/jwe.py:69
↓ 35 callersFunctionto_unicode
(x, charset="utf-8", errors="strict")
authlib/common/encoding.py:18
↓ 34 callersFunctiongenerate_token
(length=30, chars=UNICODE_ASCII_CHARACTER_SET)
authlib/common/security.py:10
↓ 34 callersMethodvalidate
(self, now=None, leeway=0)
authlib/oauth2/claims.py:69
↓ 32 callersMethodserialize_json
Generate a JWE JSON Serialization (in fully general syntax). The JWE JSON Serialization represents encrypted content as a JSON object
authlib/jose/rfc7516/jwe.py:175
↓ 27 callersFunction_grant
(form, scope=None)
tests/core/test_oauth2/test_id_jag.py:109
↓ 27 callersMethoddeserialize_compact
Extract JWE Compact Serialization. :param s: JWE Compact Serialization as bytes :param key: Private key used to decrypt payload
authlib/jose/rfc7516/jwe.py:450
↓ 27 callersMethodregister_grant
Register a grant class into the endpoint registry. Developers can implement the grants in ``authlib.oauth2.rfc6749.grants`` and regist
authlib/oauth2/rfc6749/authorization_server.py:200
↓ 27 callersMethodvalidate_token_request
Validate an ID-JAG token request. Authenticates the client, binds it to the assertion's ``client_id`` claim, and enforces replay prot
authlib/oauth2/drafts/id_jag.py:151
↓ 26 callersMethodcreate_token_response
Issue an access token (no refresh token per the ID-JAG draft).
authlib/oauth2/drafts/id_jag.py:206
↓ 26 callersMethoddeserialize_json
Extract JWE JSON Serialization. :param obj: JWE JSON Serialization as dict or str :param key: Private key used to decrypt payload
authlib/jose/rfc7516/jwe.py:516
↓ 26 callersFunctionmock_send_value
(body, status_code=200)
tests/clients/util.py:30
↓ 26 callersFunctionregister_request_object_extension
( server, metadata=None, request_object=None, support_request=True, support_request_uri=Tr
tests/flask/test_oauth2/test_jwt_authorization_request.py:101
↓ 25 callersMethodas_dict
(self, is_private=False, **params)
authlib/jose/rfc7517/base_key.py:90
↓ 25 callersFunctiondecode_response
(data)
tests/util.py:21
↓ 25 callersFunctionget_bearer_token
()
tests/clients/util.py:41
↓ 25 callersMethodget_op_key
Get the raw key for the given key_op. This method will also check if the given key_op is supported by this key. :param operation: key
authlib/jose/rfc7518/oct_key.py:52
↓ 24 callersMethodvalidate
(self, now=None, leeway=0)
authlib/oauth2/rfc7591/claims.py:32
↓ 22 callersMethodauthorize_access_token
Fetch access token in one step. :return: A token dict.
authlib/integrations/flask_client/apps.py:57
↓ 21 callersFunctioncreate_basic_auth
(username, password)
tests/django/test_oauth2/oauth2_server.py:7
↓ 21 callersMethodcreate_endpoint_response
Validate and respond in one step (non-interactive mode). :param request: The OAuth2Request to process :returns: Tuple of (status_code
authlib/oauth2/rfc6749/endpoint.py:78
↓ 21 callersFunctiondeprecate
(message, version=None, stacklevel=3)
authlib/deprecate.py:11
↓ 20 callersFunction_sign
Produce a valid ID-JAG assertion for the test fixtures.
tests/flask/test_oauth2/test_id_jag_grant.py:88
↓ 20 callersMethodauthorize_redirect
Create a HTTP Redirect for Authorization Endpoint. :param redirect_uri: Callback or redirect URI for authorization. :param kwargs: Ex
authlib/integrations/flask_client/apps.py:42
↓ 20 callersMethodregister_endpoint
Add extra endpoint to authorization server. e.g. RevocationEndpoint:: authorization_server.register_endpoint(RevocationEndpoint)
authlib/oauth2/rfc6749/authorization_server.py:219
↓ 19 callersFunctionurlsafe_b64encode
(s)
authlib/common/encoding.py:45
↓ 18 callersFunctioncreate_authorization_server
(app, use_cache=False, lazy=False)
tests/flask/test_oauth1/oauth1_server.py:173
↓ 18 callersFunctionimport_any_key
(data: Any)
authlib/_joserfc_helpers.py:11
↓ 18 callersMethodlogout_redirect
Create a HTTP Redirect for End Session Endpoint (RP-Initiated Logout). :param post_logout_redirect_uri: URI to redirect after logout.
authlib/integrations/flask_client/apps.py:82
↓ 17 callersFunction_sign
(rsa_private, **kw)
tests/core/test_oauth2/test_id_jag.py:118
↓ 17 callersMethoddeserialize
Deserialize JWS Serialization, both compact and JSON format. It will automatically deserialize depending on the given JWS. :param s:
authlib/jose/rfc7515/jws.py:246
↓ 17 callersMethodkeys
(self)
authlib/jose/rfc7517/base_key.py:52
↓ 17 callersMethodsign
Create a signed ID-JAG JWT assertion. :param key: signing key (private key or shared secret) :param issuer: ``iss`` claim - identifie
authlib/oauth2/drafts/id_jag.py:94
↓ 17 callersFunctionvalidate_array_value
(metadata, key)
authlib/oauth2/rfc8414/models.py:406
↓ 16 callersFunctionis_secure_transport
Check if the uri is over ssl.
authlib/common/security.py:15
↓ 16 callersFunctionregister_jwt_client_auth
(server, validate_jti=True)
tests/flask/test_oauth2/test_jwt_bearer_client_auth.py:42
↓ 15 callersFunction_call_validate_array
(key, valid_value, required=False)
tests/core/test_oidc/test_discovery.py:168
↓ 15 callersFunctionjson_loads
(s)
authlib/common/encoding.py:32
↓ 14 callersFunctioncreate_half_hash
(s, alg)
authlib/oidc/core/util.py:7
↓ 14 callersMethodimport_key_set
Import KeySet from string, dict or a list of keys. :return: KeySet instance
authlib/jose/rfc7517/jwk.py:47
↓ 14 callersMethodserialize
Generate a JWS Serialization. It will automatically generate a Compact or JSON Serialization depending on the given header. If a heade
authlib/jose/rfc7515/jws.py:228
↓ 13 callersMethod_get_oauth_client
(self)
authlib/integrations/base_client/sync_app.py:130
↓ 12 callersFunctionis_valid_url
(url: str, fragments_allowed=True)
authlib/common/urls.py:142
↓ 12 callersFunctionjson_b64encode
(text)
authlib/common/encoding.py:63
↓ 12 callersMethodload_config
(self, name, params)
authlib/integrations/base_client/registry.py:117
↓ 11 callersFunctioncreate_access_token
(claims, jwks, alg="RS256", typ="at+jwt")
tests/flask/test_oauth2/rfc9068/test_resource_server.py:149
↓ 11 callersMethodfetch_request_token
Method for fetching an access token from the token endpoint. This is the first step in the OAuth 1 workflow. A request token is obtai
authlib/oauth1/client.py:104
↓ 11 callersMethodload_server_metadata
(self)
authlib/integrations/base_client/sync_app.py:326
↓ 11 callersMethodparse_id_token
Return UserInfo after validating the token's ``id_token``. The expected ``nonce`` is controlled by the application. Token claims such
authlib/integrations/base_client/sync_openid.py:40
↓ 11 callersMethodput
Invoke PUT http request. If ``api_base_url`` configured, shortcut is available:: client.put("profile", json={"name": "Hsiaoming
authlib/integrations/base_client/sync_app.py:49
↓ 11 callersMethodrequest
(self, method, url, token=None, **kwargs)
authlib/integrations/base_client/sync_app.py:19
↓ 11 callersFunctionurl_encode
(params)
authlib/common/urls.py:21
↓ 10 callersMethodgenerate_token
( self, user=None, scope=None, grant_type=None, expires_in=None,
authlib/oauth2/rfc6749/grants/base.py:33
↓ 10 callersMethodget_consent_grant
Validate current HTTP request for authorization page. This page is designed for resource owner to grant or deny the authorization.
authlib/oauth2/rfc6749/authorization_server.py:263
↓ 10 callersFunctionregister_oidc_code_grant
(server, require_nonce=False)
tests/flask/test_oauth2/test_openid_code_grant.py:56
↓ 10 callersFunctionsave_authorization_code
(code, request)
tests/flask/test_oauth2/models.py:100
↓ 10 callersMethodsave_token
A method to save token into database.
authlib/oauth2/rfc6749/grants/base.py:78
↓ 10 callersFunctionscope_to_list
Convert a space separated string to a list of scopes.
authlib/oauth2/rfc6749/util.py:17
↓ 10 callersFunctionurlsafe_b64decode
(s)
authlib/common/encoding.py:40
↓ 10 callersMethodvalidate_logout_response
Validate the state parameter from the logout callback. :return: The state data dict. :raises OAuthError: If state is missing or inval
authlib/integrations/flask_client/apps.py:107
↓ 9 callersFunctionbase64_to_int
(s)
authlib/common/encoding.py:49
↓ 9 callersMethodcheck_grant_type
Validate if the client can handle the given grant_type. There are four grant types defined by RFC6749: * authorization_code *
authlib/oauth2/rfc6749/models.py:120
↓ 9 callersMethodclear_state_data
(self, session: dict[str, Any] | None, state: str)
authlib/integrations/starlette_client/integration.py:59
↓ 9 callersMethodcreate_authorization_url
Generate an authorization URL and state. :param url: Authorization endpoint url, must be HTTPS. :param state: An optional state strin
authlib/oauth2/client.py:166
↓ 9 callersMethodgenerate_cek
(self)
authlib/jose/rfc7516/models.py:66
↓ 9 callersMethodget_state_data
( self, session: dict[str, Any] | None, state: str )
authlib/integrations/starlette_client/integration.py:19
↓ 9 callersMethodset
(self, key, value, timeout=None)
tests/flask/cache.py:43
↓ 8 callersMethodcheck_iv
(self, iv)
authlib/jose/rfc7516/models.py:72
↓ 8 callersFunctiondecode
(token, key="secret")
tests/core/test_oauth2/test_rfc7523_assertion.py:7
↓ 8 callersMethoddeserialize_json
Exact JWS JSON Serialization, and validate with the given key. If key is not provided, it will return a dict without signature verific
authlib/jose/rfc7515/jws.py:171
↓ 8 callersMethodis_expired
(self)
tests/django/test_oauth2/models.py:113
↓ 8 callersFunctionjson_dumps
(data, ensure_ascii=False)
authlib/common/encoding.py:36
↓ 8 callersFunctionmock_json_response
(payload)
tests/clients/test_requests/test_oauth2_session.py:23
↓ 8 callersFunctionregister_password_grant
(server, extensions=None)
tests/flask/test_oauth2/test_password_grant.py:47
↓ 8 callersMethodserialize_compact
Generate a JWS Compact Serialization. The JWS Compact Serialization represents digitally signed or MACed content as a compact, URL-safe
authlib/jose/rfc7515/jws.py:55
↓ 7 callersMethod__init__
(self, result)
authlib/jose/errors.py:23
↓ 7 callersFunctionadd_params_to_qs
Extend a query with a list of two-tuples.
authlib/common/urls.py:81
↓ 7 callersMethodauthenticate_token_endpoint_client
Authenticate client with the given methods for token endpoint. For example, the client makes the following HTTP request using TLS: .
authlib/oauth2/rfc6749/grants/base.py:52
↓ 7 callersFunctionclient_secret_jwt_sign
( client_secret, client_id, token_endpoint, alg="HS256", claims=None, **kwargs )
authlib/oauth2/rfc7523/assertion.py:56
↓ 7 callersMethodcreate_authorization_response
If the resource owner grants the access request, the authorization server issues an access token and delivers it to the client by adding
authlib/oauth2/rfc6749/grants/implicit.py:153
↓ 7 callersFunctioncreate_id_token
Create a signed ID token for testing.
tests/flask/test_oauth2/test_end_session.py:16
↓ 7 callersMethodinit_app
Initialize lazy for Flask app. This is usually used for Flask application factory pattern.
authlib/integrations/flask_client/__init__.py:24
next →1–100 of 2,764, ranked by callers