umask() COHERENT System Call umask() Set file creation mask int umask(mask) int mask; umask allows a process to restrict the mode of files it creates. Commands that create files should specify the maximum reasonable mode. A parent (e.g. the shell sh) usually calls umask to restrict access to files created by subsequent commands. mask should be constructed from any of the permission bits found in chmod (the low-order nine bits). When a file is created with creat or mknod, the bits specified by mask are zeroed in mode; thus, bits set in mask specify permissions which will be denied. umask returns the old value of the file creation mask. ***** See Also ***** COHERENT system calls, creat(), mknod(), sh COHERENT Lexicon Page 1