summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2016-09-20 22:00:27 +0200
committerJakub Hrozek <jhrozek@redhat.com>2017-03-27 09:53:17 +0200
commit4f511a4c5f0084e22ce4c7613f1b279533c68cc5 (patch)
treecdb1e8406570b5b5ec3c562fe5ea4846132df9a7
parentc194e8d7cad0184d710d9979e9f12d5cfe176f4a (diff)
downloadsssd-4f511a4c5f0084e22ce4c7613f1b279533c68cc5.tar.gz
sssd-4f511a4c5f0084e22ce4c7613f1b279533c68cc5.tar.xz
sssd-4f511a4c5f0084e22ce4c7613f1b279533c68cc5.zip
UTIL: Add utility macro cli_creds_get_gid()
The KCM responder checks the owneship of the ccache based on both UID and GID of the peer. In order to reuse the already existing creds structure, let's just add a new macro that returns the GID from the creds structure. Reviewed-by: Michal Židek <mzidek@redhat.com> Reviewed-by: Simo Sorce <simo@redhat.com>
-rw-r--r--src/util/util_creds.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/util/util_creds.h b/src/util/util_creds.h
index 65468fa12..936b9965d 100644
--- a/src/util/util_creds.h
+++ b/src/util/util_creds.h
@@ -71,6 +71,7 @@ struct cli_creds {
};
#define cli_creds_get_uid(x) x->ucred.uid
+#define cli_creds_get_gid(x) x->ucred.gid
#else /* not HAVE_UCRED */
struct cli_creds {