started cleaning the mess with rsAccounts: only exposed useful functionality of rsAccount beyond a static class and removed all references to rsAccounts in the code

This commit is contained in:
csoler 2018-07-24 23:47:32 +02:00
parent e2bb3aef1b
commit 0f758902cd
No known key found for this signature in database
GPG key ID: 7BCA522266C0804C
19 changed files with 279 additions and 214 deletions

View file

@ -94,7 +94,7 @@ namespace resource_api{
std::string getDefaultDocroot()
{
return RsAccounts::DataDirectory(false) + "/webui";
return RsAccounts::systemDataDirectory(false) + "/webui";
}
const char* API_ENTRY_PATH = "/api/v2";

View file

@ -539,7 +539,7 @@ void RsControlModule::handleCreateLocation(Request &req, Response &resp)
mPassword = pgp_password;
mFixedPassword = pgp_password;
}
bool ssl_ok = RsAccounts::GenerateSSLCertificate(pgp_id, "", ssl_name, "", hidden_port!=0, ssl_password, ssl_id, err_string);
bool ssl_ok = RsAccounts::createNewAccount(pgp_id, "", ssl_name, "", hidden_port!=0, ssl_password, ssl_id, err_string);
// clear fixed password to restore normal password operation
// {