This check identifies BigQuery datasets configured to allow public or anonymous access, which can expose sensitive data to unauthorized users and increase the risk of data breaches. The vulnerability occurs when access controls use the special groups allAuthenticatedUsers or allUsers, effectively making data available to anyone with a Google account or the general public. To secure your BigQuery dataset, restrict access to specific users, groups, or domains instead of using public access groups, as shown in the example below:
# negative sample
resource"google_bigquery_dataset""negative1"{dataset_id="example_dataset"friendly_name="test"description="This is a test description"location="EU"default_table_expiration_ms=3600000labels={env="default"}access{role="OWNER"user_by_email=google_service_account.bqowner.email}access{role="READER"domain="hashicorp.com"}}
Non-Compliant Code Examples
resource"google_bigquery_dataset""positive1"{dataset_id="example_dataset"friendly_name="test"description="This is a test description"location="EU"default_table_expiration_ms=3600000labels={env="default"}access{role="OWNER"special_group="allAuthenticatedUsers"}}
1
2
rulesets:- Terraform / GCP # Rules to enforce / GCP.
맞춤형 데모 요청
Datadog 시작하기
Ask AI
AI-generated responses may be inaccurate. Verify important info.