Skip to content

Commit 37f9003

Browse files
committed
WL#13289: Remove yaSSL support from the 5.7 codebase
RB#22399
1 parent b8c8ae4 commit 37f9003

File tree

260 files changed

+119
-48138
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

260 files changed

+119
-48138
lines changed

.gitignore

Lines changed: 0 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -548,55 +548,6 @@ extra/resolve_stack_dump
548548
extra/resolveip
549549
extra/sql_state.h
550550
extra/tztime.cc
551-
extra/yassl/src/.deps/buffer.Plo
552-
extra/yassl/src/.deps/cert_wrapper.Plo
553-
extra/yassl/src/.deps/crypto_wrapper.Plo
554-
extra/yassl/src/.deps/handshake.Plo
555-
extra/yassl/src/.deps/lock.Plo
556-
extra/yassl/src/.deps/log.Plo
557-
extra/yassl/src/.deps/socket_wrapper.Plo
558-
extra/yassl/src/.deps/ssl.Plo
559-
extra/yassl/src/.deps/template_instnt.Plo
560-
extra/yassl/src/.deps/timer.Plo
561-
extra/yassl/src/.deps/yassl_error.Plo
562-
extra/yassl/src/.deps/yassl_imp.Plo
563-
extra/yassl/src/.deps/yassl_int.Plo
564-
extra/yassl/taocrypt/benchmark/.deps/benchmark-benchmark.Po
565-
extra/yassl/taocrypt/benchmark/benchmark
566-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-aes.Plo
567-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-aestables.Plo
568-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-algebra.Plo
569-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-arc4.Plo
570-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-asn.Plo
571-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-bftables.Plo
572-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-blowfish.Plo
573-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-coding.Plo
574-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-des.Plo
575-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-dh.Plo
576-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-dsa.Plo
577-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-file.Plo
578-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-hash.Plo
579-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-integer.Plo
580-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-md2.Plo
581-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-md4.Plo
582-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-md5.Plo
583-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-misc.Plo
584-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-random.Plo
585-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-ripemd.Plo
586-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-rsa.Plo
587-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-sha.Plo
588-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-template_instnt.Plo
589-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-tftables.Plo
590-
extra/yassl/taocrypt/src/.deps/libtaocrypt_la-twofish.Plo
591-
extra/yassl/taocrypt/test/.deps/test-test.Po
592-
extra/yassl/taocrypt/test/test
593-
extra/yassl/testsuite/.deps/testsuite-client.Po
594-
extra/yassl/testsuite/.deps/testsuite-echoclient.Po
595-
extra/yassl/testsuite/.deps/testsuite-echoserver.Po
596-
extra/yassl/testsuite/.deps/testsuite-server.Po
597-
extra/yassl/testsuite/.deps/testsuite-test.Po
598-
extra/yassl/testsuite/.deps/testsuite-testsuite.Po
599-
extra/yassl/testsuite/testsuite
600551
fcns.c
601552
fcns.h
602553
gdbinit

BUILD/SETUP.sh

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/sh
22

3-
# Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
3+
# Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.
44
#
55
# This program is free software; you can redistribute it and/or
66
# modify it under the terms of the GNU Library General Public
@@ -100,11 +100,8 @@ path=`dirname $0`
100100
export AM_MAKEFLAGS
101101
AM_MAKEFLAGS="-j 6"
102102

103-
# SSL library to use.--with-ssl will select our bundled yaSSL
104-
# implementation of SSL. To use openSSl you will nee too point out
105-
# the location of openSSL headers and lbs on your system.
106-
# Ex --with-ssl=/usr
107-
SSL_LIBRARY=--with-ssl
103+
# SSL library to use.
104+
SSL_LIBRARY=--with-ssl=system
108105

109106
if [ "x$warning_mode" = "xpedantic" ]; then
110107
warnings="-W -Wall -ansi -pedantic -Wno-long-long -Wno-unused -D_POSIX_SOURCE"
@@ -232,11 +229,9 @@ fi
232229

233230
# The -fprofile-arcs and -ftest-coverage options cause GCC to instrument the
234231
# code with profiling information used by gcov.
235-
# The -DDISABLE_TAO_ASM is needed to avoid build failures in Yassl.
236232
# The -DHAVE_gcov enables code to write out coverage info even when crashing.
237233

238234
gcov_compile_flags="-fprofile-arcs -ftest-coverage"
239-
gcov_compile_flags="$gcov_compile_flags -DDISABLE_TAO_ASM"
240235
gcov_compile_flags="$gcov_compile_flags -DMYSQL_SERVER_SUFFIX=-gcov -DHAVE_gcov"
241236

242237
# GCC4 needs -fprofile-arcs -ftest-coverage on the linker command line (as well

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -562,7 +562,7 @@ IF(BUILD_BUNDLED_ZLIB)
562562
${CMAKE_CURRENT_BINARY_DIR}/zlib
563563
)
564564
ENDIF()
565-
# Add bundled yassl/taocrypt or system openssl.
565+
# Add openssl.
566566
MYSQL_CHECK_SSL()
567567
# Add system/bundled editline.
568568
MYSQL_CHECK_EDITLINE()

client/base/mysql_connection_options.cc

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
2+
Copyright (c) 2014, 2019, Oracle and/or its affiliates. All rights reserved.
33
44
This program is free software; you can redistribute it and/or modify
55
it under the terms of the GNU General Public License as published by
@@ -163,15 +163,13 @@ MYSQL* Mysql_connection_options::create_connection()
163163
mysql_options4(connection, MYSQL_OPT_CONNECT_ATTR_ADD,
164164
"program_name", this->m_program->get_name().c_str());
165165

166-
#if !defined(HAVE_YASSL)
167166
if (this->m_server_public_key.has_value())
168167
{
169168
opt_server_public_key=
170169
const_cast <char *> (this->m_server_public_key.value().c_str());
171170
}
172171

173172
opt_get_server_public_key= this->m_get_server_public_key ? TRUE : FALSE;
174-
#endif /* !HAVE_YASSL */
175173

176174
set_server_public_key(connection);
177175
set_get_server_public_key_option(connection);

client/mysql_install_db.cc

Lines changed: 1 addition & 150 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
2+
Copyright (c) 2012, 2019, Oracle and/or its affiliates. All rights reserved.
33
44
This program is free software; you can redistribute it and/or modify
55
it under the terms of the GNU General Public License as published by
@@ -61,9 +61,6 @@ using namespace std;
6161

6262
#define PROGRAM_NAME "mysql_install_db"
6363
#define MYSQLD_EXECUTABLE "mysqld"
64-
#if defined(HAVE_YASSL)
65-
#define MYSQL_CERT_SETUP_EXECUTABLE "mysql_ssl_rsa_setup"
66-
#endif /* HAVE_YASSL */
6764
#define MAX_MYSQLD_ARGUMENTS 10
6865
#define MAX_USER_NAME_LEN 32
6966

@@ -81,10 +78,6 @@ char *opt_adminhost= 0;
8178
char default_authplugin[]= "mysql_native_password";
8279
char *opt_authplugin= 0;
8380
char *opt_mysqldfile= 0;
84-
#if defined (HAVE_YASSL)
85-
char *opt_mysql_cert_setup_file= 0;
86-
char default_mysql_cert_setup_file[]= MYSQL_CERT_SETUP_EXECUTABLE;
87-
#endif
8881
char *opt_randpwdfile= 0;
8982
char default_randpwfile[]= ".mysql_secret";
9083
char *opt_langpath= 0;
@@ -148,10 +141,6 @@ static struct my_option my_connection_options[]=
148141
&opt_ssl, 0, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0},
149142
{"mysqld-file", 0, "Qualified path to the mysqld binary.", &opt_mysqldfile,
150143
0, 0, GET_STR_ALLOC, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
151-
#if defined(HAVE_YASSL)
152-
{"ssl-setup-file", 0, "Qualified path to the mysql_ssl_setup binary", &opt_mysql_cert_setup_file,
153-
0, 0, GET_STR_ALLOC, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
154-
#endif
155144
{"random-password-file", 0, "Specifies the qualified path to the "
156145
".mysql_secret temporary password file.", &opt_randpwdfile,
157146
0, 0, GET_STR_ALLOC, REQUIRED_ARG, 0,
@@ -624,70 +613,6 @@ bool assert_mysqld_exists(const string &opt_mysqldfile,
624613
return true;
625614
}
626615

627-
#if defined(HAVE_YASSL)
628-
/**
629-
Attempts to locate the mysql_ssl_rsa_setup file.
630-
If opt_mysql_cert_setup_file is specified then the this assumed to be a
631-
correct qualified path to the mysql_ssl_rsa_setup executable.
632-
If opt_basedir is specified then opt_basedir+"/bin" is assumed to be a
633-
candidate path for the mysql_ssl_rsa_setup executable.
634-
If opt_srcdir is set then opt_srcdir+"/bin" is assumed to be a
635-
candidate path for the mysql_ssl_rsa_setup executable.
636-
If opt_builddir is set then opt_builddir+"/client" is assumed to be a
637-
candidate path for the mysql_system_tables executable.
638-
639-
If the executable isn't found in any of these locations,
640-
attempt to search the local directory and "bin" subdirectory.
641-
Finally check "/usr/bin","/usr/sbin", "/usr/local/bin","/usr/local/sbin",
642-
"/opt/mysql/bin","/opt/mysql/sbin"
643-
644-
*/
645-
bool assert_cert_generator_exists(const string &opt_mysql_cert_setup_file,
646-
const string &opt_basedir,
647-
const string &opt_builddir,
648-
const string &opt_srcdir,
649-
Path *qpath)
650-
{
651-
vector<Path > spaths;
652-
if (opt_mysql_cert_setup_file.length() > 0)
653-
{
654-
/* Use explicit option to file mysql_ssl_rsa_setup */
655-
if (!locate_file(opt_mysql_cert_setup_file, 0, qpath))
656-
{
657-
error << "No such file: " << opt_mysql_cert_setup_file << endl;
658-
return false;
659-
}
660-
}
661-
else
662-
{
663-
if (opt_basedir.length() > 0)
664-
{
665-
spaths.push_back(Path(opt_basedir).
666-
append("bin"));
667-
}
668-
if (opt_builddir.length() > 0)
669-
{
670-
spaths.push_back(Path(opt_builddir).
671-
append("client"));
672-
}
673-
674-
add_standard_search_paths(&spaths);
675-
676-
if (!locate_file(MYSQL_CERT_SETUP_EXECUTABLE, &spaths, qpath))
677-
{
678-
error << "Can't locate the server executable (mysql_ssl_rsa_setup)."
679-
<< endl;
680-
info << "The following paths were searched: ";
681-
copy(spaths.begin(), spaths.end(),
682-
infix_ostream_iterator<Path >(info, ", "));
683-
info << endl;
684-
return false;
685-
}
686-
}
687-
return true;
688-
}
689-
#endif /* HAVE_YASSL */
690-
691616

692617
bool assert_valid_language_directory(const string &opt_langpath,
693618
const string &opt_basedir,
@@ -803,19 +728,6 @@ void create_ssl_policy(string *ssl_type, string *ssl_cipher,
803728
*x509_subject= "";
804729
}
805730

806-
#if defined(HAVE_YASSL)
807-
808-
class SSL_generator_writer
809-
{
810-
public:
811-
bool operator()(int fh MY_ATTRIBUTE((unused)))
812-
{
813-
return true;
814-
}
815-
};
816-
817-
#endif /* HAVE_YASSL */
818-
819731
#define READ_BUFFER_SIZE 2048
820732
#define TIMEOUT_IN_SEC 30
821733

@@ -1563,20 +1475,6 @@ int main(int argc,char *argv[])
15631475
return 1;
15641476
}
15651477

1566-
#if defined(HAVE_YASSL)
1567-
Path mysql_cert_setup;
1568-
if( !opt_insecure &&
1569-
!assert_cert_generator_exists(create_string(opt_mysql_cert_setup_file),
1570-
basedir,
1571-
builddir,
1572-
srcdir,
1573-
&mysql_cert_setup))
1574-
{
1575-
/* Subroutine reported error */
1576-
return 1;
1577-
}
1578-
#endif /* HAVE_YASSL */
1579-
15801478
if (opt_def_extra_file)
15811479
{
15821480
Path def_extra_file;
@@ -1706,23 +1604,6 @@ int main(int argc,char *argv[])
17061604
command_line.push_back(string("--basedir=")
17071605
.append(basedir));
17081606

1709-
#if defined(HAVE_YASSL)
1710-
vector<string> cert_setup_command_line;
1711-
if (!opt_insecure)
1712-
{
1713-
if (opt_no_defaults == TRUE && opt_defaults_file == NULL &&
1714-
opt_def_extra_file == NULL)
1715-
cert_setup_command_line.push_back(string("--no-defaults"));
1716-
cert_setup_command_line.push_back(string("--datadir=")
1717-
.append(data_directory.to_str()));
1718-
cert_setup_command_line.push_back(string("--suffix=")
1719-
.append(MYSQL_SERVER_VERSION));
1720-
}
1721-
#endif /* HAVE_YASSL */
1722-
1723-
// DEBUG
1724-
//mysqld_exec.append("\"").insert(0, "gnome-terminal -e \"gdb --args ");
1725-
17261607
string ssl_type;
17271608
string ssl_cipher;
17281609
string x509_issuer;
@@ -1787,35 +1668,5 @@ int main(int argc,char *argv[])
17871668
<< endl;
17881669
}
17891670

1790-
#if defined(HAVE_YASSL)
1791-
if (!opt_insecure)
1792-
{
1793-
string ssl_output;
1794-
info << "Generating SSL Certificates" << endl;
1795-
success= process_execute(mysql_cert_setup.to_str(),
1796-
cert_setup_command_line.begin(),
1797-
cert_setup_command_line.end(),
1798-
Process_reader(&ssl_output),
1799-
SSL_generator_writer());
1800-
if (!success)
1801-
{
1802-
warning << "failed to execute " << mysql_cert_setup.to_str() << " ";
1803-
copy(cert_setup_command_line.begin(), cert_setup_command_line.end(),
1804-
infix_ostream_iterator<Path>(error, " "));
1805-
warning << endl;
1806-
warning << "SSL functionality may not work";
1807-
warning << endl;
1808-
}
1809-
else if ((ssl_output.size() > 0))
1810-
{
1811-
info << "SSL certificate generation :"
1812-
<< endl
1813-
<< ssl_output
1814-
<< endl;
1815-
}
1816-
}
1817-
1818-
#endif /* HAVE_YASSL */
1819-
18201671
return 0;
18211672
}

client/mysqltest.cc

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
1+
/* Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.
22
33
This program is free software; you can redistribute it and/or modify
44
it under the terms of the GNU General Public License as published by
@@ -6132,12 +6132,10 @@ void do_connect(struct st_command *command)
61326132
if (ds_default_auth.length)
61336133
mysql_options(&con_slot->mysql, MYSQL_DEFAULT_AUTH, ds_default_auth.str);
61346134

6135-
#if !defined(HAVE_YASSL)
61366135
/* Set server public_key */
61376136
if (opt_server_public_key && *opt_server_public_key)
61386137
mysql_options(&con_slot->mysql, MYSQL_SERVER_PUBLIC_KEY,
61396138
opt_server_public_key);
6140-
#endif
61416139

61426140
if (con_cleartext_enable)
61436141
mysql_options(&con_slot->mysql, MYSQL_ENABLE_CLEARTEXT_PLUGIN,
@@ -7147,12 +7145,10 @@ static struct my_option my_long_options[] =
71477145
{"plugin_dir", OPT_PLUGIN_DIR, "Directory for client-side plugins.",
71487146
&opt_plugin_dir, &opt_plugin_dir, 0,
71497147
GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
7150-
#if !defined(HAVE_YASSL)
71517148
{"server-public-key-path", OPT_SERVER_PUBLIC_KEY,
71527149
"File path to the server public RSA key in PEM format.",
71537150
&opt_server_public_key, &opt_server_public_key, 0,
71547151
GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
7155-
#endif
71567152
{ 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}
71577153
};
71587154

cmake/build_configurations/feature_set.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ IF(FEATURE_SET AND NOT WITHOUT_SERVER)
4545
ENDIF()
4646

4747
IF(NOT WITH_SSL)
48-
SET(WITH_SSL bundled CACHE STRING "")
48+
SET(WITH_SSL system CACHE STRING "")
4949
ENDIF()
5050
IF(NOT WITH_ZLIB)
5151
SET(WITH_ZLIB bundled CACHE STRING "")

0 commit comments

Comments
 (0)