| 1 |
# Setup |
| 2 |
INSTALL PLUGIN connection_control SONAME 'CONNECTION_CONTROL_LIB'; |
| 3 |
INSTALL PLUGIN connection_control_failed_login_attempts SONAME 'CONNECTION_CONTROL_LIB'; |
| 4 |
# Save original values of connection_control variables |
| 5 |
SET @saved_connections_threshold = @@global.connection_control_failed_connections_threshold; |
| 6 |
SET @saved_min_delay = @@global.connection_control_min_connection_delay; |
| 7 |
# set connection_control variables |
| 8 |
SET @@global.connection_control_failed_connections_threshold = 1; |
| 9 |
SET @@global.connection_control_min_connection_delay = 2000; |
| 10 |
# processlist output |
| 11 |
select * from performance_schema.processlist where user='unauthenticated_user'; |
| 12 |
ID USER HOST DB COMMAND TIME STATE INFO EXECUTION_ENGINE |
| 13 |
<Id> unauthenticated_user <Host> NULL <Command> <Time> <State> NULL PRIMARY |
| 14 |
# Cleanup |
| 15 |
SET @@global.connection_control_failed_connections_threshold = @saved_connections_threshold; |
| 16 |
SET @@global.connection_control_min_connection_delay = @saved_min_delay; |
| 17 |
UNINSTALL PLUGIN connection_control; |
| 18 |
UNINSTALL PLUGIN connection_control_failed_login_attempts; |