mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-30 07:59:35 +00:00
Security fix - prevents non-admins to delete alerts via REST
This commit is contained in:
parent
a767ad1e26
commit
8f52f33e13
8 changed files with 41 additions and 0 deletions
|
|
@ -22,6 +22,11 @@ local user_alert_store = require "user_alert_store".new()
|
|||
local rc = rest_utils.consts.success.ok
|
||||
local res = {}
|
||||
|
||||
if not isAdministrator() then
|
||||
rest_utils.answer(rest_utils.consts.err.not_granted)
|
||||
return
|
||||
end
|
||||
|
||||
interface.select(getSystemInterfaceId())
|
||||
|
||||
-- Add filters
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue