summaryrefslogtreecommitdiff
path: root/anzeige.c
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2018-11-05 10:16:58 +0100
committerErich Eckner <git@eckner.net>2018-11-05 10:16:58 +0100
commitc70beb248690bf741fc64907de35aa3b947120b4 (patch)
tree3015031f7c9c3dcafd1d197fe933e5d7d0b39192 /anzeige.c
parent92f4cff100202c5ca654d1461f46c50148cd151a (diff)
downloadanzeige-c70beb248690bf741fc64907de35aa3b947120b4.tar.xz
nobodies uid and gid changed
Diffstat (limited to 'anzeige.c')
-rw-r--r--anzeige.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/anzeige.c b/anzeige.c
index 7c7071d..5ac1fab 100644
--- a/anzeige.c
+++ b/anzeige.c
@@ -147,12 +147,12 @@ void drop_privileges()
int is_already_unprivileged = 0;
- if (setgid(99) == -1) {
+ if (setgid(65534) == -1) { // nobody
perror("can't drop group privileges");
if (! (is_already_unprivileged = (errno == 1)))
exit(-1);
}
- if (setuid(99) == -1) {
+ if (setuid(65534) == -1) { // nobody
perror("can't drop user privileges");
if (is_already_unprivileged != (errno == 1))
exit(-1);