mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-30 07:59:35 +00:00
Allow vlan interfaces
This commit is contained in:
parent
49c0dd037f
commit
c29e84314e
1 changed files with 7 additions and 0 deletions
|
|
@ -978,6 +978,13 @@ local function allowedDevName(devname)
|
|||
allowed_interfaces = ntop.listInterfaces()
|
||||
end
|
||||
|
||||
-- Stripping out vlan id, if any (support vlan interfaces)
|
||||
local devnamevlan = string.split(devname, "%.")
|
||||
if devnamevlan and devnamevlan[1] then
|
||||
devname = devnamevlan[1]
|
||||
-- vlan = devnamevlan[2]
|
||||
end
|
||||
|
||||
-- Interface is allowed if it appears in the list retrieved from C
|
||||
return allowed_interfaces[devname]
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue