Drop group privileges before dropping user privileges when execing
This ensures that the saved-set-gid is also set, although this shouldn't matter in practice since we always call execve() soon after, which overwrites the saved-set-gid with the effective gid anyway.
This commit is contained in:
@@ -1620,8 +1620,8 @@ extern Window *BX_create_additional_screen (void)
|
||||
static char geom[32];
|
||||
int i;
|
||||
|
||||
setuid(getuid());
|
||||
setgid(getgid());
|
||||
setuid(getuid());
|
||||
setsid();
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user