Exemplo n.º 1
0
		private IDisposable MakeDemux(TunnelDemultiplexer config)
		{
			TcpDemultiplexer demux = new TcpDemultiplexer(
				MakeListener(config.IpEndpoint, config.Port, config)
				);
			foreach(TunnelSenderFromPort target in config.Targets)
                demux.Add(target.OriginalPort, MakeSender(target));
            demux.SetLogDirectory(config.MonitoringDirectory);
			return demux.Start();
		}
        private IDisposable MakeDemux(TunnelDemultiplexer config)
        {
            TcpDemultiplexer demux = new TcpDemultiplexer(
                MakeListener(config.IpEndpoint, config.Port, config)
                );

            foreach (TunnelSenderFromPort target in config.Targets)
            {
                demux.Add(target.OriginalPort, MakeSender(target));
            }
            demux.SetLogDirectory(config.MonitoringDirectory);
            return(demux.Start());
        }