turbot/steampipe-mod-terraform-oci-compliance

Control: Ensure Cloud Guard is enabled in the root compartment of the tenancy

Description

Cloud Guard detects misconfigured resources and insecure activity within a tenancy and provides security administrators with the visibility to resolve these issues. Upon detection, Cloud Guard can suggest, assist, or take corrective actions to mitigate these issues. Cloud Guard should be enabled in the root compartment of your tenancy with the default configuration, activity detectors and responders.

Usage

Run the control in your terminal:

powerpipe control run terraform_oci_compliance.control.cloudguard_enabled

Snapshot and share results via Turbot Pipes:

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

SQL

This control uses a named query:

select
address as resource,
case
when (attributes_std ->> 'status') = 'ENABLED' then 'ok'
else 'alarm'
end as status,
split_part(address, '.', 2) || case
when coalesce((attributes_std ->> 'status'), '') = '' then ' ''status'' is not defined'
when (attributes_std ->> 'status') = 'ENABLED' then ' CloudGuard enabled'
else ' CloudGuard disabled'
end || '.' reason
, path || ':' || start_line
from
terraform_resource
where
type = 'oci_cloud_guard_cloud_guard_configuration';

Tags