Class DefaultTcpSSLContextSupport
java.lang.Object
org.springframework.integration.ip.tcp.connection.DefaultTcpSSLContextSupport
- All Implemented Interfaces:
TcpSSLContextSupport
Default implementation of
TcpSSLContextSupport
; uses a
'TLS' (by default) SSLContext
, initialized with 'JKS'
keystores, managed by 'SunX509' Key and Trust managers.- Since:
- 2.1
- Author:
- Gary Russell
-
Constructor Summary
ConstructorDescriptionDefaultTcpSSLContextSupport
(String keyStore, String trustStore, String keyStorePassword, String trustStorePassword) Prepares for the creation of an SSLContext using the supplied key/trust stores and passwords. -
Method Summary
Modifier and TypeMethodDescriptionGets an SSLContext.void
setKeyStoreType
(String keyStoreType) Set the key store type.void
setProtocol
(String protocol) The protocol used inSSLContext.getInstance(String)
; default "TLS".void
setTrustStoreType
(String trustStoreType) Set the trust store type.
-
Constructor Details
-
Method Details
-
setKeyStoreType
Set the key store type. Default JKS.- Parameters:
keyStoreType
- the type.- Since:
- 5.0.8
-
setTrustStoreType
Set the trust store type. Default JKS.- Parameters:
trustStoreType
- the type.- Since:
- 5.0.8
-
getSSLContext
Description copied from interface:TcpSSLContextSupport
Gets an SSLContext.- Specified by:
getSSLContext
in interfaceTcpSSLContextSupport
- Returns:
- the SSLContext.
- Throws:
GeneralSecurityException
- Any GeneralSecurityException.IOException
- Any IOException.
-
setProtocol
The protocol used inSSLContext.getInstance(String)
; default "TLS".- Parameters:
protocol
- The protocol.
-