You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@impala.apache.org by st...@apache.org on 2022/06/23 09:32:34 UTC

[impala] 01/02: IMPALA-11240: Change default ssl_cipher_list to eliminate insecure ciphers

This is an automated email from the ASF dual-hosted git repository.

stigahuang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/impala.git

commit f19f21def9ddca71d774467f5ad0ef6562df20c7
Author: Joe McDonnell <jo...@cloudera.com>
AuthorDate: Tue Jun 21 13:40:35 2022 -0700

    IMPALA-11240: Change default ssl_cipher_list to eliminate insecure ciphers
    
    The current default value for ssl_cipher_list is empty, which
    allows any cipher supported by the operating system's OpenSSL
    version. On several operating systems, this includes several
    known weak ciphers, such as those based on RC4.
    
    This changes the default to match what is used by Kudu,
    which is based on Mozilla's intermediate compatability
    level:
    https://wiki.mozilla.org/Security/Server_Side_TLS
    
    Users can get the old behavior by setting the ssl_cipher_list="".
    
    Tests:
     - Ran core tests
    
    Change-Id: I69fbfdbca3640b50d90e943f4d5c63fbc9cb1e76
    Reviewed-on: http://gerrit.cloudera.org:8080/18654
    Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
    Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
 be/src/service/impala-server.cc | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/be/src/service/impala-server.cc b/be/src/service/impala-server.cc
index f58f3a9e4..31582692a 100644
--- a/be/src/service/impala-server.cc
+++ b/be/src/service/impala-server.cc
@@ -63,6 +63,7 @@
 #include "gen-cpp/admission_control_service.proxy.h"
 #include "kudu/rpc/rpc_context.h"
 #include "kudu/rpc/rpc_controller.h"
+#include "kudu/security/security_flags.h"
 #include "kudu/util/random_util.h"
 #include "rpc/authentication.h"
 #include "rpc/rpc-mgr.h"
@@ -129,6 +130,7 @@ using boost::uuids::uuid;
 using google::protobuf::RepeatedPtrField;
 using kudu::GetRandomSeed32;
 using kudu::rpc::RpcContext;
+using kudu::security::SecurityDefaults;
 using namespace apache::hive::service::cli::thrift;
 using namespace apache::thrift;
 using namespace apache::thrift::transport;
@@ -232,10 +234,10 @@ DEFINE_string(ssl_private_key_password_cmd, "", "A Unix command whose output ret
     "will not be invoked. The output of the command will be truncated to 1024 bytes, and "
     "then all trailing whitespace will be trimmed before it is used to decrypt the "
     "private key");
-
-// TODO: For 3.0 (compatibility-breaking release), set this to a whitelist of ciphers,
-// e.g.  https://wiki.mozilla.org/Security/Server_Side_TLS
-DEFINE_string(ssl_cipher_list, "",
+// This defaults ssl_cipher_list to the same set of ciphers used by Kudu,
+// which is based on Mozilla's intermediate compatibility recommendations
+// from https://wiki.mozilla.org/Security/Server_Side_TLS
+DEFINE_string(ssl_cipher_list, SecurityDefaults::kDefaultTlsCiphers,
     "The cipher suite preferences to use for TLS-secured "
     "Thrift RPC connections. Uses the OpenSSL cipher preference list format. See man (1) "
     "ciphers for more information. If empty, the default cipher list for your platform "