Advtools.AdvInterceptor.AdvDnsServer.Start C# (CSharp) Method

Start() public method

public Start ( ) : void
return void
        public void Start()
        {
            GetProcessors();

            server_ = new DnsServer(IPAddress.Any, state_.Config.Dns.UdpListeners, state_.Config.Dns.TcpListeners, ProcessDnsQuery);
            server_.Start();
        }

Usage Example

Example #1
0
        private static void StartServers(Options options)
        {
            Configuration config = null;

            if (options.DefaultConfig)
            {
                config = Configuration.Default;
                config.Save(options.ConfigFile);
            }
            else
            {
                config = Configuration.Load(options.ConfigFile);
            }

            State state = new State(config, options.Level);

            AdvDnsServer dns = new AdvDnsServer(state, options.Intercept);

            dns.Start();

            if (options.Intercept)
            {
                AdvWebServer web = new AdvWebServer(state);
                web.Start();
            }
        }
All Usage Examples Of Advtools.AdvInterceptor.AdvDnsServer::Start