mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Bug#19991 CHANGE MASTER need option ssl-verify-server-cert
- Add MASTER_SSL_VERIFY_SERVER_CERT option to CHANGE MASTER TO - Add Master_Ssl_Serify_Server_Cert to SHOW SLAVE STATUS - Save and restore ssl_verify_server_cert to master info file setting it to disabled as default.
This commit is contained in:
@ -1126,6 +1126,11 @@ bool change_master(THD* thd, MASTER_INFO* mi)
|
||||
|
||||
if (lex_mi->ssl != LEX_MASTER_INFO::SSL_UNCHANGED)
|
||||
mi->ssl= (lex_mi->ssl == LEX_MASTER_INFO::SSL_ENABLE);
|
||||
|
||||
if (lex_mi->ssl_verify_server_cert != LEX_MASTER_INFO::SSL_UNCHANGED)
|
||||
mi->ssl_verify_server_cert=
|
||||
(lex_mi->ssl_verify_server_cert == LEX_MASTER_INFO::SSL_ENABLE);
|
||||
|
||||
if (lex_mi->ssl_ca)
|
||||
strmake(mi->ssl_ca, lex_mi->ssl_ca, sizeof(mi->ssl_ca)-1);
|
||||
if (lex_mi->ssl_capath)
|
||||
@ -1138,7 +1143,8 @@ bool change_master(THD* thd, MASTER_INFO* mi)
|
||||
strmake(mi->ssl_key, lex_mi->ssl_key, sizeof(mi->ssl_key)-1);
|
||||
#ifndef HAVE_OPENSSL
|
||||
if (lex_mi->ssl || lex_mi->ssl_ca || lex_mi->ssl_capath ||
|
||||
lex_mi->ssl_cert || lex_mi->ssl_cipher || lex_mi->ssl_key )
|
||||
lex_mi->ssl_cert || lex_mi->ssl_cipher || lex_mi->ssl_key ||
|
||||
lex_mi->ssl_verify_server_cert )
|
||||
push_warning(thd, MYSQL_ERROR::WARN_LEVEL_NOTE,
|
||||
ER_SLAVE_IGNORED_SSL_PARAMS, ER(ER_SLAVE_IGNORED_SSL_PARAMS));
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user