Aucbvax.4475
fa.unix-wizards
utzoo!decvax!ucbvax!unix-wizards
Thu Oct 15 23:32:12 1981
Re: double setuid programs
>From Mike.Accetta@CMU-10A Thu Oct 15 20:34:13 1981
Mark,

   setuid(geteuid()) has been allowed (in VM/UNIX at least) for as
long as I can remember.  Note the second line of setuid(2) in the 4.0/1
manual:

       "... These calls are only permitted to the super-user or if the
       argument is the real or effective ID."

Checking back to the original 32V manual does reveal that this is
indeed not the case in 32V.  I have actually used setuid(geteuid()) for
purposes similar to what you mention and have come across no problems
(a swap effective/real id call would still be nice, though).

                               - Mike

-----------------------------------------------------------------
gopher://quux.org/ conversion by John Goerzen <[email protected]>
of http://communication.ucsd.edu/A-News/


This Usenet Oldnews Archive
article may be copied and distributed freely, provided:

1. There is no money collected for the text(s) of the articles.

2. The following notice remains appended to each copy:

The Usenet Oldnews Archive: Compilation Copyright (C) 1981, 1996
Bruce Jones, Henry Spencer, David Wiseman.