turbot/steampipe-mod-terraform-aws-compliance

Control: ACM certificates should have transparency logging preference enabled

Description

This control checks whether ACM certificates transparency logging preference is enabled as certificate transparency logging guards against SSL/TLS certificates issued by mistake or by a compromised certificate authority.

Usage

Run the control in your terminal:

powerpipe control run terraform_aws_compliance.control.acm_certificate_transparency_logging_enabled

Snapshot and share results via Turbot Pipes:

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

SQL

This control uses a named query:

select
address as resource,
case
when (attributes_std -> 'options' ->> 'certificate_transparency_logging_preference')::text = 'ENABLED' then 'ok'
else 'alarm'
end status,
split_part(address, '.', 2) || case
when (attributes_std -> 'options' ->> 'certificate_transparency_logging_preference')::text = 'ENABLED' then ' certificate transparency logging preference enabled'
else ' certificate transparency logging preference disabled'
end || '.' reason
, path || ':' || start_line
from
terraform_resource
where
type = 'aws_acm_certificate';

Tags