1# The SSL library may fail initializing during this one
2call mtr.add_suppression("Failed to set up SSL because of the following SSL library error");
3
4--echo ################## FR8: --ssl only applies to startups
5
6--echo # Check if ssl is off: must be off.
7--error 1
8--exec $MYSQL --ssl-mode=required -e "SELECT 1"
9
10--echo # reset and enable SSL
11ALTER INSTANCE RELOAD TLS;
12
13--echo # SSL must be enabled now despite the value of --ssl
14--exec $MYSQL --ssl-mode=required -e "SELECT 1"
15
16--echo # cleanup
17
18# Disables TLS by temporarily setting a wrong value, reloading TLS
19# and restoring the wrong value
20SET @orig_ssl_ca= @@global.ssl_ca;
21SET GLOBAL ssl_ca = 'gizmo';
22ALTER INSTANCE RELOAD TLS NO ROLLBACK ON ERROR;
23SET GLOBAL ssl_ca = @orig_ssl_ca;
24
25--echo ################## End of dynamic SSL tests
26