2016-04-19 22:24:32 +01:00
|
|
|
# umask
|
|
|
|
|
|
|
|
> Manage the read/write/execute permissions that are masked out (i.e. restricted) for newly created files by the user.
|
2021-10-19 21:20:43 +01:00
|
|
|
> More information: <https://manned.org/umask>.
|
2016-04-19 22:24:32 +01:00
|
|
|
|
|
|
|
- Display the current mask in octal notation:
|
|
|
|
|
|
|
|
`umask`
|
|
|
|
|
|
|
|
- Display the current mask in symbolic (human-readable) mode:
|
|
|
|
|
|
|
|
`umask -S`
|
|
|
|
|
|
|
|
- Change the mask symbolically to allow read permission for all users (the rest of the mask bits are unchanged):
|
|
|
|
|
|
|
|
`umask {{a+r}}`
|
|
|
|
|
|
|
|
- Set the mask (using octal) to restrict no permissions for the file's owner, and restrict all permissions for everyone else:
|
|
|
|
|
|
|
|
`umask {{077}}`
|