Implements deletion of host persistent data

This commit is contained in:
Simone Mainardi 2018-05-14 19:47:49 +02:00
parent d2cc82a319
commit 8347406b63
5 changed files with 379 additions and 16 deletions

View file

@ -2,7 +2,7 @@
-- (C) 2013-18 - ntop.org
--
dirs = ntop.getDirs()
local dirs = ntop.getDirs()
package.path = dirs.installdir .. "/scripts/lua/modules/?.lua;" .. package.path
require "lua_utils"
@ -10,10 +10,12 @@ local json = require("dkjson")
sendHTTPContentTypeHeader('application/json', 'attachment; filename="exported_data.json"')
local mode = _GET["mode"]
tprint(_POST)
local mode = _POST["mode"]
if mode == "filtered" then
local host_info = url2hostinfo(_GET)
local host_info = url2hostinfo(_POST)
local host
if not isEmptyString(host_info["host"]) then