forked from opensearch-project/OpenSearch
-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding logstash pipeline for python script
- Loading branch information
Showing
1 changed file
with
35 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
input { | ||
opensearch { | ||
hosts => ["127.0.0.1:9200"] | ||
user => "${WAZUH_INDEXER_USERNAME}" | ||
password => "${WAZUH_INDEXER_PASSWORD}" | ||
index => "wazuh-alerts-4.x-*" | ||
ssl => true | ||
ca_file => "/etc/logstash/wi-certs/root-ca.pem" | ||
query => '{ | ||
"query": { | ||
"range": { | ||
"@timestamp": { | ||
"gt": "now-1m" | ||
} | ||
} | ||
} | ||
}' | ||
target => "_source" | ||
schedule => "* * * * *" | ||
} | ||
} | ||
|
||
output { | ||
|
||
stdout { codec => rubydebug } | ||
|
||
pipe | ||
{ | ||
id => "securityLake" | ||
message_format => "%{_source}" | ||
ttl => "10" | ||
command => "/usr/bin/env python3 /usr/local/bin/stdin_to_securitylake.py -d" | ||
} | ||
|
||
} |