turbot/gcp_insights

Query: pubsub_topic_encryption_details

Usage

powerpipe query gcp_insights.query.pubsub_topic_encryption_details

SQL

select
k.name as "KMS Key Name",
k.key_ring_name as "Key Ring Name",
k.create_time as "Create Time",
k.title as "Title",
nullif(split_part(k.rotation_period, 's', 1), '')::int / ( 60 * 60 * 24) as "Rotation Period",
k.location as "Location"
from
gcp_pubsub_topic p,
gcp_kms_key k
where
split_part(p.kms_key_name, 'cryptoKeys/', 2) = k.name
and p.self_link = $1;

Dashboards

The query is used in the dashboards: