diff options
author | Lukas Slebodnik <lslebodn@redhat.com> | 2015-02-18 10:23:19 +0100 |
---|---|---|
committer | Jakub Hrozek <jhrozek@redhat.com> | 2015-02-18 16:42:43 +0100 |
commit | 29b2fbec52308454fc87ec4bc43b638236220901 (patch) | |
tree | 677ed522a276a9d3c24d5078de766d3292a31092 | |
parent | 89caf3e55c20567d24f08eeabe4b6289c6e28852 (diff) | |
download | sssd-29b2fbec52308454fc87ec4bc43b638236220901.tar.gz sssd-29b2fbec52308454fc87ec4bc43b638236220901.tar.xz sssd-29b2fbec52308454fc87ec4bc43b638236220901.zip |
RESPONDERS: Warn to syslog about colliding objects
Resolves:
https://fedorahosted.org/sssd/ticket/2203
Reviewed-by: Pavel Reichl <preichl@redhat.com>
-rw-r--r-- | src/responder/ifp/ifpsrv_cmd.c | 4 | ||||
-rw-r--r-- | src/responder/nss/nsssrv_cmd.c | 14 | ||||
-rw-r--r-- | src/responder/pam/pamsrv_cmd.c | 4 |
3 files changed, 22 insertions, 0 deletions
diff --git a/src/responder/ifp/ifpsrv_cmd.c b/src/responder/ifp/ifpsrv_cmd.c index 49792f53c..adea3818e 100644 --- a/src/responder/ifp/ifpsrv_cmd.c +++ b/src/responder/ifp/ifpsrv_cmd.c @@ -617,6 +617,10 @@ static errno_t ifp_user_get_attr_search(struct tevent_req *req) if (state->res->count > 1) { DEBUG(SSSDBG_CRIT_FAILURE, "getpwnam call returned more than one result !?!\n"); + sss_log(SSS_LOG_ERR, + "More users have the same name [%s@%s] in SSSD cache. " + "SSSD will not work correctly.\n", + name, dom->name); return ENOENT; } } diff --git a/src/responder/nss/nsssrv_cmd.c b/src/responder/nss/nsssrv_cmd.c index 9c5609632..19a6121d8 100644 --- a/src/responder/nss/nsssrv_cmd.c +++ b/src/responder/nss/nsssrv_cmd.c @@ -908,6 +908,10 @@ static int nss_cmd_getpwnam_search(struct nss_dom_ctx *dctx) if (dctx->res->count > 1) { DEBUG(SSSDBG_FATAL_FAILURE, "getpwnam call returned more than one result !?!\n"); + sss_log(SSS_LOG_ERR, + "More users have the same name [%s@%s] in SSSD cache. " + "SSSD will not work correctly.\n", + name, dom->name); return ENOENT; } @@ -1580,6 +1584,9 @@ static int nss_cmd_getpwuid_search(struct nss_dom_ctx *dctx) if (dctx->res->count > 1) { DEBUG(SSSDBG_FATAL_FAILURE, "getpwuid call returned more than one result !?!\n"); + sss_log(SSS_LOG_ERR, + "More users have the same UID [%"PRIu32"] in directory " + "server. SSSD will not work correctly.\n", cmdctx->id); ret = ENOENT; goto done; } @@ -3003,6 +3010,10 @@ static int nss_cmd_getgrnam_search(struct nss_dom_ctx *dctx) if (dctx->res->count > 1) { DEBUG(SSSDBG_FATAL_FAILURE, "getgrnam call returned more than one result !?!\n"); + sss_log(SSS_LOG_ERR, + "More groups have the same name [%s@%s] in SSSD cache. " + "SSSD will not work correctly.\n", + name, dom->name); return ENOENT; } @@ -3138,6 +3149,9 @@ static int nss_cmd_getgrgid_search(struct nss_dom_ctx *dctx) if (dctx->res->count > 1) { DEBUG(SSSDBG_FATAL_FAILURE, "getgrgid call returned more than one result !?!\n"); + sss_log(SSS_LOG_ERR, + "More groups have the same GID [%"PRIu32"] in directory " + "server. SSSD will not work correctly.\n", cmdctx->id); ret = ENOENT; goto done; } diff --git a/src/responder/pam/pamsrv_cmd.c b/src/responder/pam/pamsrv_cmd.c index 7cab7b2b4..90cdbec51 100644 --- a/src/responder/pam/pamsrv_cmd.c +++ b/src/responder/pam/pamsrv_cmd.c @@ -1090,6 +1090,10 @@ static int pam_check_user_search(struct pam_auth_req *preq) if (res->count > 1) { DEBUG(SSSDBG_FATAL_FAILURE, "getpwnam call returned more than one result !?!\n"); + sss_log(SSS_LOG_ERR, + "More users have the same name [%s@%s] in SSSD cache. " + "SSSD will not work correctly.\n", + name, dom->name); return ENOENT; } else if (res->count == 0) { ret = ENOENT; |