Package org.springframework.boot.ssl
Interface SslBundle
- All Known Implementing Classes:
PropertiesSslBundle
,WebServerSslBundle
public interface SslBundle
A bundle of trust material that can be used to establish an SSL connection.
- Since:
- 3.1.0
- Author:
- Scott Frederick
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptiondefault SSLContext
Factory method to create a newSSLContext
for this bundle.getKey()
Return a reference to the key that should be used for this bundle orSslBundleKey.NONE
.ReturnSslOptions
that should be applied when establishing the SSL connection.Return the protocol to use when establishing the connection.Return theSslStoreBundle
that can be used to access this bundle's key and trust stores.static SslBundle
of
(SslStoreBundle stores) Factory method to create a newSslBundle
instance.static SslBundle
of
(SslStoreBundle stores, SslBundleKey key) Factory method to create a newSslBundle
instance.static SslBundle
of
(SslStoreBundle stores, SslBundleKey key, SslOptions options) Factory method to create a newSslBundle
instance.static SslBundle
of
(SslStoreBundle stores, SslBundleKey key, SslOptions options, String protocol) Factory method to create a newSslBundle
instance.static SslBundle
of
(SslStoreBundle stores, SslBundleKey key, SslOptions options, String protocol, SslManagerBundle managers) Factory method to create a newSslBundle
instance.
-
Field Details
-
DEFAULT_PROTOCOL
The default protocol to use.- See Also:
-
-
Method Details
-
getStores
SslStoreBundle getStores()Return theSslStoreBundle
that can be used to access this bundle's key and trust stores.- Returns:
- the
SslStoreBundle
instance for this bundle
-
getKey
SslBundleKey getKey()Return a reference to the key that should be used for this bundle orSslBundleKey.NONE
.- Returns:
- a reference to the SSL key that should be used
-
getOptions
SslOptions getOptions()ReturnSslOptions
that should be applied when establishing the SSL connection.- Returns:
- the options that should be applied
-
getProtocol
String getProtocol()Return the protocol to use when establishing the connection. Values should be supported bySSLContext.getInstance(String)
.- Returns:
- the SSL protocol
- See Also:
-
getManagers
SslManagerBundle getManagers()- Returns:
- the
SslManagerBundle
instance for this bundle
-
createSslContext
Factory method to create a newSSLContext
for this bundle.- Returns:
- a new
SSLContext
instance
-
of
Factory method to create a newSslBundle
instance.- Parameters:
stores
- the stores ornull
- Returns:
- a new
SslBundle
instance
-
of
Factory method to create a newSslBundle
instance.- Parameters:
stores
- the stores ornull
key
- the key ornull
- Returns:
- a new
SslBundle
instance
-
of
Factory method to create a newSslBundle
instance.- Parameters:
stores
- the stores ornull
key
- the key ornull
options
- the options ornull
- Returns:
- a new
SslBundle
instance
-
of
Factory method to create a newSslBundle
instance.- Parameters:
stores
- the stores ornull
key
- the key ornull
options
- the options ornull
protocol
- the protocol ornull
- Returns:
- a new
SslBundle
instance
-
of
static SslBundle of(SslStoreBundle stores, SslBundleKey key, SslOptions options, String protocol, SslManagerBundle managers) Factory method to create a newSslBundle
instance.- Parameters:
stores
- the stores ornull
key
- the key ornull
options
- the options ornull
protocol
- the protocol ornull
managers
- the managers ornull
- Returns:
- a new
SslBundle
instance
-