Added invalid interface check (#6241)

This commit is contained in:
Matteo Biscosi 2022-01-27 12:57:17 +01:00
parent 5c3a838086
commit 8a2b06ed6e

View file

@ -29,7 +29,7 @@ local what = _GET["status"] -- historical, historical-flows
local epoch_begin = _GET["epoch_begin"]
local epoch_end = _GET["epoch_end"]
if isEmptyString(ifid) then
if isEmptyString(ifid) or not interface.isValidIfId(ifid) then
print(rest_utils.rc(rest_utils.consts.err.invalid_interface))
return
end