MXS-1167: Skip permission checks for internal services

If a server points to a local MaxScale listener, the permission checks for
that server are skipped. This allows permission checks to be used with a
mix of external servers and internal services.
This commit is contained in:
Markus Mäkelä
2017-03-17 07:48:59 +02:00
parent 2e6e8574a4
commit 0b5d164855
5 changed files with 63 additions and 1 deletions

View File

@ -241,6 +241,14 @@ bool serviceHasBackend(SERVICE *service, SERVER *server);
bool serviceHasListener(SERVICE *service, const char *protocol,
const char* address, unsigned short port);
/**
* @brief Check if a MaxScale service listens on a port
*
* @param port The port to check
* @return True if a MaxScale service uses the port
*/
bool service_port_is_used(unsigned short port);
int serviceGetUser(SERVICE *service, char **user, char **auth);
int serviceSetUser(SERVICE *service, char *user, char *auth);
bool serviceSetFilters(SERVICE *service, char *filters);