Fix crit/warn bug with Defender alerts.
This commit is contained in:
parent
5fa472f450
commit
36a998cfc6
Binary file not shown.
BIN
check_mk-azure/azure-spearhead-0.1.1.mkp
Executable file
BIN
check_mk-azure/azure-spearhead-0.1.1.mkp
Executable file
Binary file not shown.
@ -210,7 +210,7 @@ def check_defender(item, params, section):
|
||||
if status != "Active" and status != "InProgress":
|
||||
return
|
||||
|
||||
severity = details["status"]
|
||||
severity = details["severity"]
|
||||
url = details["url"]
|
||||
info = details["info"]
|
||||
|
||||
@ -218,8 +218,10 @@ def check_defender(item, params, section):
|
||||
state = State.CRIT
|
||||
elif severity == "Medium":
|
||||
state = State.WARN
|
||||
else:
|
||||
elif severity == "Low":
|
||||
state = State.OK
|
||||
else:
|
||||
state = State.UNKNOWN
|
||||
|
||||
yield Result(
|
||||
state=state,
|
||||
|
Loading…
Reference in New Issue
Block a user