mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 07:29:32 +00:00
Fix ext alert formatter
This commit is contained in:
parent
a14b6e5ab3
commit
0cff924bf8
1 changed files with 10 additions and 5 deletions
|
|
@ -57,12 +57,17 @@ function external_alert.format(ifid, alert, alert_type_params)
|
|||
return res
|
||||
end
|
||||
|
||||
-- Available fields:
|
||||
-- alert_type_params.source (e.g. suricata)
|
||||
-- alert_type_params.alert (alert metadata)
|
||||
local info = alert_type_params.alerts[tostring(flow_alert_keys.flow_alert_external)]
|
||||
if not info then
|
||||
return res
|
||||
end
|
||||
|
||||
if alert_type_params.source == "suricata" then
|
||||
res = formatIDSAlert(alert_type_params.alert)
|
||||
-- Available fields:
|
||||
-- info.source (e.g. suricata)
|
||||
-- info.alert (alert metadata)
|
||||
|
||||
if info.source == "suricata" and info.alert then
|
||||
res = formatIDSAlert(info.alert)
|
||||
end
|
||||
|
||||
return res
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue