mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-30 16:09:32 +00:00
[VS] Add badge for in progress scans (#8008)
This commit is contained in:
parent
9ad2291aee
commit
41bdec5489
2 changed files with 11 additions and 1 deletions
|
|
@ -5,6 +5,7 @@
|
|||
local dirs = ntop.getDirs()
|
||||
|
||||
package.path = dirs.installdir .. "/scripts/lua/modules/?.lua;" .. package.path
|
||||
package.path = dirs.installdir .. "/scripts/lua/modules/vulnerability_scan/?.lua;" .. package.path
|
||||
|
||||
-- trace_script_duration = true
|
||||
|
||||
|
|
@ -15,6 +16,7 @@ local callback_utils = require("callback_utils")
|
|||
local recording_utils = require("recording_utils")
|
||||
local rest_utils = require("rest_utils")
|
||||
local auth = require "auth"
|
||||
local vs_utils = require "vs_utils"
|
||||
|
||||
--
|
||||
-- Read information about an interface
|
||||
|
|
@ -301,7 +303,10 @@ function dumpBriefInterfaceStats(ifid)
|
|||
res["drops"] = ifstats.stats_since_reset.drops
|
||||
|
||||
res["throughput_bps"] = ifstats.stats.throughput_bps;
|
||||
|
||||
if (vs_utils.is_available()) then
|
||||
local total, total_in_progress = vs_utils.check_in_progress_status()
|
||||
res["vs_in_progress"] = total_in_progress or 0
|
||||
end
|
||||
if prefs.is_dump_flows_enabled == true then
|
||||
res["flow_export_drops"] = ifstats.stats_since_reset.flow_export_drops
|
||||
res["flow_export_count"] = ifstats.stats_since_reset.flow_export_count
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue