public final class SSLSocketFactoryImpl
extends javax.net.ssl.SSLSocketFactory
Constructor and Description |
---|
SSLSocketFactoryImpl()
Constructor used to instantiate the default factory.
|
Modifier and Type | Method and Description |
---|---|
java.net.Socket |
createSocket()
Creates an unconnected socket.
|
java.net.Socket |
createSocket(java.net.InetAddress address,
int port)
Constructs an SSL connection to a server at a specified address
and TCP port.
|
java.net.Socket |
createSocket(java.net.InetAddress address,
int port,
java.net.InetAddress clientAddress,
int clientPort)
Constructs an SSL connection to a server at a specified address
and TCP port.
|
java.net.Socket |
createSocket(java.net.Socket s,
java.io.InputStream consumed,
boolean autoClose) |
java.net.Socket |
createSocket(java.net.Socket s,
java.lang.String host,
int port,
boolean autoClose)
Returns a socket layered over an existing socket to a
ServerSocket on the named host, at the given port.
|
java.net.Socket |
createSocket(java.lang.String host,
int port)
Constructs an SSL connection to a named host at a specified port.
|
java.net.Socket |
createSocket(java.lang.String host,
int port,
java.net.InetAddress clientAddress,
int clientPort)
Constructs an SSL connection to a named host at a specified port.
|
java.lang.String[] |
getDefaultCipherSuites()
Returns the subset of the supported cipher suites which are
enabled by default.
|
java.lang.String[] |
getSupportedCipherSuites()
Returns the names of the cipher suites which could be enabled for use
on an SSL connection.
|
public SSLSocketFactoryImpl() throws java.lang.Exception
java.lang.Exception
- errorpublic java.net.Socket createSocket()
createSocket
in class javax.net.SocketFactory
Socket.connect(java.net.SocketAddress, int)
public java.net.Socket createSocket(java.lang.String host, int port) throws java.io.IOException, java.net.UnknownHostException
createSocket
in class javax.net.SocketFactory
host
- name of the host with which to connectport
- number of the server's portjava.io.IOException
java.net.UnknownHostException
public java.net.Socket createSocket(java.net.Socket s, java.lang.String host, int port, boolean autoClose) throws java.io.IOException
createSocket
in class javax.net.ssl.SSLSocketFactory
s
- the existing sockethost
- the server hostport
- the server portautoClose
- close the underlying socket when this socket is closedjava.io.IOException
- if the connection can't be establishedjava.net.UnknownHostException
- if the host is not knownpublic java.net.Socket createSocket(java.net.Socket s, java.io.InputStream consumed, boolean autoClose) throws java.io.IOException
createSocket
in class javax.net.ssl.SSLSocketFactory
java.io.IOException
public java.net.Socket createSocket(java.net.InetAddress address, int port) throws java.io.IOException
createSocket
in class javax.net.SocketFactory
address
- the server's hostport
- its portjava.io.IOException
public java.net.Socket createSocket(java.lang.String host, int port, java.net.InetAddress clientAddress, int clientPort) throws java.io.IOException
createSocket
in class javax.net.SocketFactory
java.io.IOException
public java.net.Socket createSocket(java.net.InetAddress address, int port, java.net.InetAddress clientAddress, int clientPort) throws java.io.IOException
createSocket
in class javax.net.SocketFactory
java.io.IOException
public java.lang.String[] getDefaultCipherSuites()
getDefaultCipherSuites
in class javax.net.ssl.SSLSocketFactory
public java.lang.String[] getSupportedCipherSuites()
getSupportedCipherSuites
in class javax.net.ssl.SSLSocketFactory