X-Git-Url: http://git.archive.openwrt.org/?a=blobdiff_plain;f=modules%2Fadmin-full%2Fluasrc%2Fview%2Fadmin_status%2Froutes.htm;h=4e7287b70524e04b297c4538594345a8165d377c;hb=70e5124557fc642e1e5fec681524f481e64c358a;hp=0b37abbdde9e3a2671e26e962f254b9465873048;hpb=8fcd841aa9af96c8a4a4d3c1a555d2d1ed42332c;p=project%2Fluci.git diff --git a/modules/admin-full/luasrc/view/admin_status/routes.htm b/modules/admin-full/luasrc/view/admin_status/routes.htm index 0b37abbdd..4e7287b70 100644 --- a/modules/admin-full/luasrc/view/admin_status/routes.htm +++ b/modules/admin-full/luasrc/view/admin_status/routes.htm @@ -25,26 +25,46 @@ $Id$ <%+header%>
-

<%:a_n_routes%>

-
<%:a_n_routes1%>
+

<%:Routes%>

+
<%:The following rules are currently active on this system.%>
- <%:a_n_routes_kernel4%> + ARP +
+ + + + + + + + <% luci.sys.net.arptable(function(e) %> + + + + + + <% style = not style; end) %> +
<%_IPv4-Address%><%_MAC-Address%><%:Interface%>
<%=e["IP address"]%><%=e["HW address"]%><%=e["Device"]%>
+
+
+
+ +
+ <%_Active IPv4-Routes%>
- - - - - + + + + <% luci.sys.net.routes(function(rt) %> - - + @@ -54,29 +74,27 @@ $Id$
- <% if fs.access("/proc/net/ipv6_route") then style = true %> + <% if nixio.fs.access("/proc/net/ipv6_route") then + style = true + fe80 = luci.ip.IPv6("fe80::/10") + %>
- <%:a_n_routes_kernel6%> + <%_Active IPv6-Routes%>
<%:network%><%:target%><%:netmask%><%:gateway%><%:metric%><%:Network%><%:Target%><%_IPv4-Gateway%><%:Metric%>
<%=luci.tools.webadmin.iface_get_network(rt.device) or rt.device%><%=rt.dest:network():string()%><%=rt.dest:mask():string()%><%=rt.dest:string()%> <%=rt.gateway:string()%> <%=rt.metric%>
- - - - + + + + - <% luci.sys.net.routes6(function(rt) %> + <% luci.sys.net.routes6(function(rt) if fe80:contains(rt.dest) then return end %> - + - + <% style = not style; end) %>
<%:network%><%:target%><%:gateway6%><%:metric%><%:Network%><%:Target%><%_IPv6-Gateway%><%:Metric%>
<%=luci.tools.webadmin.iface_get_network(rt.device) or rt.device%><%=luci.tools.webadmin.iface_get_network(rt.device) or '(' .. rt.device .. ')'%> <%=rt.dest:string()%> <%=rt.source:string()%><%- - local metr = rt.metric - local lower = bit.band(metr, 0xffff) - local higher = bit.rshift(bit.band(metr, 0xffff0000), 16) - write(string.format("%04X%04X", higher, lower)) - -%><%=rt.metric_raw:upper()%>