mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 07:29:32 +00:00
Implements #4941 Flow Alerts: Add L7 Column and Filter Menu
This commit is contained in:
parent
0b4e2757c1
commit
041a5de8b9
4 changed files with 90 additions and 18 deletions
|
|
@ -4035,6 +4035,35 @@ end
|
|||
|
||||
-- ###########################################
|
||||
|
||||
function create_ndpi_proto_name(v)
|
||||
local app = ""
|
||||
|
||||
if v["proto.ndpi"] then
|
||||
app = getApplicationLabel(v["proto.ndpi"])
|
||||
else
|
||||
local master_proto = interface.getnDPIProtoName(tonumber(v["l7_master_proto"]))
|
||||
local app_proto = interface.getnDPIProtoName(tonumber(v["l7_proto"]))
|
||||
|
||||
if master_proto == app_proto then
|
||||
app = app_proto
|
||||
elseif master_proto == "Unknown" then
|
||||
app = app_proto
|
||||
else
|
||||
app = master_proto
|
||||
|
||||
if app_proto ~= "Unknown" then
|
||||
app = app .. "." .. app_proto
|
||||
end
|
||||
end
|
||||
|
||||
app = getApplicationLabel(app)
|
||||
end
|
||||
|
||||
return app
|
||||
end
|
||||
|
||||
-- ###########################################
|
||||
|
||||
--- Insert an element inside the table if is not present
|
||||
function table.insertIfNotPresent(t, element, comp)
|
||||
if table.contains(t, element, comp) then return end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue