nu.najt.kecon.jsocksproxy.socks4
Class SocksImplementation4

java.lang.Object
  extended by nu.najt.kecon.jsocksproxy.AbstractSocksImplementation
      extended by nu.najt.kecon.jsocksproxy.socks4.SocksImplementation4
All Implemented Interfaces:
SocksImplementation

public class SocksImplementation4
extends AbstractSocksImplementation

This is the SOCKS4 implementation.

More about the SOCKS protocol http://en.wikipedia.org/wiki/SOCKS

Author:
Kenny Colliander Nordin

Field Summary
protected static byte AUTHORIZATION_FAILED
           
protected static byte COMMAND_BIND
           
protected static byte COMMAND_CONNECT
           
protected static byte REQUEST_GRANTED
           
protected static byte REQUEST_REJECTED
           
 
Fields inherited from class nu.najt.kecon.jsocksproxy.AbstractSocksImplementation
logger
 
Constructor Summary
SocksImplementation4(JSocksProxy jSocksProxy, java.net.Socket socket)
          Constructor
 
Method Summary
 void handle()
          This method is the method which handle the handshake (except for the first version check) and tunneling.
 
Methods inherited from class nu.najt.kecon.jsocksproxy.AbstractSocksImplementation
getSocket, getStatus, openConnection, setStatus, tunnel
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

COMMAND_CONNECT

protected static final byte COMMAND_CONNECT
See Also:
Constant Field Values

COMMAND_BIND

protected static final byte COMMAND_BIND
See Also:
Constant Field Values

REQUEST_GRANTED

protected static final byte REQUEST_GRANTED
See Also:
Constant Field Values

REQUEST_REJECTED

protected static final byte REQUEST_REJECTED
See Also:
Constant Field Values

AUTHORIZATION_FAILED

protected static final byte AUTHORIZATION_FAILED
See Also:
Constant Field Values
Constructor Detail

SocksImplementation4

public SocksImplementation4(JSocksProxy jSocksProxy,
                            java.net.Socket socket)
Constructor

Parameters:
jSocksProxy - the parent instance
socket - the socket
Method Detail

handle

public void handle()
Description copied from interface: SocksImplementation
This method is the method which handle the handshake (except for the first version check) and tunneling.