What does SUID, SGID and Sticky bits do on inappropriate files?

Sean Eric Fagan sef at kithrup.COM
Fri Dec 28 17:12:46 AEST 1990


In article <1990Dec26.011025.4186 at NCoast.ORG> allbery at ncoast.ORG.ORG (Brandon S. Allbery KB8JRR) writes:
>Some SCO Xenix, SCO "UNIX", and possibly SVR3.2 use setgid on non-executables
>to indicate that normally cooperative file locking should actually be
>mandatory.  The SCO "UNIX" systems at work do not use g+s on files, however;
>the command used is "chown +l".

This is defined by the SVID, actually.  I forget which version (I *think* 2,
but am not certain, since I don't have a copy at home).  As for the g+s vs.
+l (the 'l' stands for 'mandatory locking', as is intuitively obvious 8-)),
I think that was put in as a safety measue.  (Don't know that sco put it in,
mind you... could have been at&t.)

>SunOS and maybe other Unixes use g+s on a directory to produce sticky gid's:
>files created in the directory inherit the directory's gid instead of the
>creating process's egid.

Wow.  SCO does that too (just checked).  Neat... 8-)  (I *honestly* didn't
know it did it!  *Really*!)

-- 
Sean Eric Fagan  | "I made the universe, but please don't blame me for it;
sef at kithrup.COM  |  I had a bellyache at the time."
-----------------+           -- The Turtle (Stephen King, _It_)
Any opinions expressed are my own, and generally unpopular with others.



More information about the Comp.unix.internals mailing list