Package com.jcraft.jsch
Class ProxySOCKS5
- java.lang.Object
-
- com.jcraft.jsch.ProxySOCKS5
-
-
Field Summary
Fields Modifier and Type Field Description private static intDEFAULTPORTprivate java.io.InputStreaminprivate java.io.OutputStreamoutprivate java.lang.Stringpasswdprivate java.lang.Stringproxy_hostprivate intproxy_portprivate java.net.Socketsocketprivate java.lang.Stringuser
-
Constructor Summary
Constructors Constructor Description ProxySOCKS5(java.lang.String proxy_host)ProxySOCKS5(java.lang.String proxy_host, int proxy_port)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()voidconnect(SocketFactory socket_factory, java.lang.String host, int port, int timeout)private voidfill(java.io.InputStream in, byte[] buf, int len)static intgetDefaultPort()java.io.InputStreamgetInputStream()java.io.OutputStreamgetOutputStream()java.net.SocketgetSocket()voidsetUserPasswd(java.lang.String user, java.lang.String passwd)
-
-
-
Field Detail
-
DEFAULTPORT
private static int DEFAULTPORT
-
proxy_host
private java.lang.String proxy_host
-
proxy_port
private int proxy_port
-
in
private java.io.InputStream in
-
out
private java.io.OutputStream out
-
socket
private java.net.Socket socket
-
user
private java.lang.String user
-
passwd
private java.lang.String passwd
-
-
Method Detail
-
setUserPasswd
public void setUserPasswd(java.lang.String user, java.lang.String passwd)
-
connect
public void connect(SocketFactory socket_factory, java.lang.String host, int port, int timeout) throws JSchException
- Specified by:
connectin interfaceProxy- Throws:
JSchException
-
getInputStream
public java.io.InputStream getInputStream()
- Specified by:
getInputStreamin interfaceProxy
-
getOutputStream
public java.io.OutputStream getOutputStream()
- Specified by:
getOutputStreamin interfaceProxy
-
getDefaultPort
public static int getDefaultPort()
-
fill
private void fill(java.io.InputStream in, byte[] buf, int len) throws JSchException, java.io.IOException- Throws:
JSchExceptionjava.io.IOException
-
-