public class I2PTunnelConnectClient extends I2PTunnelHTTPClientBase implements Runnable
Supports various host formats (example.i2p, .b32.i2p, base64, external domains) and CONNECT syntax variations. Protocol ignored for I2P destinations.
Additional lines after CONNECT are stripped. CONNECT line removed for .i2p accesses, passed through for outproxy accesses.
Reference: RFC draft-luotonen-ssl-tunneling-03.txt (1997) "Tunneling SSL Through a WWW Proxy"
I2PTunnelHTTPClientBase.AuthResult, I2PTunnelHTTPClientBase.OnProxySuccess, I2PTunnelHTTPClientBase.OnTimeout| Modifier and Type | Field and Description |
|---|---|
static String | AUTH_REALMHTTP authentication realm for SSL CONNECT proxy. |
__requestId, _proxyList, BASIC_AUTH, BROWSER_READ_TIMEOUT, DEFAULT_READ_TIMEOUT, DIGEST_AUTH, ERR_DESTINATION_UNKNOWN, ERR_NO_OUTPROXY, INITIAL_SO_TIMEOUT, PROP_AUTH, PROP_OUTPROXY_AUTH, PROP_OUTPROXY_PW, PROP_OUTPROXY_PW_PREFIX, PROP_OUTPROXY_USER, PROP_OUTPROXY_USER_PREFIX, PROP_PROXY_DIGEST_PREFIX, PROP_PROXY_DIGEST_SHA256_SUFFIX, PROP_PROXY_DIGEST_SUFFIX, PROP_PW, PROP_PW_PREFIX, PROP_SSL_OUTPROXIES, PROP_USE_OUTPROXY_PLUGIN, PROP_USER, SUCCESS_RESPONSE_clientId, _context, _executor, _log, _ownDest, DEFAULT_CONNECT_TIMEOUT, dest, l, listenerReady, mySockets, PROP_USE_SSL, sockLock, sockMgr, ssopen, tunnel| Constructor and Description |
|---|
I2PTunnelConnectClient(int localPort,
Logging l,
boolean ownDest,
String wwwProxy,
EventDispatcher notifyThis,
I2PTunnel tunnel)As of 0.9.20 this is fast, and does NOT connect the manager to the router,
or open the local socket. |
| Modifier and Type | Method and Description |
|---|---|
protected void | clientConnectionRun(Socket s)Handle an incoming CONNECT proxy connection. |
boolean | close(boolean forced)Closes the CONNECT proxy and unregisters from port mapper. |
protected I2PSocketOptions | getDefaultOptions()Create the default options (using the default timeout, etc). |
protected String | getRealm()Get the authentication realm string. |
void | startRunning()Starts the CONNECT proxy and registers with port mapper. |
_t, _t, _t, authorize, decodeIDNHost, getAuthError, getErrorPage, getErrorPage, getPrefix, handleClientException, handleI2PSocketException, isDigestAuthRequired, noteProxyResult, optionsUpdated, selectProxy, selectSSLProxy, writeErrorMessage, writeErrorMessage, writeErrorMessage, writeErrorMessage, writeFooter, writeFooterbuildSocketManager, buildSocketManager, buildSocketManager, buildSocketManager, closeSocket, createI2PSocket, createI2PSocket, createI2PSocket, destroy, getDefaultOptions, getListenHost, getLocalPort, getSocketManager, getSocketManager, getSocketManager, killSharedClient, manageConnection, run, verifySocketManagerconnected, disconnected, errorOccurred, getBooleanOption, getId, getTunnel, isOpen, reportAbuse, routerDisconnected, setId, setName, setTunnel, toStringattachEventDispatcher, detachEventDispatcher, getEventDispatcher, getEvents, getEventValue, ignoreEvents, notifyEvent, unIgnoreEvents, waitEventValuepublic static final String AUTH_REALM
public I2PTunnelConnectClient(int localPort,
Logging l,
boolean ownDest,
String wwwProxy,
EventDispatcher notifyThis,
I2PTunnel tunnel)
throws IllegalArgumentExceptionIllegalArgumentException - if the I2PTunnel does not contain
valid config to contact the routerprotected void clientConnectionRun(Socket s)
clientConnectionRun in class I2PTunnelClientBases - the local client socket connectionpublic boolean close(boolean forced)
close in class I2PTunnelClientBaseprotected I2PSocketOptions getDefaultOptions()
getDefaultOptions in class I2PTunnelClientBaseprotected String getRealm()
I2PTunnelHTTPClientBasegetRealm in class I2PTunnelHTTPClientBasepublic void startRunning()
startRunning in class I2PTunnelClientBase