turbot/steampipe-mod-gcp-compliance

Control: Alloy DB clusters should use customer-managed encryption key (CMEK) for encryption

Usage

Run the control in your terminal:

powerpipe control run gcp_compliance.control.alloydb_cluster_encrypted_with_cmk

Snapshot and share results via Turbot Pipes:

powerpipe login
powerpipe control run gcp_compliance.control.alloydb_cluster_encrypted_with_cmk --share

SQL

This control uses a named query:

select
self_link resource,
case
when encryption_info ->> 'encryptionType' = 'CUSTOMER_MANAGED_ENCRYPTION' then 'ok'
else 'alarm'
end as status,
case
when encryption_info ->> 'encryptionType' = 'CUSTOMER_MANAGED_ENCRYPTION' then title || ' encrypted with customer-managed encryption keys.'
else title || ' encrypted with Google-managed encryption keys.'
end as reason
, location as location, project as project
from
gcp_alloydb_cluster;

Tags