repo: ngircd action: commit revision: path_from: revision_from: e009ccbe66f67a4c5344d6a1f415c50b699765ad: path_to: revision_to:
commit e009ccbe66f67a4c5344d6a1f415c50b699765ad Author: Florian WestphalDate: Tue Aug 27 00:19:31 2013 +0200 ngircd: discard supplementary group ids on startup The intention was to switch to JUST uid:gid, but setgid is not sufficient. Reported-by: Michael Scherer diff --git a/src/ngircd/ngircd.c b/src/ngircd/ngircd.c
--- a/src/ngircd/ngircd.c
+++ b/src/ngircd/ngircd.c
@@ -724,6 +724,11 @@ NGIRCd_Init(bool NGIRCd_NoDaemon)
if (real_errno != EPERM)
goto out;
}
+ if (setgroups(0, NULL) != 0) {
+ Log(LOG_ERR, "Can't drop supplementary group ids: %s!",
+ strerror(errno));
+ goto out;
+ }
}
#endif
-----END OF PAGE-----