Add logging for all non-get REST calls (fix #4279)

This commit is contained in:
Alfredo Cardigliano 2020-08-14 12:02:09 +02:00
parent 83d16879df
commit 1160066b08
6 changed files with 52 additions and 4 deletions

View file

@ -9,6 +9,7 @@ package.path = dirs.installdir .. "/scripts/lua/modules/pools/?.lua;" .. package
require "lua_utils"
local json = require ("dkjson")
local rest_utils = require("rest_utils")
local tracker = require("tracker")
--
-- Add a new ntopng user
@ -81,3 +82,8 @@ if limited_lifetime and not ntop.addUserLifetime(username, lifetime_secs) then
end
print(rest_utils.rc(rc, res))
-- TRACKER HOOK
-- Note: already tracked by ntop.addUser
-- tracker.log('add_ntopng_user', { username = username })