GCP Associate Cloud Engineer Practice Question 89: Cloud Storage CMEK Service Agent
Google Cloud Associate Cloud Engineer · Test 9 · question 9 of 10
A team creates a new Cloud Storage bucket configured to use a customer-managed encryption key (CMEK) stored in Cloud KMS. After setting the default encryption key on the bucket, every object upload starts failing with a permission error related to the key. What is the most likely missing configuration?
Show answer and explanation
Answer:
Cloud Storage performs the actual encrypt and decrypt calls to Cloud KMS using its own per-project service agent, not the identity of the user or application uploading the object. If that service agent does not have the Cloud KMS CryptoKey Encrypter/Decrypter role on the key, every write to a CMEK-enabled bucket fails, because Cloud Storage itself cannot use the key on the caller's behalf.
Option A grants a much broader administrative role, and grants it to the wrong principal; uploading users do not need direct Cloud KMS permissions at all under CMEK, Cloud Storage's service agent does the key operations. Option C is unrelated; uniform bucket-level access controls whether ACLs or IAM govern object access, it has no bearing on whether the service agent can use the encryption key. Option D describes a command that does not exist; Cloud KMS keys are not moved between projects, and CMEK setups commonly keep the key in a different project than the bucket as long as the service agent is granted access to it.
Reference: Use customer-managed encryption keys