Пример #1
0
 /// <summary>
 /// Starts negotiating asynchronously with a SOCKS proxy server.
 /// </summary>
 /// <param name="host">The remote server to connect to.</param>
 /// <param name="port">The remote port to connect to.</param>
 /// <param name="callback">The method to call when the connection has been established.</param>
 /// <param name="proxyEndPoint">The IPEndPoint of the SOCKS proxy server.</param>
 /// <returns>An IAsyncProxyResult that references the asynchronous connection.</returns>
 public override IAsyncProxyResult BeginNegotiate(string host, int port, HandShakeComplete callback, IPEndPoint proxyEndPoint)
 {
     ProtocolComplete = callback;
     Buffer           = GetHostPortBytes(host, port);
     Server.BeginConnect(proxyEndPoint, new AsyncCallback(this.OnConnect), Server);
     AsyncResult = new IAsyncProxyResult();
     return(AsyncResult);
 }
Пример #2
0
 /// <summary>
 /// Starts negotiating asynchronously with a SOCKS proxy server.
 /// </summary>
 /// <param name="remoteEP">An IPEndPoint that represents the remote device.</param>
 /// <param name="callback">The method to call when the connection has been established.</param>
 /// <param name="proxyEndPoint">The IPEndPoint of the SOCKS proxy server.</param>
 /// <returns>An IAsyncProxyResult that references the asynchronous connection.</returns>
 public override IAsyncProxyResult BeginNegotiate(IPEndPoint remoteEP, HandShakeComplete callback, IPEndPoint proxyEndPoint)
 {
     ProtocolComplete = callback;
     Buffer           = GetEndPointBytes(remoteEP);
     Server.BeginConnect(proxyEndPoint, new AsyncCallback(this.OnConnect), Server);
     AsyncResult = new IAsyncProxyResult();
     return(AsyncResult);
 }
Пример #3
0
 /// <summary>
 /// Starts negotiating asynchronously with a SOCKS proxy server.
 /// </summary>
 /// <param name="host">The remote server to connect to.</param>
 /// <param name="port">The remote port to connect to.</param>
 /// <param name="callback">The method to call when the connection has been established.</param>
 /// <param name="proxyEndPoint">The IPEndPoint of the SOCKS proxy server.</param>
 /// <returns>An IAsyncProxyResult that references the asynchronous connection.</returns>
 public override IAsyncProxyResult BeginNegotiate(string host, int port, HandShakeComplete callback, IPEndPoint proxyEndPoint)
 {
     ProtocolComplete = callback;
     Buffer = GetHostPortBytes(host, port);
     Server.BeginConnect(proxyEndPoint, new AsyncCallback(this.OnConnect), Server);
     AsyncResult = new IAsyncProxyResult();
     return AsyncResult;
 }
Пример #4
0
 public override IAsyncProxyResult BeginNegotiate(string host, int port, HandShakeComplete callback, IPEndPoint proxyEndPoint)
 {
     // ProtocolComplete = callback;
     // Buffer = GetHostPortBytes(host, port);
     Server.BeginConnect(proxyEndPoint, delegate(IAsyncResult ar)
     {
         this.OnConnect(ar, callback, host, port);
     }, Server);
     IAsyncProxyResult AsyncResult = new IAsyncProxyResult();
     return AsyncResult;
 }
Пример #5
0
        public override IAsyncProxyResult BeginNegotiate(string host, int port, HandShakeComplete callback, IPEndPoint proxyEndPoint)
        {
            // ProtocolComplete = callback;
            // Buffer = GetHostPortBytes(host, port);
            Server.BeginConnect(proxyEndPoint, delegate(IAsyncResult ar)
            {
                this.OnConnect(ar, callback, host, port);
            }, Server);
            IAsyncProxyResult AsyncResult = new IAsyncProxyResult();

            return(AsyncResult);
        }
Пример #6
0
 private void method_6(IAsyncProxyResult value)
 {
     zoSqudwCqh = value;
 }
Пример #7
0
 /// <summary>
 /// Starts negotiating asynchronously with a SOCKS proxy server.
 /// </summary>
 /// <param name="remoteEP">An IPEndPoint that represents the remote device.</param>
 /// <param name="callback">The method to call when the connection has been established.</param>
 /// <param name="proxyEndPoint">The IPEndPoint of the SOCKS proxy server.</param>
 /// <returns>An IAsyncProxyResult that references the asynchronous connection.</returns>
 public override IAsyncProxyResult BeginNegotiate(IPEndPoint remoteEP, HandShakeComplete callback, IPEndPoint proxyEndPoint)
 {
     ProtocolComplete = callback;
     Buffer = GetEndPointBytes(remoteEP);
     Server.BeginConnect(proxyEndPoint, new AsyncCallback(this.OnConnect), Server);
     AsyncResult = new IAsyncProxyResult();
     return AsyncResult;
 }