equal
deleted
inserted
replaced
297 print("Done.\n"); |
297 print("Done.\n"); |
298 end |
298 end |
299 if not what or what == "dns" then |
299 if not what or what == "dns" then |
300 local dns = require "net.dns"; |
300 local dns = require "net.dns"; |
301 pcall(function () |
301 pcall(function () |
|
302 local unbound = require"net.unbound"; |
302 local unbound_config = configmanager.get("*", "unbound") or {}; |
303 local unbound_config = configmanager.get("*", "unbound") or {}; |
303 unbound_config.hoststxt = false; -- don't look at /etc/hosts |
304 unbound_config.hoststxt = false; -- don't look at /etc/hosts |
304 configmanager.set("*", "unbound", unbound_config); |
305 configmanager.set("*", "unbound", unbound_config); |
305 dns = require"net.unbound".dns; |
306 unbound.purge(); -- ensure the above config is used |
|
307 dns = unbound.dns; |
306 end) |
308 end) |
307 local idna = require "util.encodings".idna; |
309 local idna = require "util.encodings".idna; |
308 local ip = require "util.ip"; |
310 local ip = require "util.ip"; |
309 local c2s_ports = set.new(configmanager.get("*", "c2s_ports") or {5222}); |
311 local c2s_ports = set.new(configmanager.get("*", "c2s_ports") or {5222}); |
310 local s2s_ports = set.new(configmanager.get("*", "s2s_ports") or {5269}); |
312 local s2s_ports = set.new(configmanager.get("*", "s2s_ports") or {5269}); |