Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Filebeat] Improve ECS categorization field mappings for zeek module #17738

Merged
merged 4 commits into from
Apr 29, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.next.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,7 @@ https://github.com/elastic/beats/compare/v7.0.0-alpha2...master[Check the HEAD d
- Improve ECS categorization field mappings in postgresql module. {issue}16177[16177] {pull}17914[17914]
- Improve ECS categorization field mappings in rabbitmq module. {issue}16178[16178] {pull}17916[17916]
- Improve ECS categorization field mappings in redis module. {issue}16179[16179] {pull}17918[17918]
- Improve ECS categorization field mappings for zeek module. {issue}16029[16029] {pull}17738[17738]

*Heartbeat*

Expand Down
28 changes: 0 additions & 28 deletions x-pack/filebeat/module/zeek/capture_loss/ingest/pipeline.json

This file was deleted.

21 changes: 21 additions & 0 deletions x-pack/filebeat/module/zeek/capture_loss/ingest/pipeline.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
description: Pipeline for normalizing Zeek capture_loss.log
processors:
- set:
field: event.created
value: '{{_ingest.timestamp}}'
- date:
field: zeek.capture_loss.ts
formats:
- UNIX
- remove:
field: zeek.capture_loss.ts
- set:
field: event.kind
value: metric
- set:
field: event.type
value: info
on_failure:
- set:
field: error.message
value: '{{ _ingest.on_failure_message }}'
2 changes: 1 addition & 1 deletion x-pack/filebeat/module/zeek/capture_loss/manifest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ var:
- name: tags
default: [zeek.capture_loss]

ingest_pipeline: ingest/pipeline.json
ingest_pipeline: ingest/pipeline.yml
input: config/capture_loss.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
{
"@timestamp": "2019-09-10T16:19:28.465Z",
"event.dataset": "zeek.capture_loss",
"event.kind": "metric",
"event.module": "zeek",
"event.type": "info",
"fileset.name": "capture_loss",
"input.type": "log",
"log.offset": 0,
Expand Down
19 changes: 13 additions & 6 deletions x-pack/filebeat/module/zeek/connection/config/connection.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,20 +75,27 @@ processors:

ignore_missing: true
fail_on_error: false

- convert:
fields:
- {from: "zeek.session_id", to: "event.id"}
- {from: "source.address", to: "source.ip", type: "ip"}
- {from: "destination.address", to: "destination.ip", type: "ip"}
ignore_missing: true
fail_on_error: false
- add_fields:
target: event
fields:
kind: event
category:
- network
{{ if .community_id }}
- if:
equals.network.transport: icmp
then:
community_id:
fields:
source_ip: source.address
destination_ip: destination.address
icmp_type: zeek.connection.icmp.type
icmp_code: zeek.connection.icmp.code
else:
community_id:
fields:
source_ip: source.address
destination_ip: destination.address
{{ end }}
160 changes: 0 additions & 160 deletions x-pack/filebeat/module/zeek/connection/ingest/pipeline.json

This file was deleted.

Loading