Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
NEWGRP(1)               FreeBSD General Commands Manual              NEWGRP(1)

NAME
     newgrp -- change to a new group

SYNOPSIS
     newgrp [-l] [group]

DESCRIPTION
     The newgrp utility creates a new shell execution environment with modi-
     fied real and effective group IDs.

     The options are as follows:

     -l      Simulate a full login.  The environment and umask are set to what
             would be expected if the user actually logged in again.

     If the group operand is present, a new shell is started with the speci-
     fied effective and real group IDs.  The user will be prompted for a pass-
     word if they are not a member of the specified group.

     Otherwise, the real, effective and supplementary group IDs are restored
     to those from the current user's password database entry.

EXIT STATUS
     The newgrp utility attempts to start the shell regardless of whether
     group IDs were successfully changed.

     If an error occurs and the shell cannot be started, newgrp exits >0.
     Otherwise, the exit status of newgrp is the exit status of the shell.

SEE ALSO
     csh(1), groups(1), login(1), sh(1), su(1), umask(1), group(5), passwd(5),
     environ(7)

STANDARDS
     The newgrp utility conforms to IEEE Std 1003.1-2001 (``POSIX.1'').

HISTORY
     A newgrp utility appeared in Version 6 AT&T UNIX.

BUGS
     Group passwords are inherently insecure as there is no way to stop users
     obtaining the crypted passwords from the group database.  Their use is
     discouraged.

FreeBSD 6.2                      May 23, 2002                      FreeBSD 6.2

NAME | SYNOPSIS | DESCRIPTION | EXIT STATUS | SEE ALSO | STANDARDS | HISTORY | BUGS

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=newgrp&sektion=1&manpath=FreeBSD+6.2-RELEASE>

home | help