Package org.metricshub.http
Class ProtocolOverridingSSLSocketFactory
java.lang.Object
javax.net.SocketFactory
javax.net.ssl.SSLSocketFactory
org.metricshub.http.ProtocolOverridingSSLSocketFactory
A
SSLSocketFactory which uses an existing SSLSocketFactory to delegate its operations to and overrides the
enabled protocols to the protocols that were passed to its
constructor-
Constructor Summary
ConstructorsConstructorDescriptionProtocolOverridingSSLSocketFactory(SSLSocketFactory delegate, String[] enabledProtocols) Constructs aProtocolOverridingSSLSocketFactorywith the given delegateSSLSocketFactoryand array of enabled protocols. -
Method Summary
Modifier and TypeMethodDescriptioncreateSocket(String host, int port) createSocket(String host, int port, InetAddress localAddress, int localPort) createSocket(InetAddress host, int port) createSocket(InetAddress host, int port, InetAddress localAddress, int localPort) createSocket(Socket socket, String host, int port, boolean autoClose) String[]String[]Methods inherited from class javax.net.ssl.SSLSocketFactory
createSocket, getDefaultMethods inherited from class javax.net.SocketFactory
createSocket
-
Constructor Details
-
ProtocolOverridingSSLSocketFactory
Constructs aProtocolOverridingSSLSocketFactorywith the given delegateSSLSocketFactoryand array of enabled protocols.- Parameters:
delegate- The underlyingSSLSocketFactoryto delegate operations to.enabledProtocols- The array of protocols to be set as enabled protocols.
-
-
Method Details
-
getDefaultCipherSuites
- Specified by:
getDefaultCipherSuitesin classSSLSocketFactory
-
getSupportedCipherSuites
- Specified by:
getSupportedCipherSuitesin classSSLSocketFactory
-
createSocket
public Socket createSocket(Socket socket, String host, int port, boolean autoClose) throws IOException - Specified by:
createSocketin classSSLSocketFactory- Throws:
IOException
-
createSocket
- Specified by:
createSocketin classSocketFactory- Throws:
IOException
-
createSocket
public Socket createSocket(String host, int port, InetAddress localAddress, int localPort) throws IOException - Specified by:
createSocketin classSocketFactory- Throws:
IOException
-
createSocket
- Specified by:
createSocketin classSocketFactory- Throws:
IOException
-
createSocket
public Socket createSocket(InetAddress host, int port, InetAddress localAddress, int localPort) throws IOException - Specified by:
createSocketin classSocketFactory- Throws:
IOException
-