An enterprise security architect is transitioning an external CI/CD pipeline hosted on Azure DevOps from legacy static service account keys to short-lived federated credentials using Workload Identity Federation to securely access Secret Manager secrets.
In which sequential order should the architect execute the steps to configure this keyless authentication and authorization workflow?
- 1Create a Workload Identity Pool and an OIDC Workload Identity Provider in Google Cloud configured with the Azure DevOps issuer URL and audience.
- 2Configure attribute mappings and assertion conditions on the Workload Identity Provider to validate claims such as repository ID and pipeline context.
- 3Grant the roles/iam.workloadIdentityUser IAM role on the target GCP Service Account to the specific external principal set derived from the mapped attributes.
- 4Grant the roles/secretmanager.secretAccessor IAM role to the target GCP Service Account on the specific secret resource in Secret Manager.
- 5Configure the Azure DevOps pipeline step to exchange its Azure OIDC JWT for a Google Cloud federated token and generate a short-lived GCP service account access token.
Answer
The correct sequence begins by creating the Workload Identity Pool and Provider, defining attribute mappings and conditions, assigning the workloadIdentityUser role to the external principal set on the target Service Account, granting the secretAccessor role to the Service Account on the secret, and finally executing the token exchange in the pipeline.
The sequence follows the logical dependency chain of Workload Identity Federation setup: first establishing trust via the Pool and Provider, defining mapped attribute conditions for security filtering, granting impersonation rights via workloadIdentityUser on the service account, granting least-privilege secret accessor permissions to the service account, and executing the client-side credential exchange.
Step-by-Step Solution
Key Concept
Workload Identity Federation and Service Account Lifecycle Security