UID of parent process
UID of parent process
- Subject: UID of parent process
- From: James Bucanek <email@hidden>
- Date: Fri, 17 Jun 2005 23:17:16 -0700
Greetings,
I would like to know if there is a straightforward way of obtaining the UID (or EUID) of the parent process.
getppid() gives me the PID of the parent process
getuid()/geteuid() gives me the UID of the current process
I want to know the UID of PPID.
Why: The tool I'm writing is a SetUID executable that will run as root when launched. I'd like for it to (normally) run under the UID of whatever process launched it, until such time that it actually needs to run as root.
--
James Bucanek <mailto:email@hidden>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden