- A
Enable mutual TLS for all connections to the Cloud SQL instance.
Why wrong: mTLS authenticates clients but does not control decryption key access.
- B
Set up a service account with Cloud KMS CryptoKey Encrypter/Decrypter and attach it to authorized VMs.
This ensures only specific VMs can decrypt, coupling compute access with key access.
- C
Use VPC Service Controls to restrict access to the Cloud SQL instance and the key.
Why wrong: VPC SC restricts data exfiltration but does not control granular decryption permissions.
- D
Configure Cloud SQL to use Cloud Armor to whitelist IP addresses.
Why wrong: Cloud Armor is for HTTP(S) load balancing, not for Cloud SQL access control.
Quick Answer
The correct answer is to set up a service account with the Cloud KMS CryptoKey Encrypter/Decrypter role and attach it to authorized VMs. This is required because Cloud SQL with CMEK enforces data-at-rest encryption using a customer-managed key, and any compute resource—such as a Compute Engine VM—must possess the decryption permission on that specific key to access the database. Without this IAM binding, the Cloud SQL instance would reject the connection even if network rules allow it, as the decryption capability is tied directly to the resource’s identity. On the Google Professional Cloud Security Engineer exam, this scenario tests your understanding of how CMEK shifts access control from network-level to identity-level enforcement, a common trap where candidates mistakenly focus on VPC firewall rules instead of IAM roles. Remember the mnemonic: “Key to the key” — the service account holds the key to decrypt the CMEK key, so only VMs with that account can unlock the data.
PCSE Ensuring data protection Practice Question
This PCSE practice question tests your understanding of ensuring data protection. This is a configuration task: choose the command set that satisfies every stated requirement. Small differences — like 'secret' vs 'password' or 'transport input ssh' vs 'all' — change whether the answer is correct. After answering, compare your reasoning against the explanation and wrong-answer breakdown below. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.
A company uses Cloud SQL for PostgreSQL with CMEK. They need to ensure that the Cloud SQL instance can only be accessed by authorized compute resources that have the correct IAM permissions to decrypt the data. What additional configuration is required to enforce access control?
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
Set up a service account with Cloud KMS CryptoKey Encrypter/Decrypter and attach it to authorized VMs.
Option B is correct because Cloud SQL with CMEK requires that any compute resource accessing the instance must have the Cloud KMS CryptoKey Encrypter/Decrypter IAM role on the key. By attaching a service account with this role to authorized VMs, you ensure that only those VMs can decrypt the data at rest, enforcing access control at the IAM level. This directly ties the decryption permission to the compute resource's identity, not just network-level access.
Key principle: Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Enable mutual TLS for all connections to the Cloud SQL instance.
Why it's wrong here
mTLS authenticates clients but does not control decryption key access.
- ✓
Set up a service account with Cloud KMS CryptoKey Encrypter/Decrypter and attach it to authorized VMs.
Why this is correct
This ensures only specific VMs can decrypt, coupling compute access with key access.
Related concept
Read the scenario before looking for a memorised answer.
- ✗
Use VPC Service Controls to restrict access to the Cloud SQL instance and the key.
Why it's wrong here
VPC SC restricts data exfiltration but does not control granular decryption permissions.
- ✗
Configure Cloud SQL to use Cloud Armor to whitelist IP addresses.
Why it's wrong here
Cloud Armor is for HTTP(S) load balancing, not for Cloud SQL access control.
Common exam traps
Common exam trap: answer the scenario, not the keyword
Google Cloud often tests the distinction between network-level access controls (like VPC Service Controls or Cloud Armor) and IAM-based key authorization, leading candidates to choose perimeter security options instead of the correct identity-based decryption permission.
Detailed technical explanation
How to think about this question
CMEK uses Cloud KMS to wrap the data encryption keys (DEKs) that encrypt the Cloud SQL data. When a client connects, the Cloud SQL proxy or the database engine must unwrap the DEK using the KMS key, which requires the caller to have the cloudkms.cryptoKeyVersions.useToDecrypt permission. This permission is granted via the CryptoKey Encrypter/Decrypter role, and the service account attached to the VM must be authorized in the key's IAM policy. In practice, if the VM's service account lacks this role, the Cloud SQL instance will fail to decrypt its data, effectively denying access even if network connectivity exists.
KKey Concepts to Remember
- Read the scenario before looking for a memorised answer.
- Find the constraint that changes the correct option.
- Eliminate answers that are true in general but not in this case.
TExam Day Tips
- Watch for words such as best, first, most likely and least administrative effort.
- Review why wrong options are wrong, not only why the correct option is correct.
Key takeaway
Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.
Real-world example
How this comes up in practice
A company's IT admin needs to give a contractor read-only access to production logs without sharing account credentials. Using role-based access control (RBAC) and temporary scoped permissions — not a permanent shared password — is the correct pattern. Questions like this test whether you can apply least-privilege access across cloud identity services.
What to study next
Got this wrong? Here's your next step.
Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.
- →
Ensuring data protection — study guide chapter
Learn the concepts, then practise the questions
- →
Ensuring data protection practice questions
Targeted practice on this topic area only
- →
All PCSE questions
500 questions across all exam domains
- →
Google Professional Cloud Security Engineer study guide
Full concept coverage aligned to exam objectives
- →
PCSE practice test guide
How to use practice tests most effectively before exam day
Related practice questions
Related PCSE practice-question pages
Use these pages to review the topic behind this question. This is how one missed question becomes focused revision.
Configuring network security practice questions
Practise PCSE questions linked to Configuring network security.
Configuring access within a cloud solution environment practice questions
Practise PCSE questions linked to Configuring access within a cloud solution environment.
Ensuring data protection practice questions
Practise PCSE questions linked to Ensuring data protection.
Managing operations in a cloud solution environment practice questions
Practise PCSE questions linked to Managing operations in a cloud solution environment.
Supporting compliance requirements practice questions
Practise PCSE questions linked to Supporting compliance requirements.
PCSE fundamentals practice questions
Practise PCSE questions linked to PCSE fundamentals.
PCSE scenario practice questions
Practise PCSE questions linked to PCSE scenario.
PCSE troubleshooting practice questions
Practise PCSE questions linked to PCSE troubleshooting.
Practice this exam
Start a free PCSE practice session
Short sessions build daily habit. Longer sessions build exam-day stamina. Try a timed session to simulate real conditions.
FAQ
Questions learners often ask
What does this PCSE question test?
Ensuring data protection — This question tests Ensuring data protection — Read the scenario before looking for a memorised answer..
What is the correct answer to this question?
The correct answer is: Set up a service account with Cloud KMS CryptoKey Encrypter/Decrypter and attach it to authorized VMs. — Option B is correct because Cloud SQL with CMEK requires that any compute resource accessing the instance must have the Cloud KMS CryptoKey Encrypter/Decrypter IAM role on the key. By attaching a service account with this role to authorized VMs, you ensure that only those VMs can decrypt the data at rest, enforcing access control at the IAM level. This directly ties the decryption permission to the compute resource's identity, not just network-level access.
What should I do if I get this PCSE question wrong?
Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.
What is the key concept behind this question?
Read the scenario before looking for a memorised answer.
About these practice questions
Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →
Same concept, more angles
1 more ways this is tested on PCSE
These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.
Variation 1. A company wants to ensure that all data stored in Cloud Storage buckets is encrypted with a customer-managed key (CMEK) that is managed in Cloud KMS. The security team requires that only authorized applications can access the key. Which configuration step should be taken to achieve this?
easy- A.Use a customer-supplied encryption key (CSEK) instead of CMEK.
- ✓ B.Grant the Cloud KMS CryptoKey Encrypter/Decrypter role to the Cloud Storage service account at the Cloud KMS key resource.
- C.Create a bucket with default encryption set to use a CMEK, and grant the service account the Cloud KMS Admin role.
- D.Grant the Cloud KMS CryptoKey Encrypter/Decrypter role to the Cloud Storage service account at the project level.
Why B: Option B is correct because Cloud Storage uses its own Google-managed service account to interact with Cloud KMS when encrypting or decrypting data with a CMEK. By granting the Cloud KMS CryptoKey Encrypter/Decrypter role to the Cloud Storage service account at the specific key resource, you authorize only that service account to use the key, ensuring that only authorized applications (via Cloud Storage) can access the key. This follows the principle of least privilege and meets the security team's requirement.
Last reviewed: Jun 30, 2026
This PCSE practice question is part of Courseiva's free Google Cloud certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the PCSE exam.
Question Discussion
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
Sign in to join the discussion.