java.lang.Object
io.helidon.common.tls.ConfiguredTlsManager
- All Implemented Interfaces:
- NamedService,- TlsManager
The default configured 
TlsManager implementation.- 
Constructor SummaryConstructorsModifierConstructorDescriptionprotectedConfiguredTlsManager(String name, String type) Configured tls manager constructor.
- 
Method SummaryModifier and TypeMethodDescriptionprotected KeyManagerFactorybuildKmf(TlsConfig target, SecureRandom secureRandom, PrivateKey privateKey, Certificate[] certificates) Build the key manager factory.protected TrustManagerFactoryCreate a new trust manager factory based on the configuration (i.e., the algorithm and provider).voidAlways called before any other method on this type.protected voidinitializeTmf(TrustManagerFactory tmf, KeyStore keyStore, TlsConfig tlsConfig) Perform initialization of theTrustManagerFactorybased on the provided TLS configuration.protected voidinitSslContext(TlsConfig tlsConfig, SecureRandom secureRandom, KeyManager[] keyManagers, TrustManager[] trustManagers) Initialize and set theSSLContexton this manager instance.protected KeyStoreinternalKeystore(TlsConfig tlsConfig) Creates an internal keystore and loads it with no password and no data.The key manager in use.name()Name of this implementation, as provided inConfiguredProvider.create(Config, String).voidThis method will multiplex the call to allTlsReloadableComponents that are being managed by this manager.protected voidreload(Optional<X509KeyManager> keyManager, Optional<X509TrustManager> trustManager) Reload the current SSL context with the provided key manager and trust manager (if defined).protected SecureRandomsecureRandom(TlsConfig tlsConfig) Load secure random.SSL context created by this manager.protected TrustManagerFactoryCreates a trust all trust manager factory.The trust manager in use.type()Type of this implementation, to distinguish instances of same type, with differentNamedService.name().
- 
Constructor Details- 
ConfiguredTlsManagerConfigured tls manager constructor.- Parameters:
- name- the manager name
- type- the manager type
 
 
- 
- 
Method Details- 
nameDescription copied from interface:NamedServiceName of this implementation, as provided inConfiguredProvider.create(Config, String).- Specified by:
- namein interface- NamedService
- Returns:
- name of this service
 
- 
typeDescription copied from interface:NamedServiceType of this implementation, to distinguish instances of same type, with differentNamedService.name(). Use for exampleConfiguredProvider.configKey()to define the type.- Specified by:
- typein interface- NamedService
- Returns:
- type of this service
 
- 
sslContextDescription copied from interface:TlsManagerSSL context created by this manager. This method is called only afterTlsManager.init(TlsConfig)and only ifTlsConfig.enabled()istrue.- Specified by:
- sslContextin interface- TlsManager
- Returns:
- the SSL context to use
 
- 
initDescription copied from interface:TlsManagerAlways called before any other method on this type. This method is only called when TLS is enabled. In case the TLS is disabled, none of the methods on this type can be called.- Specified by:
- initin interface- TlsManager
- Parameters:
- tlsConfig- TLS configuration
 
- 
reloadDescription copied from interface:TlsManagerThis method will multiplex the call to allTlsReloadableComponents that are being managed by this manager.- Specified by:
- reloadin interface- TlsManager
- Parameters:
- tls- the new tls instance
- See Also:
 
- 
keyManagerDescription copied from interface:TlsManagerThe key manager in use.- Specified by:
- keyManagerin interface- TlsManager
- Returns:
- key manager
 
- 
trustManagerDescription copied from interface:TlsManagerThe trust manager in use.- Specified by:
- trustManagerin interface- TlsManager
- Returns:
- trust manager
 
- 
reloadReload the current SSL context with the provided key manager and trust manager (if defined).- Parameters:
- keyManager- key manager to use
- trustManager- trust manager to use
 
- 
initSslContextprotected void initSslContext(TlsConfig tlsConfig, SecureRandom secureRandom, KeyManager[] keyManagers, TrustManager[] trustManagers) Initialize and set theSSLContexton this manager instance.- Parameters:
- tlsConfig- the tls configuration
- secureRandom- the secure random
- keyManagers- the key managers
- trustManagers- the trust managers
 
- 
secureRandomLoad secure random.- Parameters:
- tlsConfig- TLS configuration
- Returns:
- secure random
 
- 
buildKmfprotected KeyManagerFactory buildKmf(TlsConfig target, SecureRandom secureRandom, PrivateKey privateKey, Certificate[] certificates) Build the key manager factory.- Parameters:
- target- the tls configuration
- secureRandom- the secure random
- privateKey- the private key for the key store
- certificates- the certificates for the keystore
- Returns:
- a key manager factory instance
 
- 
internalKeystoreCreates an internal keystore and loads it with no password and no data.- Parameters:
- tlsConfig- TLS config
- Returns:
- a new keystore
 
- 
createTmfCreate a new trust manager factory based on the configuration (i.e., the algorithm and provider).- Parameters:
- tlsConfig- TLS config
- Returns:
- a new trust manager factory
 
- 
initializeTmfPerform initialization of theTrustManagerFactorybased on the provided TLS configuration.- Parameters:
- tmf- trust manager factory to be initialized
- keyStore- keystore
- tlsConfig- tls configuration
 
- 
trustAllTmfCreates a trust all trust manager factory.- Returns:
- a new trust manager factory trusting all
 
 
-