turbot/steampipe-mod-terraform-oci-compliance

Control: Ensure VCN has at least one inbound security list configured

Description

This control checks if a VCN has at least one inbound security list configured.

Usage

Run the control in your terminal:

powerpipe control run terraform_oci_compliance.control.vcn_has_inbound_security_list_configured

Snapshot and share results via Turbot Pipes:

powerpipe login
powerpipe control run terraform_oci_compliance.control.vcn_has_inbound_security_list_configured --share

SQL

This control uses a named query:

select
address as resource,
case
when (attributes_std -> 'ingress_security_rules' ->> 'protocol') is not null then 'ok'
else 'alarm'
end as status,
split_part(address, '.', 2) || case
when (attributes_std -> 'ingress_security_rules' ->> 'protocol') is not null then ' has inbound security list configured'
else ' has no inbound security list configured'
end || '.' reason
, path || ':' || start_line
from
terraform_resource
where
type = 'oci_core_security_list';

Tags