mirror of
https://github.com/NixOS/nix.git
synced 2024-11-25 16:23:02 +00:00
* The gid should also match.
This commit is contained in:
parent
1c90fabccc
commit
8f58733ef1
@ -178,7 +178,7 @@ void switchToNixUser()
|
||||
#if SETUID_HACK
|
||||
|
||||
/* Don't do anything if this is not a setuid binary. */
|
||||
if (getuid() == geteuid()) return;
|
||||
if (getuid() == geteuid() && getgid() == getegid()) return;
|
||||
|
||||
/* Here we set the uid and gid to the Nix user and group,
|
||||
respectively, IF the current (real) user is a member of the Nix
|
||||
|
Loading…
Reference in New Issue
Block a user