Merge branch 'sslrequest' into v1.2.0

connleak
René Cannaò 10 years ago
commit 6bacf8147e

@ -274,7 +274,8 @@ MySQL_Threads_Handler::MySQL_Threads_Handler() {
variables.server_version=strdup((char *)"5.1.30");
variables.eventslog_filename=strdup((char *)""); // proxysql-mysql-eventslog is recommended
variables.eventslog_filesize=100*1024*1024;
variables.server_capabilities=CLIENT_FOUND_ROWS | CLIENT_PROTOCOL_41 | CLIENT_IGNORE_SIGPIPE | CLIENT_TRANSACTIONS | CLIENT_SECURE_CONNECTION | CLIENT_CONNECT_WITH_DB | CLIENT_SSL;
// variables.server_capabilities=CLIENT_FOUND_ROWS | CLIENT_PROTOCOL_41 | CLIENT_IGNORE_SIGPIPE | CLIENT_TRANSACTIONS | CLIENT_SECURE_CONNECTION | CLIENT_CONNECT_WITH_DB | CLIENT_SSL;
variables.server_capabilities=CLIENT_FOUND_ROWS | CLIENT_PROTOCOL_41 | CLIENT_IGNORE_SIGPIPE | CLIENT_TRANSACTIONS | CLIENT_SECURE_CONNECTION | CLIENT_CONNECT_WITH_DB;
variables.poll_timeout=2000;
variables.poll_timeout_on_failure=100;
variables.have_compress=true;
@ -1149,6 +1150,10 @@ bool MySQL_Threads_Handler::set_variable(char *name, char *value) { // this is t
int intv=atoi(value);
if (intv > 10 && intv <= 65535) {
variables.server_capabilities=intv;
if (variables.server_capabilities & CLIENT_SSL) {
// for now disable CLIENT_SSL
variables.server_capabilities &= ~CLIENT_SSL;
}
return true;
} else {
return false;

Loading…
Cancel
Save