Class SslConfigurationBuilder
java.lang.Object
org.infinispan.client.hotrod.configuration.AbstractConfigurationChildBuilder
org.infinispan.client.hotrod.configuration.AbstractSecurityConfigurationChildBuilder
org.infinispan.client.hotrod.configuration.SslConfigurationBuilder
- All Implemented Interfaces:
ConfigurationChildBuilder
,Builder<SslConfiguration>
public class SslConfigurationBuilder
extends AbstractSecurityConfigurationChildBuilder
implements Builder<SslConfiguration>
SSLConfigurationBuilder.
- Since:
- 5.3
- Author:
- Tristan Tarrant
-
Constructor Summary
ModifierConstructorDescriptionprotected
-
Method Summary
Modifier and TypeMethodDescriptionConfigures the ciphers Setting this property also implicitly enables SSL/TLS (seeenable()
create()
Create the configuration beandisable()
Disables the SSL supportenable()
Enables the SSL supportenabled
(boolean enabled) Enables or disables the SSL supporthostnameValidation
(boolean hostnameValidation) Configures whether to enable hostname validation according to RFC 2818.Sets the alias of the key to use, in case the keyStore contains multiple certificates.keyStoreCertificatePassword
(char[] keyStoreCertificatePassword) Deprecated, for removal: This API element is subject to removal in a future version.since 9.3keyStoreFileName
(String keyStoreFileName) Specifies the filename of a keystore to use to create theSSLContext
You also need to specify akeyStorePassword(char[])
.keyStorePassword
(char[] keyStorePassword) Specifies the password needed to open the keystore You also need to specify akeyStoreFileName(String)
.keyStoreType
(String keyStoreType) Specifies the type of the keystore, such as JKS or JCEKS.Configures the secure socket protocol.Configures the SSL provider.read
(SslConfiguration template, Combine combine) Reads the configuration from an already created configuration bean into this builder.sniHostName
(String sniHostName) Specifies the TLS SNI hostname for the connectionsslContext
(SSLContext sslContext) Specifies a pre-builtSSLContext
trustStoreFileName
(String trustStoreFileName) Specifies the filename of a truststore to use to create theSSLContext
You also need to specify atrustStorePassword(char[])
.trustStorePassword
(char[] trustStorePassword) Specifies the password needed to open the truststore You also need to specify atrustStoreFileName(String)
.trustStorePath
(String trustStorePath) Deprecated, for removal: This API element is subject to removal in a future version.since 12.0 to be removed in 15.0.trustStoreType
(String trustStoreType) Specifies the type of the truststore, such as JKS or JCEKS.void
validate()
Validate the data in this builder before building the configuration beanwithProperties
(Properties properties) Configures this builder using the specified properties.Methods inherited from class org.infinispan.client.hotrod.configuration.AbstractSecurityConfigurationChildBuilder
authentication, ssl
Methods inherited from class org.infinispan.client.hotrod.configuration.AbstractConfigurationChildBuilder
addCluster, addContextInitializer, addContextInitializer, addContextInitializers, addJavaSerialAllowList, addJavaSerialWhiteList, addServer, addServers, asyncExecutorFactory, balancingStrategy, balancingStrategy, balancingStrategy, batchSize, build, classLoader, clientIntelligence, connectionPool, connectionTimeout, consistentHashImpl, consistentHashImpl, dnsResolverMaxTTL, dnsResolverMinTTL, dnsResolverNegativeTTL, forceReturnValues, keySizeEstimate, marshaller, marshaller, marshaller, maxRetries, protocolVersion, remoteCache, security, socketTimeout, statistics, tcpKeepAlive, tcpNoDelay, transaction, transactionTimeout, transportFactory, uri, uri, valueSizeEstimate, version
-
Constructor Details
-
SslConfigurationBuilder
-
-
Method Details
-
attributes
- Specified by:
attributes
in interfaceBuilder<SslConfiguration>
-
disable
Disables the SSL support -
enable
Enables the SSL support -
enabled
Enables or disables the SSL support -
keyStoreFileName
Specifies the filename of a keystore to use to create theSSLContext
You also need to specify akeyStorePassword(char[])
. Alternatively specify an initializedsslContext(SSLContext)
. Setting this property also implicitly enables SSL/TLS (seeenable()
-
keyStoreType
Specifies the type of the keystore, such as JKS or JCEKS. Defaults to JKS. Setting this property also implicitly enables SSL/TLS (seeenable()
-
keyStorePassword
Specifies the password needed to open the keystore You also need to specify akeyStoreFileName(String)
. Alternatively specify an initializedsslContext(SSLContext)
. Setting this property also implicitly enables SSL/TLS (seeenable()
-
keyStoreCertificatePassword
@Deprecated(forRemoval=true) public SslConfigurationBuilder keyStoreCertificatePassword(char[] keyStoreCertificatePassword) Deprecated, for removal: This API element is subject to removal in a future version.since 9.3Specifies the password needed to access private key associated with certificate stored in specifiedkeyStoreFileName(String)
. If password is not specified, password provided inkeyStorePassword(char[])
will be used. Setting this property also implicitly enables SSL/TLS (seeenable()
Note: this only works with some keystore types -
keyAlias
Sets the alias of the key to use, in case the keyStore contains multiple certificates. Setting this property also implicitly enables SSL/TLS (seeenable()
-
sslContext
Specifies a pre-builtSSLContext
-
trustStoreFileName
Specifies the filename of a truststore to use to create theSSLContext
You also need to specify atrustStorePassword(char[])
. Alternatively specify an initializedsslContext(SSLContext)
. Setting this property also implicitly enables SSL/TLS (seeenable()
-
trustStorePath
Deprecated, for removal: This API element is subject to removal in a future version.since 12.0 to be removed in 15.0. UsetrustStoreFileName(String)
and pass pem totrustStoreType(String)
. -
trustStoreType
Specifies the type of the truststore, such as JKS or JCEKS. Defaults to JKS. Setting this property also implicitly enables SSL/TLS (seeenable()
-
trustStorePassword
Specifies the password needed to open the truststore You also need to specify atrustStoreFileName(String)
. Alternatively specify an initializedsslContext(SSLContext)
. Setting this property also implicitly enables SSL/TLS (seeenable()
-
sniHostName
Specifies the TLS SNI hostname for the connection -
provider
Configures the SSL provider. Setting this property also implicitly enables SSL/TLS (seeenable()
- Parameters:
provider
- The name of the provider to use when obtaining an SSLContext.- See Also:
-
protocol
Configures the secure socket protocol. Setting this property also implicitly enables SSL/TLS (seeenable()
- Parameters:
protocol
- The standard name of the requested protocol, e.g TLSv1.2- See Also:
-
ciphers
Configures the ciphers Setting this property also implicitly enables SSL/TLS (seeenable()
- Parameters:
ciphers
- one or more cipher names- See Also:
-
hostnameValidation
Configures whether to enable hostname validation according to RFC 2818. This is enabled by default and requires that the server certificate includes a subjectAltName extension of type dNSName or iPAddress.- Parameters:
hostnameValidation
- whether to enable hostname validation
-
validate
public void validate()Description copied from interface:Builder
Validate the data in this builder before building the configuration bean- Specified by:
validate
in interfaceBuilder<SslConfiguration>
-
create
Description copied from interface:Builder
Create the configuration bean- Specified by:
create
in interfaceBuilder<SslConfiguration>
- Returns:
-
read
Description copied from interface:Builder
Reads the configuration from an already created configuration bean into this builder. Returns an appropriate builder to allow fluent configuration- Specified by:
read
in interfaceBuilder<SslConfiguration>
- Parameters:
template
- the configuration from which to "clone" this config if needed.combine
- the way attributes and children of this instance and the template should be combined.
-
withProperties
Description copied from interface:ConfigurationChildBuilder
Configures this builder using the specified properties. SeeConfigurationBuilder
for a list.- Specified by:
withProperties
in interfaceConfigurationChildBuilder
- Overrides:
withProperties
in classAbstractConfigurationChildBuilder
-