A healthcare organization is migrating an on-premises PostgreSQL database to Cloud SQL. Corporate governance mandates that all encryption keys protecting sensitive patient records must reside strictly within an on-premises physical Hardware Security Module (HSM) outside of Google Cloud. Additionally, key access must follow the principle of least privilege, granting permission only to the necessary service identity. Which key management architecture and IAM configuration meets these regulatory requirements?
- Configure Cloud SQL to use Customer-Managed Encryption Keys (CMEK) integrated with Cloud EKM pointing to the on-premises HSM, and grant the Cloud SQL Service Agent the Cloud KMS CryptoKey Encrypter/Decrypter role on the key.Answer
- BImplement Customer-Supplied Encryption Keys (CSEK) by embedding raw 256-bit AES key material directly into the Cloud SQL database connection strings and deployment configurations.
- CConfigure Cloud SQL to use Customer-Managed Encryption Keys (CMEK) backed by Cloud KMS, and grant the Project Owner primitive role to the Cloud SQL service account to guarantee persistent key access during automatic key rotations.
- DDeploy Cloud SQL using Google-default encryption keys and configure VPC Service Controls perimeters to handle external key encryption automatically for database persistent disks.
Answer
Configure Cloud SQL with CMEK integrated with Cloud EKM pointing to the on-premises HSM, and assign the Cloud KMS CryptoKey Encrypter/Decrypter role to the Cloud SQL Service Agent.
Customer-Managed Encryption Keys (CMEK) integrated with Cloud EKM (External Key Manager) allow Google Cloud services like Cloud SQL to perform data encryption and decryption while holding the root cryptographic keys within an external, on-premises Hardware Security Module (HSM). Granting the Cloud KMS CryptoKey Encrypter/Decrypter role strictly to the Cloud SQL Service Agent satisfies least-privilege security requirements.
Step-by-Step Solution
Key Concept
Cloud EKM with CMEK for external key sovereignty and fine-grained Cloud KMS IAM roles