diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2019-05-23 10:32:21 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2019-05-23 10:32:21 +0300 |
commit | 826f9d4f7e99973cafe7654697d7c50b8b64b76b (patch) | |
tree | 8e41c3a90d40c21c37fcbd0658afe7d349865540 /sql-common/client.c | |
parent | e5d71e0b3d3ebd4e69526002720f93d62a3fd641 (diff) | |
parent | 31fe70290c54c44231aed881f5138924f32e47c5 (diff) | |
download | mariadb-git-826f9d4f7e99973cafe7654697d7c50b8b64b76b.tar.gz |
Merge 10.4 into 10.5
Diffstat (limited to 'sql-common/client.c')
-rw-r--r-- | sql-common/client.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sql-common/client.c b/sql-common/client.c index c66cb1a749d..8596d1cafee 100644 --- a/sql-common/client.c +++ b/sql-common/client.c @@ -12,7 +12,7 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335 USA */ /* This file is included by both libmysql.c (the MySQL client C API) @@ -1575,8 +1575,10 @@ static int ssl_verify_server_cert(Vio *vio, const char* server_hostname, const c */ #ifdef HAVE_X509_check_host - ret_validation= X509_check_host(server_cert, server_hostname, - strlen(server_hostname), 0, 0) != 1; + ret_validation= + (X509_check_host(server_cert, server_hostname, + strlen(server_hostname), 0, 0) != 1) && + (X509_check_ip_asc(server_cert, server_hostname, 0) != 1); #else subject= X509_get_subject_name(server_cert); cn_loc= X509_NAME_get_index_by_NID(subject, NID_commonName, -1); |