Associate Cloud Engineer ยท Impersonation, short-lived credentials and workload identity
Workload Identity Federation
Letting external workloads (AWS, Azure, GitHub Actions, OIDC) authenticate without keys: pools, providers, attribute mappings and conditions, how it differs from workforce federation.
Key points
- Workloads outside Google Cloud (AWS, Azure/Entra ID, GitHub Actions, any OIDC/SAML IdP) get access without service account keys.
- Pool: external identities; provider: trust in the IdP.
- Attribute mappings (CEL): claims to Google attributes; google.subject required.
- Attribute condition: rejects non-matching credentials.
- Security Token Service: external credential to federated token.
- Workforce identity federation: for humans.
Source: https://docs.cloud.google.com/iam/docs/workload-identity-federation
Practice questions
What does a provider inside a workload identity pool represent?
- A billing account that pays for external logins
- A Google service account used by the workload
- A cached copy of the external user directory
- The trust relationship with an external identity provider
Show answer
Answer: D. The trust relationship with an external identity provider
A provider describes the trust relationship with an external identity provider. The pool is the container, and keys are what federation avoids.
Which can serve as an external identity provider for Workload Identity Federation?
- AWS
- Microsoft Entra ID
- A generic OpenID Connect provider
- A shared static password list
- Only workloads running on Compute Engine
Show answer
Answer: A. AWS, B. Microsoft Entra ID, C. A generic OpenID Connect provider
AWS, Microsoft Entra ID and generic OIDC providers are supported. Federation does not trust arbitrary static passwords or require the workload to run in Google Cloud.
True or false: an AWS workload must be given a downloaded Google service account key before it can use Workload Identity Federation.
Show answer
Answer: False
False. The whole point of federation is to remove that key; the workload presents its AWS credential and Google exchanges it for a federated token.
Practice 8 questions on this topic in Bitzu
Short lessons, instant explanations and spaced review of what you get wrong. Free on iOS and Android.
