Skip to content

Commit

Permalink
[Filebeat] fix organization and customer prefix for aws/cloudtrail (e…
Browse files Browse the repository at this point in the history
…lastic#23126)

* fix organization and customer prefix for aws/cloudtrail

- use ^.*AWSLogs as beginning of prefix, matches:
  + custom-prefix/AWSLogs/1234567890/CloudTrail/
  + o-xxxxxxx/AWSLogs/1234567890/CloudTrail/
  + AWSLogs/1234567890/CloudTrail/

Closes elastic#23109

Co-authored-by: Andrew Kroh <andrew.kroh@elastic.co>
(cherry picked from commit b4aba8e)
  • Loading branch information
leehinman committed Dec 15, 2020
1 parent bbd9da7 commit aca462c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.next.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ https://github.com/elastic/beats/compare/v7.0.0-alpha2...master[Check the HEAD d
- Fix aws s3 overview dashboard. {pull}23045[23045]
- Fix bad `network.direction` values in Fortinet/firewall fileset. {pull}23072[23072]
- Fix Cisco ASA/FTD module's parsing of WebVPN log message 716002. {pull}22966[22966]
- Add support for organization and custom prefix in AWS/CloudTrail fileset. {issue}23109[23109] {pull}23126[23126]

*Heartbeat*

Expand Down Expand Up @@ -672,4 +673,3 @@ port. {pull}19209[19209]




6 changes: 3 additions & 3 deletions x-pack/filebeat/module/aws/cloudtrail/config/s3.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@ type: s3
queue_url: {{ .queue_url }}
file_selectors:
{{ if .process_cloudtrail_logs }}
- regex: '^AWSLogs/\d+/CloudTrail/'
- regex: 'AWSLogs/\d+/CloudTrail/'
expand_event_list_from_field: 'Records'
{{ end }}

{{ if .process_digest_logs }}
- regex: '^AWSLogs/\d+/CloudTrail-Digest/'
- regex: 'AWSLogs/\d+/CloudTrail-Digest/'
{{ end }}

{{ if .process_insight_logs }}
- regex: '^AWSLogs/\d+/CloudTrail-Insight/'
- regex: 'AWSLogs/\d+/CloudTrail-Insight/'
expand_event_list_from_field: 'Records'
{{ end }}

Expand Down

0 comments on commit aca462c

Please sign in to comment.