| 1 |
# Save the initial number of concurrent sessions |
| 2 |
--source include/count_sessions.inc |
| 3 |
# Allowed cipher regex |
| 4 |
--source include/allowed_ciphers.inc |
| 5 |
|
| 6 |
--echo # Setup |
| 7 |
|
| 8 |
--echo # Create test user |
| 9 |
CREATE USER admin_user IDENTIFIED BY 'abcd'; |
| 10 |
--echo # Grant required privilege so that test user |
| 11 |
--echo # can connect to server using admin interface |
| 12 |
GRANT SERVICE_CONNECTION_ADMIN ON *.* TO admin_user; |
| 13 |
|
| 14 |
|
| 15 |
--echo # Verify that TLS is configured for admin channel |
| 16 |
--query_vertical SELECT * FROM performance_schema.tls_channel_status WHERE CHANNEL = 'mysql_admin' AND PROPERTY = 'Enabled' |
| 17 |
|
| 18 |
--echo # Try to connect using TLS |
| 19 |
--replace_regex $ALLOWED_CIPHERS_REGEX |
| 20 |
--exec $MYSQL --host=127.0.0.1 --port=$MASTER_ADMINPORT --user=admin_user -pabcd --ssl-mode=REQUIRED -e "SELECT 1" |
| 21 |
|
| 22 |
--echo # Cleanup |
| 23 |
DROP USER admin_user; |
| 24 |
|
| 25 |
# Wait until all sessions are disconnected |
| 26 |
--source include/wait_until_count_sessions.inc |