aboutsummaryrefslogtreecommitdiff
path: root/src/util
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-09-03 13:00:17 +0000
committerChristian Grothoff <christian@grothoff.org>2012-09-03 13:00:17 +0000
commitd97c5e23d256db8c2d1249c20a7d0e5714350b53 (patch)
treecc1e1d090498ade190991b6d8f1aaa5f2e75c1dd /src/util
parent9d99db63729a6143186b9b5b39bdb60e77b19c31 (diff)
downloadgnunet-d97c5e23d256db8c2d1249c20a7d0e5714350b53.tar.gz
gnunet-d97c5e23d256db8c2d1249c20a7d0e5714350b53.zip
always allow root
Diffstat (limited to 'src/util')
-rw-r--r--src/util/service.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/util/service.c b/src/util/service.c
index af0d0769a..e2d056d7f 100644
--- a/src/util/service.c
+++ b/src/util/service.c
@@ -660,10 +660,12 @@ check_access (void *cls, const struct GNUNET_CONNECTION_Credentials *uc,
660 if (GNUNET_YES == sctx->match_uid) 660 if (GNUNET_YES == sctx->match_uid)
661 { 661 {
662 /* UID match required */ 662 /* UID match required */
663 ret = (NULL != uc) && (uc->uid == geteuid ()); 663 ret = (NULL != uc) && ( (0 == uc->uid) || (uc->uid == geteuid ()) );
664 } 664 }
665 else if ( (GNUNET_YES == sctx->match_gid) && 665 else if ( (GNUNET_YES == sctx->match_gid) &&
666 ( (NULL == uc) || (uc->uid != geteuid ()) ) ) 666 ( (NULL == uc) ||
667 ( (0 != uc->uid) &&
668 (uc->uid != geteuid ()) ) ) )
667 { 669 {
668 /* group match required and UID does not match */ 670 /* group match required and UID does not match */
669 if (NULL == uc) 671 if (NULL == uc)