From: pmelange Date: Mon, 5 Nov 2018 13:03:35 +0000 (+0100) Subject: luci-base: network.lua add ipv6-prefix-assignment support to get_status_by_address X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=4fc3ab47378df1ffdf766df2c514122a0217a2de;p=oweals%2Fluci.git luci-base: network.lua add ipv6-prefix-assignment support to get_status_by_address Signed-off-by: pmelange --- diff --git a/modules/luci-base/luasrc/model/network.lua b/modules/luci-base/luasrc/model/network.lua index 7f7397032..49e1657aa 100644 --- a/modules/luci-base/luasrc/model/network.lua +++ b/modules/luci-base/luasrc/model/network.lua @@ -855,6 +855,14 @@ function get_status_by_address(self, addr) end end end + if s and s['ipv6-prefix-assignment'] then + local a + for _, a in ipairs(s['ipv6-prefix-assignment']) do + if a and a['local-address'] and a['local-address'].address == addr then + return net, s + end + end + end end end end