[0m


UMASK(1)	    UNIX Programmer's Manual		 UMASK(1)



[1mNAME
     [0mumask - set file creation mode mask

[1mSYNOPSIS
     umask [0m[ _o_o_o ]

[1mDESCRIPTION
     [0m_U_m_a_s_k sets the access control mask used by the shell and
     commands invoked from it whenever a new file is created.  If
     no argument is given the current mask is printed (as an
     octal number).  The argument is an octal number which
     becomes the current mask.

     The mask specifies file access mode bits from the base set
     777 which will [1mnot [0mbe set when a new file is created.  The
     bits specify read, write and execute access (in that order)
     for access by the file owner, a member of the file group and
     anyone else (in that order).  Thus:

     [1m700  [0mThe bits controlling access by the file owner.

     [1m070  [0mThe bits controlling access by a user who is not the
	  file owner but is in the group of the file (see _l_s(1)
	  option [1m-lg [0mor _l_s(1v) option [1m-l[0m).

     [1m007  [0mThe bits controlling access by anyone else.

     Similarly:-

     [1m444  [0mThe bits controlling read access.

     [1m222  [0mThe bits controlling write access.

     [1m111  [0mThe bits controlling execute access.

     In use the mask is used to remove access bits from the
     access requested by an _o_p_e_n(2) system call which creates a
     file.  Normally programs request an access of _6_6_6 for data
     files and _7_7_7 for executable files.  Thus a mask of _0_2_2 (the
     default) will cause data files to have access _6_4_4; owner
     read/write and group/other read-only.

     The umask value is inherited by any command run, directly or
     indirectly, from the shell.  On systems where group write
     access is required to be the default it is normal for users
     to place the command:

	  [1mumask 2

     [0min their ._l_o_g_i_n (_c_s_h(1)) or ._p_r_o_f_i_l_e (_s_h(1)).





Printed 11/2/93     Revision 1.1 of 15/10/90			1






UMASK(1)	    UNIX Programmer's Manual		 UMASK(1)



[1mSEE ALSO
     [0m_s_h(1), _c_s_h(1), _l_s(1), _l_s(1v), _o_p_e_n(2), _u_m_a_s_k(2).





















































Printed 11/2/93     Revision 1.1 of 15/10/90			2



[0m