Project: KICS (Provisioning / Security & Compliance)
File: c065b98e-1515-4991-9dca-b602bd6a2fbb.md

title: Action Trail Logging For All Regions Disabled hide: toc: true navigation: true <style> .highlight .hll { background-color: #ff171742; } .md-content { max-width: 1100px; margin: 0 auto; } </style> Query id: c065b98e-1515-4991-9dca-b602bd6a2fbb Query name: Action Trail Logging For All Regions Disabled Platform: Terraform Severity: <span style="color:#ff7213">Medium</span> Category: Observability URL: Action Trail Logging for all regions should be enabled<br> ```tf title="Positive test num. 1 - tf file" hl_lines="6" resource "alicloudactiontrailtrail" "actiontrail2" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" ossbucketname = "bucket_name" event_rw = "All" trail_region = "cn-hangzhou" } ``` ```tf title="Positive test num. 2 - tf file" hl_lines="5 6" resource "alicloudactiontrailtrail" "actiontrail3" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" ossbucketname = "bucket_name" event_rw = "Read" trail_region = "cn-hangzhou" } ``` ```tf title="Positive test num. 3 - tf file" hl_lines="5 6" resource "alicloudactiontrailtrail" "actiontrail4" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" ossbucketname = "bucket_name" event_rw = "Write" trail_region = "cn-hangzhou" } ``` <details><summary>Positive test num. 4 - tf file</summary> ```tf hl_lines="6" resource "alicloudactiontrailtrail" "actiontrail5" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" ossbucketname = "bucket_name" event_rw = "All" trail_region = "cn-beijing" } ``` </details> <details><summary>Positive test num. 5 - tf file</summary> ```tf hl_lines="5 6" resource "alicloudactiontrailtrail" "actiontrail6" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" ossbucketname = "bucket_name" event_rw = "Read" trail_region = "cn-beijing" } ``` </details> <details><summary>Positive test num. 6 - tf file</summary> ```tf hl_lines="5 6" resource "alicloudactiontrailtrail" "actiontrail7" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" ossbucketname = "bucket_name" event_rw = "Write" trail_region = "cn-beijing" } ``` </details> <details><summary>Positive test num. 7 - tf file</summary> ```tf hl_lines="1" resource "alicloudactiontrailtrail" "actiontrail8" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" ossbucketname = "bucket_name" event_rw = "All" } ``` </details> <details><summary>Positive test num. 8 - tf file</summary> ```tf hl_lines="1" resource "alicloudactiontrailtrail" "actiontrail9" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" ossbucketname = "bucket_name" trail_region = "All" } ``` </details> <details><summary>Positive test num. 9 - tf file</summary> ```tf hl_lines="1" resource "alicloudactiontrailtrail" "actiontrail10" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" trail_region = "All" } ``` </details> ```tf title="Negative test num. 1 - tf file" resource "alicloudactiontrailtrail" "actiontrail1" { trail_name = "action-trail" osswriterole_arn = "acs:ram::1182725xxxxxxxxxxx" ossbucketname = "bucket_name" event_rw = "All" trail_region = "All" } ```