1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 15:07:45 +00:00

usermod: Use LibCore syscall wrapper for setegid()

This commit is contained in:
Andreas Kling 2021-12-16 19:32:01 +01:00
parent ad37ca4815
commit 99eaeedf4e

View file

@ -21,10 +21,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
return 1;
}
if (setegid(0) < 0) {
perror("setegid");
return 1;
}
TRY(Core::System::setegid(0));
TRY(Core::System::pledge("stdio wpath rpath cpath fattr tty"));
TRY(Core::System::unveil("/etc", "rwc"));