github.com/aquasecurity/trivy-iac@v0.8.1-0.20240127024015-3d8e412cf0ab/avd_docs/aws/cloudtrail/AVD-AWS-0163/CloudFormation.md (about)

     1  
     2  Enable access logging on the bucket
     3  
     4  ```yaml---
     5  Resources:
     6    GoodExampleTrail:
     7      Type: AWS::CloudTrail::Trail
     8      Properties:
     9        IsLogging: true
    10        S3BucketName: "my-bucket"
    11        TrailName: "Cloudtrail"
    12    GoodExampleBucket:
    13      Type: AWS::S3::Bucket
    14      Properties:
    15        BucketName: "my-bucket"
    16        LoggingConfiguration:
    17          DestinationBucketName: logging-bucket
    18          LogFilePrefix: accesslogs/
    19  
    20  ```
    21  
    22