turbot/steampipe-mod-gcp-compliance

Control: Check if BigQuery datasets are publicly readable

Usage

Run the control in your terminal:

powerpipe control run gcp_compliance.control.require_bq_table_iam

Snapshot and share results via Turbot Pipes:

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

SQL

This control uses a named query:

select
self_link resource,
case
when access @> '[{"specialGroup": "allAuthenticatedUsers"}]' or access @> '[{"iamMember": "allUsers"}]' then 'alarm'
else 'ok'
end as status,
case
when access @> '[{"specialGroup": "allAuthenticatedUsers"}]' or access @> '[{"iamMember": "allUsers"}]'
then title || ' publicly accessible.'
else title || ' not anonymously or publicly accessible.'
end as reason
, location as location, project as project
from
gcp_bigquery_dataset;

Tags