public DnsServer(Configer config) { this.emitter = new EventEmitter(); this.globalClient = new DnsClient(new IPEndPoint(IPAddress.Parse(config.GlobalDnsServer), 53), new UdpRequestResolver()); this.ispClient = new DnsClient(new IPEndPoint(IPAddress.Parse(config.IspDnsServer), 53), new UdpRequestResolver()); this.masterFile = new MasterFile(); }
public DnsServer(IPEndPoint endServer) { if (endServer != null && endServer.Address.ToString() != "0.0.0.0") { this.client = new DnsClient(endServer, new UdpRequestResolver()); } this.masterFile = new MasterFile(); }
public DnsServer(IPEndPoint endServer) { this.emitter = new EventEmitter(); this.client = new DnsClient(endServer, new UdpRequestResolver()); this.masterFile = new MasterFile(); }
public DnsServer(MasterFile masterFile, string endServer, int port = DEFAULT_PORT) : this(masterFile, IPAddress.Parse(endServer), port) { }
public DnsServer(MasterFile masterFile, IPAddress endServer, int port = DEFAULT_PORT) : this(masterFile, new IPEndPoint(endServer, port)) { }
public DnsServer(MasterFile masterFile, IPEndPoint endServer) : this(new FallbackRequestResolver(masterFile, new UdpRequestResolver(endServer))) { }