Return the algorithm for encoding ``id_token``. By default, it will use ``client.id_token_signed_response_alg``, if not defined, ``RS256`` will be used. But you can override this method to customize the returned algorithm.
(self, client)
| 24 | return config["key"] |
| 25 | |
| 26 | def get_client_algorithm(self, client): |
| 27 | """Return the algorithm for encoding ``id_token``. By default, it will |
| 28 | use ``client.id_token_signed_response_alg``, if not defined, ``RS256`` |
| 29 | will be used. But you can override this method to customize the returned |
| 30 | algorithm. |
| 31 | """ |
| 32 | # Per OpenID Connect Registration 1.0 Section 2: |
| 33 | # Use client's id_token_signed_response_alg if specified |
| 34 | config = self._compatible_resolve_jwt_config(None, client) |
| 35 | alg = config.get("alg") |
| 36 | if alg: |
| 37 | return alg |
| 38 | |
| 39 | if hasattr(client, "id_token_signed_response_alg"): |
| 40 | return client.id_token_signed_response_alg or "RS256" |
| 41 | return "RS256" |
| 42 | |
| 43 | def get_client_claims(self, client): |
| 44 | """Return the default client claims for encoding the ``id_token``. Developers |
no test coverage detected