Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for IBMJSSE2 into grpc-java #7422

Merged
merged 8 commits into from Sep 16, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 13 additions & 1 deletion netty/src/main/java/io/grpc/netty/GrpcSslContexts.java
Expand Up @@ -82,6 +82,7 @@ private GrpcSslContexts() {}
NEXT_PROTOCOL_VERSIONS);

private static final String SUN_PROVIDER_NAME = "SunJSSE";
private static final String IBM_PROVIDER_NAME = "IBMJSSE2";

/**
* Creates an SslContextBuilder with ciphers and APN appropriate for gRPC.
Expand Down Expand Up @@ -196,7 +197,14 @@ public static SslContextBuilder configure(SslContextBuilder builder, Provider jd
apc = ALPN;
} else {
throw new IllegalArgumentException(
SUN_PROVIDER_NAME + " selected, but Java 9+ and Jetty NPN/ALPN unavailable");
jdkProvider.getName() + " selected, but Java 9+ and Jetty NPN/ALPN unavailable");
}
} else if (IBM_PROVIDER_NAME.equals(jdkProvider.getName())) {
if (JettyTlsUtil.isJava9AlpnAvailable()) {
apc = ALPN;
} else {
throw new IllegalArgumentException(
sanjaypujare marked this conversation as resolved.
Show resolved Hide resolved
jdkProvider.getName() + " selected, but Java 9+ ALPN unavailable");
}
} else if (ConscryptLoader.isConscrypt(jdkProvider)) {
apc = ALPN;
Expand Down Expand Up @@ -243,6 +251,10 @@ private static Provider findJdkProvider() {
|| JettyTlsUtil.isJava9AlpnAvailable()) {
return provider;
}
} else if (IBM_PROVIDER_NAME.equals(provider.getName())) {
sanjaypujare marked this conversation as resolved.
Show resolved Hide resolved
if (JettyTlsUtil.isJava9AlpnAvailable()) {
return provider;
}
} else if (ConscryptLoader.isConscrypt(provider)) {
return provider;
}
Expand Down