Added optional parameters for services that allow all servers to be used when building the list of users.

This commit is contained in:
Markus Makela
2015-02-09 06:20:39 +02:00
parent 7cf65adc6e
commit 46ec9abe29
5 changed files with 384 additions and 342 deletions

View File

@ -779,6 +779,25 @@ serviceEnableRootUser(SERVICE *service, int action)
return 1;
}
/**
* Enable/Disable loading the user data from only one server or all of them
*
* @param service The service we are setting the data for
* @param action 1 for root enable, 0 for disable access
* @return 0 on failure
*/
int
serviceAuthAllServers(SERVICE *service, int action)
{
if (action != 0 && action != 1)
return 0;
service->users_from_all = action;
return 1;
}
/**
* Trim whitespace from the from an rear of a string
*