Prepare and test your skills
Prepare and test your skills
Free sample question, answered and explained below. The Professional Cloud DevOps Engineer practice bank has 1,455 more like it. Try 10 free: instant score, no account.
Your organization uses an external CI/CD pipeline running in an external cloud provider to deploy application infrastructure. The pipeline needs to decrypt sensitive deployment configuration files using a Cloud KMS key before initiating rollout.
To meet strict security compliance, your implementation must satisfy the following requirements:
Which configuration should you implement?
This architecture establishes a secure, keyless authentication bridge between external CI/CD pipeline runners and Google Cloud resources by combining Workload Identity Federation (WIF), fine-grained Cloud Key Management Service (Cloud KMS) access control, and comprehensive Cloud Audit Logging.
roles/cloudkms.cryptoKeyDecrypter strictly at the individual CryptoKey level (rather than across the entire KeyRing or project) ensures the service account can only decrypt payloads without having permissions to encrypt, destroy, or manage key configurations.This approach creates a traditional, exportable service account key file and assigns decryption permissions broadly across the entire project.
roles/cloudkms.cryptoKeyDecrypter at the project level allows the service account to decrypt ciphertexts using any CryptoKey present in any KeyRing within the project.The external environment was legacy infrastructure incapable of OpenID Connect (OIDC) token exchange and required long-lived credentials for basic service authentication.
This configuration grants administrative control over the cryptographic key lifecycle to the service account and grants Workload Identity Pool administrative privileges to the pipeline runner.
roles/cloudkms.admin role provides administrative capabilities (e.g., creating keys, updating rotation policies, setting IAM policies) but does not even provide cryptographic decryption capabilities (cloudkms.cryptoKeyVersions.useToDecrypt).roles/iam.workloadIdentityPoolAdmin allows the pipeline runner to modify pool providers and attribute mappings, which could permit a compromised runner to change trust relationships and spoof identities.The pipeline's objective was to provision and manage IAM workload pools and Cloud KMS infrastructure rather than decrypt configuration secrets during runtime.
This configuration maps external user account names directly into a Workload Identity Pool and assigns cryptographic roles at the broader KeyRing level.
roles/cloudkms.cryptoKeyEncrypterDecrypter at the KeyRing resource grants both encryption and decryption access to all keys within that KeyRing, exceeding the required read-only decryption need on a single key.username is unsafe because external usernames can be modified or reassigned after user deletion, allowing spoofing attacks.The pipeline needed bidirectional cryptographic operations across all keys in the KeyRing and the external identity provider guaranteed that usernames were immutable and unique.
Answer them yourself and get your score the moment you finish. No account needed.
Full access includes
Keep the momentum going with these hand-picked practice scenarios
Last updated Validated