turbot/steampipe-mod-terraform-aws-compliance

Control: Athena workgroup configuration should be enforced

Description

This control checks whether Athena Workgroup should enforce configuration to prevent client disabling encryption.

Usage

Run the control in your terminal:

powerpipe control run terraform_aws_compliance.control.athena_workgroup_enforce_workgroup_configuration

Snapshot and share results via Turbot Pipes:

powerpipe login
powerpipe control run terraform_aws_compliance.control.athena_workgroup_enforce_workgroup_configuration --share

SQL

This control uses a named query:

select
address as resource,
case
when (attributes_std -> 'configuration' -> 'enforce_workgroup_configuration')::boolean then 'ok'
else 'alarm'
end status,
split_part(address, '.', 2) || case
when (attributes_std -> 'configuration' -> 'enforce_workgroup_configuration')::boolean then ' enforce workgroup configuration set'
else ' enforce workgroup configuration not set'
end || '.' reason
, path || ':' || start_line
from
terraform_resource
where
type = 'aws_athena_workgroup';

Tags