skipcheck

TM1 client · Docs · Security

OidcKeyService

from skipcheck_tm1.services import OidcKeyService

The OpenID Connect signing keys TM1 has cached, for servers that check OIDC tokens themselves. Removing a key makes TM1 fetch it from the provider again, as after the provider rotates its keys. On a server that checks no tokens, the cache is empty.

Refresh the cache after the provider rotates its keys:

# After the provider rotates its signing keys: drop every cached key, so TM1
# fetches them again
tm1.oidc_keys.remove(tm1.oidc_keys.keys())

The asyncio flavor, skipcheck_tm1.aio, has the same methods to await, on AsyncOidcKeyService.

Members

keysThe IDs of the cached keys.
removeDrops keys from the cache.

keys

keys() -> list[str]

GetOIDCKeys(): the IDs of the cached keys.

TM1 REST FunctionImport GetOIDCKeys

remove

remove(key_ids: Sequence[str]) -> None

RemoveOIDCKeyFromCache: drops keys from the cache. A key TM1 hasn't cached fails the call with a Tm1NotFoundError: TM1 answers 400 with ObjectNotFound (code 55), which the client reads as not found.

TM1 REST ActionImport RemoveOIDCKeyFromCache