simple_openid_connect.jwk¶
JSON-Web-Key handling code
Functions
|
Fetch JSON web keys from the given jwks_uri. |
|
Fetch JSON web keys from the given jwks_uri. |
- simple_openid_connect.jwk.fetch_jwks(jwks_uri: str, session: Session | None = None) list[JWK][source]¶
Fetch JSON web keys from the given jwks_uri. This uri is part of the provider configuration and used to validate responses and tokens sent by the provider.
- Parameters:
session – a requests.Session object used to perform all HTTP requests. It can be used to customize certificate verification for example.
- Raises:
OpenidProtocolError – If fetching the keys fails
- simple_openid_connect.jwk.fetch_jwks_max_age(jwks_uri: str, session: Session | None = None) tuple[list[JWK], datetime | None][source]¶
Fetch JSON web keys from the given jwks_uri. This uri is part of the provider configuration and used to validate responses and tokens sent by the provider.
- Parameters:
session – a requests.Session object used to perform all HTTP requests. It can be used to customize certificate verification for example.
- Raises:
OpenidProtocolError – If fetching the keys fails