URL: https://github.com/SSSD/sssd/pull/80
Author: celestian
 Title: #80: SYSDB: Sudorule without a sudoUser returns EINVAL
Action: opened

PR body:
"""
This patch solved a regression caused by the recent patches
to lowercase sudoUser -- in case sudoUser is missing completely,
we abort the processing of this rule and all others.

With this patch, we return EINVAL and gracefully skip
the malgormed rule instead.

Resolves:
https://fedorahosted.org/sssd/ticket/3241
"""

To pull the PR as Git branch:
git remote add ghsssd https://github.com/SSSD/sssd
git fetch ghsssd pull/80/head:pr80
git checkout pr80
From 8877575954842bb2dfcf545b79a3db3ee06521a4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Petr=20=C4=8Cech?= <pc...@redhat.com>
Date: Wed, 16 Nov 2016 10:09:18 +0100
Subject: [PATCH] SYSDB: Sudorule without a sudoUser returns EINVAL

This patch solved a regression caused by the recent patches
to lowercase sudoUser -- in case sudoUser is missing completely,
we abort the processing of this rule and all others.

With this patch, we return EINVAL and gracefully skip
the malgormed rule instead.

Resolves:
https://fedorahosted.org/sssd/ticket/3241
---
 src/db/sysdb_sudo.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/db/sysdb_sudo.c b/src/db/sysdb_sudo.c
index 4bd93ff..0a59e89 100644
--- a/src/db/sysdb_sudo.c
+++ b/src/db/sysdb_sudo.c
@@ -874,6 +874,7 @@ static errno_t sysdb_sudo_add_lowered_users(struct sss_domain_info *domain,
     if (ret != EOK) {
         DEBUG(SSSDBG_OP_FAILURE, "Unable to get %s attribute [%d]: %s\n",
               SYSDB_SUDO_CACHE_AT_USER, ret, strerror(ret));
+        ret = EINVAL;
         goto done;
     }
 
_______________________________________________
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org

Reply via email to