@FunctionalInterface public interface SSLContextSelector
Modifier and Type | Field and Description |
---|---|
static SSLContextSelector |
NULL_SELECTOR
A selector which always returns
null (no match). |
Modifier and Type | Method and Description |
---|---|
static SSLContextSelector |
aggregate(SSLContextSelector... selectors)
Create an aggregate selector which executes each given selector in order until a match is found.
|
static SSLContextSelector |
aggregate(SSLContextSelector selector1,
SSLContextSelector selector2)
Create an aggregate selector which executes each given selector in order until a match is found.
|
static SSLContextSelector |
constantSelector(SSLContext context)
Create a selector which always returns the same context.
|
SSLContext |
selectContext(SSLConnectionInformation connectionInformation)
Select the SSL context which corresponds to the given connection information.
|
static SSLContextSelector |
sniMatcherSelector(SNIMatcher matcher,
SSLContext context)
Create a selector which returns the given SSL context if the given SNI matcher matches.
|
static final SSLContextSelector NULL_SELECTOR
null
(no match).SSLContext selectContext(SSLConnectionInformation connectionInformation)
null
if no SSL contexts match, in which case a fallback
selector may be used, or a default SSL context selected. If no selectors match an SSL context, the connection
is refused.connectionInformation
- information about the in-progress connectionnull
if the connection is not acceptable to this selectorstatic SSLContextSelector aggregate(SSLContextSelector selector1, SSLContextSelector selector2)
selector1
- the first selector to testselector2
- the second selector to teststatic SSLContextSelector aggregate(SSLContextSelector... selectors)
selectors
- the selectors to teststatic SSLContextSelector sniMatcherSelector(SNIMatcher matcher, SSLContext context)
matcher
- the SNI matcher (must not be null
)context
- the SSL context to select (must not be null
)null
SNIHostName.createSNIMatcher(String)
,
SSLUtils.createHostNameStringPredicateSNIMatcher(java.util.function.Predicate)
,
SSLUtils.createHostNamePredicateSNIMatcher(java.util.function.Predicate)
,
SSLUtils.createHostNameStringSNIMatcher(String)
,
SSLUtils.createHostNameSuffixSNIMatcher(String)
static SSLContextSelector constantSelector(SSLContext context)
context
- the context to returncontext
Copyright © 2017 JBoss by Red Hat. All rights reserved.