turbot/terraform_aws_compliance

Query: ecr_repository_encrypted_with_kms

Usage

powerpipe query terraform_aws_compliance.query.ecr_repository_encrypted_with_kms

Steampipe Tables

SQL

select
address as resource,
case
when
(attributes_std ->> 'encryption_configuration') is not null
and coalesce((attributes_std -> 'encryption_configuration' ->> 'encryption_type'), '') = 'KMS'
then 'ok'
else 'alarm'
end as status,
split_part(address, '.', 2) || case
when
(attributes_std ->> 'encryption_configuration') is not null
and coalesce((attributes_std -> 'encryption_configuration' ->> 'encryption_type'), '') = 'KMS'
then ' encrypted using KMS'
else ' not encrypted using KMS'
end || '.' as reason
, path || ':' || start_line
from
terraform_resource
where
type = 'aws_ecr_repository';

Controls

The query is being used by the following controls: