Changing to a limited set of IDs is interesting, I have never looked at
what happens when a thread does setuid, and neither the man page or a
very quick look at the code tells me. But the portable way is to do the
things needed for init, then fork into three processes and give each a
UID as needed. I would really evaluate the design which made this
necessary, to see if some IPC could be used. Certainly that's more
likely to be portable.
--
Bill Davidsen <davidsen@tmr.com>
"We have more to fear from the bungling of the incompetent than from
the machinations of the wicked." - from Slashdot
-