turbot/turbot

steampipe plugin install turbotsteampipe plugin install turbot

Table: turbot_policy_type

List all the policy types known to Turbot.

Examples

List all policy types

select
id,
uri,
trunk_title
from
turbot_policy_type
order by
trunk_title

List all policy types for AWS S3

select
id,
uri,
trunk_title
from
turbot_policy_type
where
mod_uri like 'tmod:@turbot/aws-s3%'
order by
trunk_title

Count policy types by cloud provider

select
sum(case when mod_uri like 'tmod:@turbot/aws-%' then 1 else 0 end) as aws,
sum(case when mod_uri like 'tmod:@turbot/azure-%' then 1 else 0 end) as azure,
sum(case when mod_uri like 'tmod:@turbot/gcp-%' then 1 else 0 end) as gcp,
count(*) as total
from
turbot_policy_type

Policy types that target AWS > S3 > Bucket

select
trunk_title,
uri,
targets
from
turbot_policy_type
where
targets ? 'tmod:@turbot/aws-s3#/resource/types/bucket'

.inspect turbot_policy_type

Policy types define the types of controls known to Turbot.

NameTypeDescription
akasjsonbAKA (also known as) identifiers for the policy type.
category_idbigintID of the control category for the policy type.
category_uritextURI of the control category for the policy type.
create_timestamptimestamp without time zoneWhen the policy type was first discovered by Turbot. (It may have been created earlier.)
default_templatetextDefault template used to calculate template-based policy values. Should be a Jinja based YAML string.
descriptiontextDescription of the policy type.
icontextIcon of the policy type.
idbigintUnique identifier of the policy type.
mod_uritextURI of the mod that contains the policy type.
parent_idtextID for the parent of this policy type.
pathjsonbHierarchy path with all identifiers of ancestors of the policy type.
read_onlybooleanIf true user-defined policy settings are blocked from being created.
schemajsonbJSON schema defining the allowed schema for policy values for any targeted resources.
secretbooleanJSON schema defining valid values for the policy type.
secret_leveltextSecret Level: SECRET, CONFIDENTIAL or NONE.
targetsjsonbURIs of the resource types targeted by this policy type.
titletextTitle of the policy type.
trunk_titletextTitle with full path of the policy type.
update_timestamptimestamp without time zoneWhen the policy type was last updated in Turbot.
uritextURI of the policy type.
version_idbigintUnique identifier for this version of the policy type.