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());
        }
示例#2
0
 public void Add(TunnelDemultiplexer service)
 {
     AddListener(service);
 }