From ca530f335e224b82b6f67c185c11aa86e4d058fa Mon Sep 17 00:00:00 2001 From: Ning Sun Date: Tue, 5 Mar 2024 18:00:14 +0800 Subject: [PATCH] feat: correct behaviour for ssl private key password --- ingester-grpc/src/main/java/io/greptime/rpc/GrpcClient.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ingester-grpc/src/main/java/io/greptime/rpc/GrpcClient.java b/ingester-grpc/src/main/java/io/greptime/rpc/GrpcClient.java index de14d5f..562a938 100644 --- a/ingester-grpc/src/main/java/io/greptime/rpc/GrpcClient.java +++ b/ingester-grpc/src/main/java/io/greptime/rpc/GrpcClient.java @@ -552,10 +552,10 @@ private SslContext newSslContext(TlsOptions tlsOptions) { if (tlsOptions.getClientCertChain().isPresent() && tlsOptions.getPrivateKey().isPresent()) { if (tlsOptions.getPrivateKeyPassword().isPresent()) { - builder.keyManager(tlsOptions.getClientCertChain().get(), tlsOptions.getPrivateKey().get()); - } else { builder.keyManager(tlsOptions.getClientCertChain().get(), tlsOptions.getPrivateKey().get(), tlsOptions.getPrivateKeyPassword().get()); + } else { + builder.keyManager(tlsOptions.getClientCertChain().get(), tlsOptions.getPrivateKey().get()); } }