Commit 3ebe4455 authored by unknown's avatar unknown
Browse files

Bug#20022 mysql-test-run can't be run with secure connections turned on for all testcases

 - Part 1, fixes rpl- and federated-tests where connection is made to 127.0.0.1


client/mysqltest.c:
  Turn on ssl_verify_server_cert only if host is "localhost"
parent a9e1cf72
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -2381,6 +2381,9 @@ int do_connect(struct st_query *q)
#ifdef HAVE_OPENSSL
  if (opt_use_ssl || con_ssl)
  {
    /* Turn on ssl_verify_server_cert only if host is "localhost" */
    opt_ssl_verify_server_cert= !strcmp(con_host, "localhost");

    mysql_ssl_set(&next_con->mysql, opt_ssl_key, opt_ssl_cert, opt_ssl_ca,
		  opt_ssl_capath, opt_ssl_cipher);
    mysql_options(&next_con->mysql, MYSQL_OPT_SSL_VERIFY_SERVER_CERT,