1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-30 19:23:07 +03:00

MCOL-497 securing mysql connection with TLS in crossengine and querystats code.

This commit is contained in:
Roman Nozdrin
2017-12-19 08:21:55 +03:00
parent b795e6b781
commit fbd081dbf1
11 changed files with 302 additions and 221 deletions

View File

@ -532,6 +532,9 @@ void Oam::getSystemConfig(const std::string& module, ModuleConfig& moduleconfig)
const string MODULE_DISABLE_STATE = "ModuleDisableState";
const string MODULE_DBROOT_COUNT = "ModuleDBRootCount";
const string MODULE_DBROOT_ID = "ModuleDBRootID";
const string MODULE_TLS_CA = "ModuleTLSCA";
const string MODULE_TLS_CL_CERT = "ModuleTLSClientCert";
const string MODULE_TLS_CL_KEY = "ModuleTLSClientKey";
string moduletype = module.substr(0, MAX_MODULE_TYPE_SIZE);
int moduleID = atoi(module.substr(MAX_MODULE_TYPE_SIZE, MAX_MODULE_ID_SIZE).c_str());
@ -606,6 +609,13 @@ void Oam::getSystemConfig(const std::string& module, ModuleConfig& moduleconfig)
sort ( moduleconfig.dbrootConfigList.begin(), moduleconfig.dbrootConfigList.end() );
if ( moduletype == "um" )
{
moduleconfig.TLSCA = sysConfig->getConfig(Section, MODULE_TLS_CA + itoa(moduleTypeID) );
moduleconfig.TLSClientCert = sysConfig->getConfig(Section, MODULE_TLS_CL_CERT + itoa(moduleTypeID) );
moduleconfig.TLSClientKey = sysConfig->getConfig(Section, MODULE_TLS_CL_KEY + itoa(moduleTypeID) );
}
return;
}
}
@ -2953,8 +2963,6 @@ oamModuleInfo_t Oam::getModuleInfo()
// Get Server Type Install ID
serverTypeInstall = atoi(sysConfig->getConfig("Installation", "ServerTypeInstall").c_str());
sysConfig;
}
catch (...) {}