ReferenceCountedOpenSslContext() — netty Function Reference
Architecture documentation for the ReferenceCountedOpenSslContext() function in ReferenceCountedOpenSslContext.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD f3954116_a651_4a53_b811_f3e9b4849519["ReferenceCountedOpenSslContext()"] a8fb0f76_e201_5987_db10_2b8b0b47e791["ReferenceCountedOpenSslContext"] f3954116_a651_4a53_b811_f3e9b4849519 -->|defined in| a8fb0f76_e201_5987_db10_2b8b0b47e791 ea5a56d5_d36f_b820_f146_1680b428453c["opensslSelectorFailureBehavior()"] f3954116_a651_4a53_b811_f3e9b4849519 -->|calls| ea5a56d5_d36f_b820_f146_1680b428453c 28445b4f_132d_ed94_fb71_3bda4e7021da["isClient()"] f3954116_a651_4a53_b811_f3e9b4849519 -->|calls| 28445b4f_132d_ed94_fb71_3bda4e7021da 3749c2ba_d7d0_ccbc_e238_6b90b3791b73["setUseTasks()"] f3954116_a651_4a53_b811_f3e9b4849519 -->|calls| 3749c2ba_d7d0_ccbc_e238_6b90b3791b73 0a79ef7d_c46d_9aa0_4d56_9443f6cd10f3["setPrivateKeyMethod()"] f3954116_a651_4a53_b811_f3e9b4849519 -->|calls| 0a79ef7d_c46d_9aa0_4d56_9443f6cd10f3 5bc9d740_9044_981a_f1f4_824ebd694e43["PrivateKeyMethod()"] f3954116_a651_4a53_b811_f3e9b4849519 -->|calls| 5bc9d740_9044_981a_f1f4_824ebd694e43 b154f30b_10cd_8bc3_cd2f_4764f8bc4ce9["AsyncPrivateKeyMethod()"] f3954116_a651_4a53_b811_f3e9b4849519 -->|calls| b154f30b_10cd_8bc3_cd2f_4764f8bc4ce9 f6e1e1a8_72c3_ae2c_d85a_5212a39abe3a["CompressionAlgorithm()"] f3954116_a651_4a53_b811_f3e9b4849519 -->|calls| f6e1e1a8_72c3_ae2c_d85a_5212a39abe3a 4bd0abd9_b8ec_3db0_ec88_b0976da28e9e["release()"] f3954116_a651_4a53_b811_f3e9b4849519 -->|calls| 4bd0abd9_b8ec_3db0_ec88_b0976da28e9e style f3954116_a651_4a53_b811_f3e9b4849519 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
handler/src/main/java/io/netty/handler/ssl/ReferenceCountedOpenSslContext.java lines 223–488
ReferenceCountedOpenSslContext(Iterable<String> ciphers, CipherSuiteFilter cipherFilter,
OpenSslApplicationProtocolNegotiator apn, int mode, Certificate[] keyCertChain,
ClientAuth clientAuth, String[] protocols, boolean startTls,
String endpointIdentificationAlgorithm, boolean enableOcsp,
boolean leakDetection, List<SNIServerName> serverNames,
ResumptionController resumptionController,
Map.Entry<SslContextOption<?>, Object>... ctxOptions)
throws SSLException {
super(startTls, resumptionController);
OpenSsl.ensureAvailability();
if (enableOcsp && !OpenSsl.isOcspSupported()) {
throw new IllegalStateException("OCSP is not supported.");
}
if (mode != SSL.SSL_MODE_SERVER && mode != SSL.SSL_MODE_CLIENT) {
throw new IllegalArgumentException("mode most be either SSL.SSL_MODE_SERVER or SSL.SSL_MODE_CLIENT");
}
boolean tlsFalseStart = false;
boolean useTasks = USE_TASKS;
OpenSslPrivateKeyMethod privateKeyMethod = null;
OpenSslAsyncPrivateKeyMethod asyncPrivateKeyMethod = null;
OpenSslCertificateCompressionConfig certCompressionConfig = null;
Integer maxCertificateList = null;
Integer tmpDhKeyLength = null;
String[] groups = OpenSsl.NAMED_GROUPS;
if (ctxOptions != null) {
for (Map.Entry<SslContextOption<?>, Object> ctxOpt : ctxOptions) {
SslContextOption<?> option = ctxOpt.getKey();
if (option == OpenSslContextOption.TLS_FALSE_START) {
tlsFalseStart = (Boolean) ctxOpt.getValue();
} else if (option == OpenSslContextOption.USE_TASKS) {
useTasks = (Boolean) ctxOpt.getValue();
} else if (option == OpenSslContextOption.PRIVATE_KEY_METHOD) {
privateKeyMethod = (OpenSslPrivateKeyMethod) ctxOpt.getValue();
} else if (option == OpenSslContextOption.ASYNC_PRIVATE_KEY_METHOD) {
asyncPrivateKeyMethod = (OpenSslAsyncPrivateKeyMethod) ctxOpt.getValue();
} else if (option == OpenSslContextOption.CERTIFICATE_COMPRESSION_ALGORITHMS) {
certCompressionConfig = (OpenSslCertificateCompressionConfig) ctxOpt.getValue();
} else if (option == OpenSslContextOption.MAX_CERTIFICATE_LIST_BYTES) {
maxCertificateList = (Integer) ctxOpt.getValue();
} else if (option == OpenSslContextOption.TMP_DH_KEYLENGTH) {
tmpDhKeyLength = (Integer) ctxOpt.getValue();
} else if (option == OpenSslContextOption.GROUPS) {
String[] groupsArray = (String[]) ctxOpt.getValue();
Set<String> groupsSet = new LinkedHashSet<String>(groupsArray.length);
for (String group : groupsArray) {
groupsSet.add(GroupsConverter.toOpenSsl(group));
}
groups = groupsSet.toArray(EmptyArrays.EMPTY_STRINGS);
} else if (option == OpenSslContextOption.USE_JDK_PROVIDER_SIGNATURES) {
// Alternative key fallback policy - handled during key material setup
logger.debug("Alternative key fallback policy set to: " + ctxOpt.getValue());
} else {
logger.debug("Skipping unsupported " + SslContextOption.class.getSimpleName()
+ ": " + ctxOpt.getKey());
}
}
}
if (privateKeyMethod != null && asyncPrivateKeyMethod != null) {
throw new IllegalArgumentException("You can either only use "
+ OpenSslAsyncPrivateKeyMethod.class.getSimpleName() + " or "
+ OpenSslPrivateKeyMethod.class.getSimpleName());
}
this.tlsFalseStart = tlsFalseStart;
leak = leakDetection ? leakDetector.track(this) : null;
this.mode = mode;
this.clientAuth = isServer() ? checkNotNull(clientAuth, "clientAuth") : ClientAuth.NONE;
this.protocols = protocols == null ? OpenSsl.defaultProtocols(mode == SSL.SSL_MODE_CLIENT) : protocols;
this.endpointIdentificationAlgorithm = endpointIdentificationAlgorithm;
this.serverNames = serverNames;
this.enableOcsp = enableOcsp;
this.keyCertChain = keyCertChain == null ? null : keyCertChain.clone();
String[] suites = checkNotNull(cipherFilter, "cipherFilter").filterCipherSuites(
Domain
Subdomains
Calls
Source
Frequently Asked Questions
What does ReferenceCountedOpenSslContext() do?
ReferenceCountedOpenSslContext() is a function in the netty codebase, defined in handler/src/main/java/io/netty/handler/ssl/ReferenceCountedOpenSslContext.java.
Where is ReferenceCountedOpenSslContext() defined?
ReferenceCountedOpenSslContext() is defined in handler/src/main/java/io/netty/handler/ssl/ReferenceCountedOpenSslContext.java at line 223.
What does ReferenceCountedOpenSslContext() call?
ReferenceCountedOpenSslContext() calls 8 function(s): AsyncPrivateKeyMethod, CompressionAlgorithm, PrivateKeyMethod, isClient, opensslSelectorFailureBehavior, release, setPrivateKeyMethod, setUseTasks.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free