summaryrefslogtreecommitdiff
path: root/src/responder
diff options
context:
space:
mode:
Diffstat (limited to 'src/responder')
-rw-r--r--src/responder/nss/nsssrv_netgroup.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/responder/nss/nsssrv_netgroup.c b/src/responder/nss/nsssrv_netgroup.c
index 4ec4161c..12be52bf 100644
--- a/src/responder/nss/nsssrv_netgroup.c
+++ b/src/responder/nss/nsssrv_netgroup.c
@@ -363,7 +363,14 @@ static errno_t setnetgrent_retry(struct tevent_req *req)
}
ret = lookup_netgr_step(step_ctx);
- if (ret != EOK) {
+ switch (ret) {
+ case EOK:
+ break;
+ case EMSGSIZE:
+ state->netgr->ready = true;
+ ret = ENOENT;
+ /* FALLTHROUGH */
+ default:
goto done;
}
tevent_req_done(req);
@@ -459,6 +466,11 @@ static errno_t lookup_netgr_step(struct setent_step_ctx *step_ctx)
/* Look up the netgroup in the cache */
ret = sysdb_getnetgr(step_ctx->dctx, sysdb, dom, name,
&step_ctx->dctx->res);
+ if (step_ctx->dctx->res->count > 1) {
+ DEBUG(SSSDBG_FATAL_FAILURE,
+ ("getnetgr call returned more than one result !?!\n"));
+ return EMSGSIZE;
+ }
if (ret == ENOENT) {
/* This netgroup was not found in this domain */
if (!step_ctx->dctx->check_provider) {