Lines Matching refs:setuid
1303 if (setuid(new_uid) < 0)
1305 syserr("main: setuid(%d) failed", (int) new_uid);
2919 (void) setuid(RealUid);
3048 (void) setuid(RealUid);
3681 ** EX_OSERR if the setuid failed.
3792 ** Try to setuid(RunAsUid).
3798 if (setuid(RunAsUid) < 0 ||
3807 ** setuid() to drop the saved-uid as well.
3818 if (setuid(RunAsUid) < 0)
3820 syserr("drop_privileges: second setuid(%d) attempt failed",
3828 syserr("drop_privileges: setuid(%d) failed",
3834 if (RunAsUid != 0 && setuid(0) == 0)
3838 ** allows a non-root process to override setuid()
3843 syserr("drop_privileges: setuid(0) succeeded (when it should not)");
3846 else if (RunAsUid != euid && setuid(euid) == 0)
3850 ** if a non-root effective-uid calls setuid(real-uid)