Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 30 May 96 16:18:56 EDT
From:      eischen@vigrid.com (Daniel Eischen)
To:        kuku@gilberto.physik.rwth-aachen.de, michaelv@HeadCandy.com
Cc:        freebsd-hackers@freefall.freebsd.org
Subject:   Re: newgrp(1)
Message-ID:  <9605302018.AA11531@pcnet1.pcnet.com>

next in thread | raw e-mail | index | archive | help
> >  The newgrp command changes the primary group identification of the current
> >  shell process to group.  You remain logged in and the current directory is
> >  unchanged, but calculations of access permissions to files are performed
> >  with respect to the primary group ID.
> 
> This is a SysV-ism.  If I'm not mistaken, SysV needs this because you
> can only be in one group at a time.  This means you need to constantly
> newgrp to change group access permissions if you're moving among
> multiple groups.
> 
> BSD allows you to be in multiple groups at the same time, so makes
> this command pretty much unnecessary.
> 
> This is how I understand it, anyway.  I'm sure someone will correct me
> if I'm wrong...

The problem is not when you want to reference files that already exist,
but when you want to create files with a specific group so that only
others in that group can reference them.

We use the newgrp command on our HP systems for various projects with
multiple developers.  Each project usually usually has at least one
group associated with it.  By using newgrp before we start any processes
that can create files, we're assured that the files have the correct
permissions (group).  GUI-based systems, like Interleaf, Atria ClearCase,
compilers, etc, can then be used to create files with the correct group.
This is really important when you're not granted root permissions on
the systems; you can't hunt around and manually set the group on all
files in the project directory because you don't own them.

Unless there's another way of doing this in FreeBSD, I'd like to see
the newgrp command brought in.  My $.02.

Dan Eischen
eischen@pcnet.com



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9605302018.AA11531>