Helper class for SOCKS5 proxying.
Socks5Proxy
| Modifier and Type | Class and Description |
|---|---|
| public static interface | Socks5.Authentication
A SOCKS5 authentication method. |
| public static class | Socks5.NoAuthenticationFactory
The implementation of the |
| public static class | Socks5.UsernamePasswordAuthenticationFactory
The implementation of the |
| Modifier and Type | Field and Description |
|---|---|
| public static final byte | ADDRESS_TYPE_DOMAIN
The address type for domain names used in SOCKS5 connect requests and responses. |
| public static final byte | ADDRESS_TYPE_IPV4
The address type for IPv4 used in SOCKS5 connect requests and responses. |
| public static final byte | ADDRESS_TYPE_IPV6
The address type for IPv6 used in SOCKS5 connect requests and responses. |
| public static final byte | COMMAND_CONNECT
The SOCKS5 |
| public static final byte | RESERVED
The reserved byte value: 0. |
| public static final byte | VERSION
The SOCKS protocol version: 5. |
| Access | Constructor and Description |
|---|---|
| private |
| ADDRESS_TYPE_DOMAIN | back to summary |
|---|---|
| public static final byte ADDRESS_TYPE_DOMAIN The address type for domain names used in SOCKS5 connect requests and responses. | |
| ADDRESS_TYPE_IPV4 | back to summary |
|---|---|
| public static final byte ADDRESS_TYPE_IPV4 The address type for IPv4 used in SOCKS5 connect requests and responses. | |
| ADDRESS_TYPE_IPV6 | back to summary |
|---|---|
| public static final byte ADDRESS_TYPE_IPV6 The address type for IPv6 used in SOCKS5 connect requests and responses. | |
| COMMAND_CONNECT | back to summary |
|---|---|
| public static final byte COMMAND_CONNECT The SOCKS5 | |
| RESERVED | back to summary |
|---|---|
| public static final byte RESERVED The reserved byte value: 0. | |
| VERSION | back to summary |
|---|---|
| public static final byte VERSION The SOCKS protocol version: 5. | |
| Socks5 | back to summary |
|---|---|
| private Socks5() | |
A SOCKS5 authentication method.
Implementations should send and receive the bytes that are specific to the particular authentication method.
| Modifier and Type | Class and Description |
|---|---|
| public static interface | Socks5.Authentication.Factory
A factory for |
| Modifier and Type | Method and Description |
|---|---|
| public void | authenticate(EndPoint
the endPoint, Callback EndPoint to send to and receive from the SOCKS5 serverthe callback to complete when the authentication is complete callback)Performs the authentication send and receive bytes
exchanges specific for this |
| authenticate | back to summary |
|---|---|
| public void authenticate(EndPoint endPoint, Callback callback) Performs the authentication send and receive bytes
exchanges specific for this | |
Authentications.
| Modifier and Type | Method and Description |
|---|---|
| public byte | |
| public Socks5. |
| getMethod | back to summary |
|---|---|
public byte getMethod()
| |
| newAuthentication | back to summary |
|---|---|
public Socks5.
| |
The implementation of the NO AUTH authentication method defined in
RFC 1928.
| Modifier and Type | Field and Description |
|---|---|
| public static final byte |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public byte | |
| public Socks5. |
| METHOD | back to summary |
|---|---|
| public static final byte METHOD | |
| NoAuthenticationFactory | back to summary |
|---|---|
| public NoAuthenticationFactory() | |
| getMethod | back to summary |
|---|---|
| public byte getMethod() Implements org.
| |
| newAuthentication | back to summary |
|---|---|
| public Socks5. Implements org.
| |
The implementation of the USERNAME/PASSWORD authentication method defined in
RFC 1929.
| Modifier and Type | Class and Description |
|---|---|
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private final Charset | |
| private static final Logger | |
| public static final byte | |
| private final String | |
| private final String | |
| public static final byte |
| Access | Constructor and Description |
|---|---|
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public byte | |
| public Socks5. |
| charset | back to summary |
|---|---|
| private final Charset charset | |
| LOG | back to summary |
|---|---|
| private static final Logger LOG | |
| METHOD | back to summary |
|---|---|
| public static final byte METHOD | |
| password | back to summary |
|---|---|
| private final String password | |
| userName | back to summary |
|---|---|
| private final String userName | |
| VERSION | back to summary |
|---|---|
| public static final byte VERSION | |
| UsernamePasswordAuthenticationFactory | back to summary |
|---|---|
| public UsernamePasswordAuthenticationFactory(String userName, String password) | |
| UsernamePasswordAuthenticationFactory | back to summary |
|---|---|
| public UsernamePasswordAuthenticationFactory(String userName, String password, Charset charset) | |
| getMethod | back to summary |
|---|---|
| public byte getMethod() Implements org.
| |
| newAuthentication | back to summary |
|---|---|
| public Socks5. Implements org.
| |
| Modifier and Type | Field and Description |
|---|---|
| private final ByteBuffer | |
| private Callback | |
| private EndPoint | |
| private final Socks5. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public void | authenticate(EndPoint
the endPoint, Callback EndPoint to send to and receive from the SOCKS5 serverthe callback to complete when the authentication is complete callback)Implements org. Performs the authentication send and receive bytes
exchanges specific for this |
| private void | |
| public void | failed(Throwable
the reason for the operation failure x)Overrides default org. Callback invoked when the operation fails. |
| public Invocable. | |
| public void | succeeded()
Overrides default org. Callback invoked when the operation completes. |
| byteBuffer | back to summary |
|---|---|
| private final ByteBuffer byteBuffer | |
| callback | back to summary |
|---|---|
| private Callback callback | |
| endPoint | back to summary |
|---|---|
| private EndPoint endPoint | |
| factory | back to summary |
|---|---|
| private final Socks5. | |
| UsernamePasswordAuthentication | back to summary |
|---|---|
| private UsernamePasswordAuthentication(Socks5. | |
| authenticate | back to summary |
|---|---|
| public void authenticate(EndPoint endPoint, Callback callback) Implements org. Doc from org. Performs the authentication send and receive bytes
exchanges specific for this | |
| authenticationSent | back to summary |
|---|---|
| private void authenticationSent() | |
| failed | back to summary |
|---|---|
| public void failed(Throwable x) Overrides default org. Doc from org. Callback invoked when the operation fails. | |
| getInvocationType | back to summary |
|---|---|
| public Invocable. Overrides default org.
| |
| succeeded | back to summary |
|---|---|
| public void succeeded() Overrides default org. Doc from org. Callback invoked when the operation completes.
| |