summaryrefslogtreecommitdiff
path: root/daemon/slave.c
diff options
context:
space:
mode:
authorJulio M. Merino Vidal <jmmv@NetBSD.org>2006-05-01 22:51:57 +0000
committerBrian Cameron <bcameron@src.gnome.org>2006-05-01 22:51:57 +0000
commita9e30a48a0d1d3355c086fc130588624326455c0 (patch)
tree8e91d7d22fbb0ca297f668fd48166aede70131f3 /daemon/slave.c
parent6d0c4c19c07d522b5692b8365057c1b478be4794 (diff)
downloadgdm-a9e30a48a0d1d3355c086fc130588624326455c0.tar.gz
Explicitly adjust the effective GID before running the child session
2006-05-01 Julio M. Merino Vidal <jmmv@NetBSD.org> * daemon/slave.c: Explicitly adjust the effective GID before running the child session program. Otherwise it remains with high privileges. The problem was exposed under NetBSD.
Diffstat (limited to 'daemon/slave.c')
-rw-r--r--daemon/slave.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/daemon/slave.c b/daemon/slave.c
index c160c390..310c5554 100644
--- a/daemon/slave.c
+++ b/daemon/slave.c
@@ -3543,6 +3543,7 @@ session_child_run (struct passwd *pwent,
close (iceauth_fd);
}
+ NEVER_FAILS_setegid (pwent->pw_gid);
#ifdef HAVE_LOGINCAP
if (setusercontext (NULL, pwent, pwent->pw_uid,
LOGIN_SETLOGIN | LOGIN_SETPATH |