mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-17 06:22:53 +01:00
Logstash Module - Change it to arrays
This commit is contained in:
@@ -2,7 +2,6 @@
|
||||
{%- set HOSTNAME = salt['grains.get']('host', '') %}
|
||||
|
||||
beat.name: {{ HOSTNAME }}
|
||||
beat.hostname: {{ HOSTNAME }}
|
||||
|
||||
#========================== Modules configuration ============================
|
||||
filebeat.modules:
|
||||
|
||||
@@ -11,21 +11,18 @@ input {
|
||||
filter {
|
||||
if "ids" in [tags] {
|
||||
mutate {
|
||||
add_field => {"sensor_name" => "%{[beat][name]}"}
|
||||
add_field => {"syslog-host_from" => "%{[beat][hostname]}"}
|
||||
rename => { "[beat][name]", "sensor_name" }
|
||||
rename => { "[beat][hostname]", "syslog-host_from" }
|
||||
remove_tag => ["beat"]
|
||||
rename => { "host" => "beat_host" }
|
||||
remove_field => ["[beat][name]", "[beat][hostname]"]
|
||||
}
|
||||
}
|
||||
|
||||
if "bro" in [tags] {
|
||||
mutate {
|
||||
add_field => {"sensor_name" => "%{[beat][name]}"}
|
||||
add_field => {"syslog-host_from" => "%{[beat][hostname]}"}
|
||||
rename => { "[beat][name]", "sensor_name" }
|
||||
rename => { "[beat][hostname]", "syslog-host_from" }
|
||||
remove_tag => ["beat"]
|
||||
rename => { "host" => "beat_host" }
|
||||
remove_field => ["[beat][name]", "[beat][hostname]"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user