Control: Ensure VM disks for critical VMs are encrypted with Customer-Supplied Encryption Keys (CSEK)
Description
Customer-Supplied Encryption Keys (CSEK) are a feature in Google Cloud Storage and Google Compute Engine. If you supply your own encryption keys, Google uses your key to protect the Google-generated keys used to encrypt and decrypt your data. By default, Google Compute Engine encrypts all data at rest. Compute Engine handles and manages this encryption for you without any additional actions on your part. However, if you wanted to control and manage this encryption yourself, you can provide your own encryption keys.
Usage
Run the control in your terminal:
powerpipe control run gcp_compliance.control.compute_disk_encrypted_with_csk
Snapshot and share results via Turbot Pipes:
powerpipe loginpowerpipe control run gcp_compliance.control.compute_disk_encrypted_with_csk --share
SQL
This control uses a named query:
select self_link resource, case when disk_encryption_key_type = 'Customer supplied' then 'ok' else 'alarm' end as status, case when disk_encryption_key_type = 'Customer supplied' then title || ' encrypted with customer-supplied encryption keys (CSEK).' when disk_encryption_key_type = 'Customer managed' then title || ' encrypted with customer-managed encryption keys.' else title || ' encrypted with default Google-managed keys.' end as reason , location as location, project as projectfrom gcp_compute_disk;