home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!auspex-gw!guy
- From: guy@Auspex.COM (Guy Harris)
- Newsgroups: comp.sys.sun.misc
- Subject: Re: Directories, set-guid?
- Message-ID: <15915@auspex-gw.auspex.com>
- Date: 15 Dec 92 22:46:39 GMT
- References: <BzAH8n.3wn@fafnir.com>
- Sender: news@auspex-gw.auspex.com
- Organization: Auspex Systems, Santa Clara
- Lines: 31
- Nntp-Posting-Host: auspex.auspex.com
-
- >What does a mode set-guid mean for a directory? I notice that our Sun
- >has most system directories, like /etc, set to mode 's' for group. The
- >man pages say this is possible but is ignored.
-
- Any SunOS 4.x man page that says that is incorrect.
-
- A not-necessarily-obvious man page that *doesn't* say that is OPEN(2V):
-
- O_CREAT If the file exists, this flag has no effect.
- Otherwise, the file is created, and the owner
- ID of the file is set to the effective user
- ID of the process. The group ID of the file
- is set to either:
-
- o the effective group ID of the process, if
- the filesystem was not mounted with the
- BSD file-creation semantics flag (see
- mount(2V)) and the set-gid bit of the
- parent directory is clear, or
-
- o the group ID of the directory in which the
- file is created.
-
- Other manual pages describing calls that create files should say much
- the same thing - i.e., that if the set-GID bit is set on a directory,
- creation of files in that directory follows 4.2andupBSD semantics for
- the group ID of the newly-created file, not "traditional UNIX"
- semantics.
-
- You can, of course, get 4.2andupBSD semantics *without* that bit being
- set, if you mount with the "grpid" option.
-