When a process creates a new file, it specifies the permissions that it
would like the new file to have. Often, the mode requested is
0666 (readable and writable by everyone), which is more permissive
that we would like. Fortunately, Linux consults something called a "umask"
whenever a new file is created. The system uses the umask value to reduce the
originally-specified permissions to something more reasonable and secure. You
can view your current umask setting by typing umask at the command
line:
$ umask
0022
On Linux systems, the umask normally defaults to 0022, which
allows others to read your new files (if they can get to them) but not modify
them.