diff --git a/home/dns.go b/home/dns.go index 2a08db3b..3e58ffb1 100644 --- a/home/dns.go +++ b/home/dns.go @@ -60,6 +60,18 @@ func initDNSServer() { config.dnsctx.rdns = InitRDNS(&config.clients) config.dnsctx.whois = initWhois(&config.clients) + + topClients := config.stats.GetTopData(30) + for _, ip := range topClients { + ipAddr := net.ParseIP(ip) + if !ipAddr.IsLoopback() { + config.dnsctx.rdns.Begin(ip) + } + if isPublicIP(ipAddr) { + config.dnsctx.whois.Begin(ip) + } + } + initFiltering() }