Exchange a device assertion or a projected service-account token for a runtime identity token
/titan/broker/runtime-identities/exchangeA device signs a titan-device-assertion+jwt with its enrolled key and sends it as the bearer token (source_type titan_device_key). A workload of an attached customer Kubernetes cluster sends its projected service-account token, audience urn:titan:identity-broker:<td> (source_type kubernetes_service_account); it gets A2_VERIFIED at most. A workload in a Titan-managed sandbox sends its attestor's identity assertion (source_type titan_sandbox); it gets A3_ATTESTED only while the attestor attests it. A workload on a customer's cloud VM sends a titan-cloud-instance-credential (source_type cloud_instance_identity): a credential its cloud's metadata service minted for this one exchange, accepted once and only while fresh (SOURCE_CREDENTIAL_REPLAYED, SOURCE_CREDENTIAL_STALE); on Azure its nonce is a one-time challenge the Broker issues on this route for the media type application/vnd.titan.cloud-instance-challenge+json;version=1 with no credential. It gets A2_VERIFIED at most. The Broker selects the tenant by audience.
Headers
Bearer <token>. Runtime identity token from the identity exchange. Through the public edge, device-bound callers (titand) and workloads of the deployment's attached customer Kubernetes clusters are served. A device-bound caller's requests also carry a Titan-Device-Proof over the path below /v1 (or below the cell prefix), i.e. the /titan/agent/... path; an attached cluster's carry none.
Body parameters
One of: 1
titan_device_key: an enrolled device's assertion. kubernetes_service_account: through the public edge, a workload of an attached customer cluster (its projected token); Hexel-hosted workloads exchange in-cluster with their mesh identity. titan_sandbox: a workload in a Titan-managed sandbox, with its sandbox attestor's titan-sandbox-identity+jwt (only for agent deployments sandbox attestation lists). cloud_instance_identity: a workload on a customer's cloud VM, with a credential its cloud's metadata service minted for this exchange (a GCP identity token, Azure attested data, or on AWS an STS GetCallerIdentity request signed with the instance role, which the Broker forwards to STS; only for agent deployments cloud instance identity lists).
One of: "titan_device_key", "kubernetes_service_account", "titan_sandbox", "cloud_instance_identity"
One of: "urn:titan:token-type:runtime-identity"
urn:titan:gateway:<enforcement_deployment_id>; selects the tenant.
Returns
200Runtime identity issued.IdentityExchangeResponse
Runtime identity token (titanRuntimeIdentity).
One of: "urn:titan:token-type:runtime-identity"
One of: "Bearer"
The durable session this runtime session is a leg of; absent for a plain runtime session.
Errors
- 400Refused: INVALID_IDENTITY_EXCHANGE, RUNNER_PROOF_STALE, SOURCE_CREDENTIAL_STALE.
- 401Refused: INVALID_SOURCE_CREDENTIAL, SOURCE_CREDENTIAL_REPLAYED, SOURCE_VERIFIER_AMBIGUOUS, UNKNOWN_SOURCE_VERIFIER.
- 403Refused: ASSURANCE_INSUFFICIENT, CLOUD_INSTANCE_KEY_MISMATCH, CLOUD_INSTANCE_LAUNCH_TOO_OLD, DELEGATED_USER_ORGANIZATION_MISMATCH, IDENTITY_BINDING_AMBIGUOUS, IDENTITY_BINDING_NOT_FOUND, IDENTITY_CONTEXT_MISMATCH, IDENTITY_INACTIVE, SESSION_DELEGATION_DENIED.
- 409Refused: DURABLE_SESSION_EXPIRED, DURABLE_SESSION_SUSPENDED, SESSION_CONTINUATION_DENIED, SESSION_CONTINUATION_LAPSED.
- 429Refused: IDENTITY_EXCHANGE_RATE_LIMITED.
- 503Refused: LOCAL_IDENTITY_STATE_UNAVAILABLE.