mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-03-09 15:40:03 +00:00
Display as direct output when public IP is the same as one wan public ip
This commit is contained in:
parent
eedbfc56b7
commit
dc01b097d2
50 changed files with 6 additions and 11468 deletions
|
@ -1489,6 +1489,9 @@ function interfaces_status()
|
|||
whois = ut.trim(sys.exec("whois " .. publicIP .. " | grep -i 'netname' | awk '{print $2}'"))
|
||||
--whois = ut.trim(sys.exec("wget -4 -qO- -T 1 'http://api.iptoasn.com/v1/as/ip/" .. publicIP .. "' | jsonfilter -q -e '@.as_description'"))
|
||||
end
|
||||
if publicIP == mArray.openmptcprouter["wan_addr"] then
|
||||
mArray.openmptcprouter["direct_output"] = true
|
||||
end
|
||||
end
|
||||
if publicIP6 ~= "" then
|
||||
whois6 = uci:get("openmptcprouter",interface,"asn") or ""
|
||||
|
@ -1496,6 +1499,9 @@ function interfaces_status()
|
|||
whois6 = ut.trim(sys.exec("whois " .. publicIP6 .. " | grep -i 'netname' | awk '{print $2}'"))
|
||||
--whois6 = ut.trim(sys.exec("wget -6 -qO- -T 1 'http://api.iptoasn.com/v1/as/ip/" .. publicIP6 .. "' | jsonfilter -q -e '@.as_description'"))
|
||||
end
|
||||
if publicIP6 == mArray.openmptcprouter["wan_addr6"] then
|
||||
mArray.openmptcprouter["direct_output"] = true
|
||||
end
|
||||
end
|
||||
if ifname ~= "" and ifname ~= nil then
|
||||
if fs.access("/sys/class/net/" .. ifname) then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue