sys: don't start privops helper for NTS-KE helper

The NTS-KE helper doesn't need to bind sockets or adjust the clock.
Don't start the privops helper, or keep the capabilities, when dropping
root privileges in its context.
This commit is contained in:
Miroslav Lichvar
2020-10-05 18:14:23 +02:00
parent a96d288027
commit 8e9716d5d4
4 changed files with 10 additions and 3 deletions

View File

@@ -57,7 +57,8 @@ SYS_Solaris_Finalise(void)
void
SYS_Solaris_DropRoot(uid_t uid, gid_t gid, SYS_ProcessContext context)
{
PRV_StartHelper();
if (context == SYS_MAIN_PROCESS)
PRV_StartHelper();
UTI_DropRoot(uid, gid);
}
#endif