// Path: src/com/lixia/rdp/crypto/CryptoException.java
// public class CryptoException
// extends Exception
// {
//     public CryptoException() { super(); }
//     /** @param reason  the reason why the exception was thrown. */
//     public CryptoException(String reason) { super(reason); }       
// }


import java.io.*;
import java.net.*;
import com.lixia.rdp.crypto.CryptoException;
import com.lixia.uag.websocket.LocalHttpTunnel;
import org.apache.log4j.Logger;

			LocalHttpTunnel tunnel = new LocalHttpTunnel(Options.http_server, 
					new InetSocketAddress(host,port),
					Options.username,
					Options.password,
					Options.command);
			SocketAddress endpoint = tunnel.createTunnel();
			if(endpoint != null){
				this.rdpsock = new Socket();
				rdpsock.connect(endpoint,timeout_ms);
			}
			else{
				throw new IOException("failed to create tunnel!");
			}
		}
		else{
			rdpsock = new Socket();
			rdpsock.connect(new InetSocketAddress(host,port),timeout_ms);
		}
	}

	/**
	 * Connect to a server
	 * @param host Address of server
	 * @param port Port to connect to on server
	 * @throws IOException
	 * @throws RdesktopException
	 * @throws OrderException
	 * @throws CryptoException
	 */
	public void connect(InetAddress host, int port) throws IOException,

// Path: src/com/lixia/rdp/crypto/CryptoException.java
// public class CryptoException
// extends Exception
// {
//     public CryptoException() { super(); }
//     /** @param reason  the reason why the exception was thrown. */
//     public CryptoException(String reason) { super(reason); }       
// }


// Path: src/com/lixia/rdp/ISO.java
import java.io.*;
import java.net.*;
import com.lixia.rdp.crypto.CryptoException;
import com.lixia.uag.websocket.LocalHttpTunnel;
import org.apache.log4j.Logger;

			LocalHttpTunnel tunnel = new LocalHttpTunnel(Options.http_server, 
					new InetSocketAddress(host,port),
					Options.username,
					Options.password,
					Options.command);
			SocketAddress endpoint = tunnel.createTunnel();
			if(endpoint != null){
				this.rdpsock = new Socket();
				rdpsock.connect(endpoint,timeout_ms);
			}
			else{
				throw new IOException("failed to create tunnel!");
			}
		}
		else{
			rdpsock = new Socket();
			rdpsock.connect(new InetSocketAddress(host,port),timeout_ms);
		}
	}

	/**
	 * Connect to a server
	 * @param host Address of server
	 * @param port Port to connect to on server
	 * @throws IOException
	 * @throws RdesktopException
	 * @throws OrderException
	 * @throws CryptoException
	 */
	public void connect(InetAddress host, int port) throws IOException,

			RdesktopException, OrderException, CryptoException {
