Added service SSL mode variables.
This commit is contained in:
@ -420,7 +420,7 @@ hashtable_memory_fns(monitorhash,strdup,NULL,free,NULL);
|
||||
|
||||
/** Add the 5.5.5- string to the start of the version string if
|
||||
* the version string starts with "10.".
|
||||
* This mimics MariaDB 10.0 replication which adds 5.5.5- for backwards compatibility. */
|
||||
* This mimics MariaDB 10.0 behavior which adds 5.5.5- for backwards compatibility. */
|
||||
if(strncmp(version_string,"10.",3) == 0)
|
||||
{
|
||||
((SERVICE *)(obj->element))->version_string = malloc((strlen(version_string) +
|
||||
|
||||
@ -136,7 +136,8 @@ SERVICE *service;
|
||||
service->routerModule = strdup(router);
|
||||
service->users_from_all = false;
|
||||
service->resources = NULL;
|
||||
|
||||
service->ssl_mode = SSL_REQUIRED;
|
||||
|
||||
if (service->name == NULL || service->routerModule == NULL)
|
||||
{
|
||||
if (service->name)
|
||||
@ -855,6 +856,16 @@ serviceOptimizeWildcard(SERVICE *service, int action)
|
||||
return 1;
|
||||
}
|
||||
|
||||
/** Enable or disable the service SSL capability*/
|
||||
int
|
||||
serviceSetSSL(SERVICE *service, int action)
|
||||
{
|
||||
if(action)
|
||||
service->ssl_mode = SSL_REQUIRED;
|
||||
else
|
||||
service->ssl_mode = SSL_DISABLED;
|
||||
}
|
||||
|
||||
/**
|
||||
* Whether to strip escape characters from the name of the database the client
|
||||
* is connecting to.
|
||||
|
||||
Reference in New Issue
Block a user