Logstash - Alter input for Wazuh logs

This commit is contained in:
Wes Lambert
2018-12-12 20:52:18 +00:00
parent 54c35cdc0d
commit 41e9c4c7e0

View File

@@ -9,7 +9,7 @@ input {
} }
} }
filter { filter {
if [type] == "ids" { if [type] == "ids" or [type] =~ "bro" {
mutate { mutate {
rename => { "host" => "beat_host" } rename => { "host" => "beat_host" }
remove_tag => ["beat"] remove_tag => ["beat"]
@@ -17,11 +17,10 @@ filter {
add_field => { "syslog-host_from" => "%{[beat][name]}" } add_field => { "syslog-host_from" => "%{[beat][name]}" }
} }
} }
if "bro" in [tags] { if [type] =~ "ossec" {
mutate { mutate {
rename => { "host" => "beat_host" } rename => { "host" => "beat_host" }
remove_tag => ["beat"] remove_tag => ["beat"]
add_field => { "sensor_name" => "%{[beat][name]}" }
add_field => { "syslog-host_from" => "%{[beat][name]}" } add_field => { "syslog-host_from" => "%{[beat][name]}" }
} }
} }