Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!seismo!sundc!pitstop!sun!amdcad!ames!ll-xn!husc6!cmcl2!edler From: edler@cmcl2.NYU.EDU (Jan Edler) Newsgroups: comp.unix.wizards Subject: umask and multiple groups Message-ID: <21241@cmcl2.NYU.EDU> Date: Thu, 5-Nov-87 11:32:06 EST Article-I.D.: cmcl2.21241 Posted: Thu Nov 5 11:32:06 1987 Date-Received: Sun, 8-Nov-87 03:34:36 EST Reply-To: edler@cmcl2.UUCP (Jan Edler) Organization: New York University, Ultracomputer project Lines: 28 In 4.[23]bsd, when you create a file, the gid of the file is taken from the gid of the directory you create it in (even if you aren't a member of that group). It seems to me that the single umask(2) mechanism is crippled in this environment. If I work in several different groups, and I don't want my files in each group created with the same group permissions, I have to change the umask every time I switch back and forth between working on different groups; a situation akin to that which motivated the establishment of multiple groups in the first place (elimination of the newgrp command). The only alternatives I can think of are: - Allow a separate umask in the kernel for each group a user is a member of. An extra umask would also be needed for groups that the user is not a member of. - Add a file mode mask to each directory, to apply for all files created there. With either of these alternatives, the existing umask could remain as well, so that the mode of a newly created file would be influenced by two masks; this would help make either change upward compatible, since users happy with the old semantics could just ignore the new masks (leave them 0). Any thoughts on this? Other ideas? Does everyone think things are fine the way they are? Were multiple groups a bad idea? Jan Edler edler@nyu.nyu.edu ...!cmcl2!edler