File tree Expand file tree Collapse file tree 1 file changed +59
-0
lines changed
Expand file tree Collapse file tree 1 file changed +59
-0
lines changed Original file line number Diff line number Diff line change 1+ # Alert when there are 500 discovery detection events coming from the same ip, userAgent within 30 seconds.
2+
3+ # Rule name, must be unique
4+ name : Attack threshold exceeded
5+
6+ # Type of alert.
7+ type : percentage_match
8+
9+ # Alert when this many documents matching the query occur within a timeframe
10+ max_percentage : 10
11+
12+ # num_events must occur within this amount of time to trigger an alert
13+ timeframe :
14+ seconds : 60
15+
16+ # Index to search, wildcard supported
17+ index : bitsensor
18+ timestamp_field : endpoint.localtime
19+
20+ query_key :
21+ - context.ip
22+
23+ # A list of elasticsearch filters used for find events
24+ # These filters are joined with AND and nested in a filtered query
25+ # For more info: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl.html
26+ match_bucket_filter :
27+ - query :
28+ query_string :
29+ query : " _exists_:detections"
30+
31+ include :
32+ - endpoint.location
33+ - endpoint.name
34+ - context.http.userAgent
35+ - context.ip
36+ - context.php.session.sessionId
37+ - detections.type
38+ - detections.name
39+ - meta.user
40+ - errors
41+
42+ alert_subject : " Attack threshold exceeded by {}"
43+ alert_subject_args :
44+ - context.ip
45+
46+ alert_text_type : alert_text_only
47+ alert_text : " Time: {}\n IP: {} \n User-Agent: {}\n\n ID: {}\n User: {}"
48+ alert_text_args :
49+ - endpoint.localtime
50+ - context.ip
51+ - context.http.userAgent
52+ - _id
53+ - meta.user
54+
55+ # The alert is use when a match is found
56+ alert :
57+ - slack
58+ slack_webhook_url : " https://hooks.slack.com/services/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"
59+ slack_username_override : " ElastAlert"
You can’t perform that action at this time.
0 commit comments