Questions tagged [umask]
89 questions
4
votes
1 answer
SFTP-server uploaded files having wrong rights
I have been trying to figure out what is wrong with the file rights. When I am uploading files using FileZilla all the files get rights -rw-r--r--. I would want them to have -rwxr-xr-x. I have tried using umask to fix the rights but something is…

Firze
- 355
- 6
- 16
4
votes
3 answers
rsync pull disregards my umask, why?
My umask is 0002.
So when I rsync -r me@remote:new ., why aren't the results group-writable?
drwxrwsr-x 10 root developers 4096 Aug 22 12:55 .
drwxrwsr-x 12 root developers 4096 Jul 14 19:05 ..
drwxrwsr-x 3 root developers 4096…

Aaron Adams
- 333
- 2
- 10
4
votes
2 answers
Setting umask for all users
I'm trying to set the default umask to 002 for all users including root on my CentOS box.
According to this and other answers, this can be achieved by editing /etc/profile. However the comments at the top of that file say:
It's NOT a good idea to…

Yarin
- 1,366
- 8
- 19
- 31
4
votes
2 answers
How can I change the umask for a user when he logs on to an alternate group?
I want the umask to be more permissive for users when they switch to a non-default group. Just to demonstrate what I mean:
$ id
uid=500(beamin) gid=500(beamin) groups=10(wheel)
$ umask
0022
$ sg wheel
$ umask # I want this to now be 0002…

Belmin Fernandez
- 10,799
- 27
- 84
- 148
4
votes
3 answers
Conflicts between ACLs and umask
I have a directory which can be read and written by a couple of unix groups. This is achieved by using ACLs. Let's assume I did it like this:
mkdir /tmp/test
setfacl -d -m g:group1:rwx /tmp/test
Works great, the whole group (And other groups I add…

kayahr
- 313
- 4
- 14
4
votes
1 answer
Howto force umask 002 for all software?
I have added umask 002 to /etc/profile, but software like git and apache still sets files to 755 instead of 775. Is there a way to force umask 002 for all programs on a machine?

grm
- 425
- 2
- 4
- 10
4
votes
2 answers
How can I give default group write permission to a file created by www-data?
our apache runs as www-data:psacln
if this line is run;

Devrim
- 1,187
- 4
- 16
- 29
3
votes
1 answer
debian internal-sftp -u 0002 umask does not work correctly - execute permission missing
I've been searching here and but I could not find similar question.
I have set up SSH and sftp server on debian 7, the problem is that the umask is applied without execute permissions. Even if I change the different value, execute permissions are…

oglop
- 251
- 3
- 8
3
votes
1 answer
Which umask is more secure in Linux ( 022 or 027)?
Is there any security concerns if the umask is set to 027 for root (Basically I want to know if 027 is better in security than 022 ) ?
As per my understanding 027 is a better one from security perspective . But I want to confirm this point .

Mathews Jose
- 161
- 1
- 2
- 9
3
votes
1 answer
NFSv3 + ACL: mask is gone on clients
I'm sharing a NFS folder among a user group. The default umask on the clients is 0700, and this is a problem because newly created files won't be readable/writable by another users.
So, I'm using ACLs to force the umask 0770 on the shared folder,…

Jorge Suárez de Lis
- 391
- 8
- 22
3
votes
1 answer
Increasing permissiveness/permissions for umask + openssh + chrooted SFTP server using internal-sftp
The suggestion found at these links works for me:
How to setup ssh's umask for all type of connections
http://ubuntuforums.org/showthread.php?t=1107974#5
Summary: Use PAM to inject the umask, using the following line in /etc/pam.d/sshd
session …

JDS
- 2,598
- 4
- 30
- 49
3
votes
2 answers
Why is umask a AND NOT mask operation
Why is umask a $perms AND NOT $mask and not simply $perms AND $mask instead?
In other words why is there a NOT in there; why doesn't wasn't it implemented as an and mask?
As an example, 666 and 700, to give 600?

Spacen Jasset
- 244
- 1
- 8
3
votes
1 answer
Setting umask for www-data user (run via sudo) on Ubuntu 10.04 LTS
I run apache as user www-data on Ubuntu 10_04 LTS. I've got /etc/apache2/envvar setup with 'umask 002' so that any new files/dirs created by the daemon have group write permissions enabled. At times, I need to create files/dirs from the command line…

Alan W. Smith
- 249
- 1
- 4
- 10
2
votes
0 answers
nginx passenger, setting the umask
I was wondering how to set the umask for nginx or passenger or both processes. A search seems to only bring up Apache. Any help would be very much appreciated! (This is on Debian.)

Cenoc
- 217
- 1
- 12
2
votes
1 answer
Should usergroups be enabled?
All our users are managed with a central LDAP. When my predecessor in managing the infrastructure created the ldap he decided against creating usergroups (meaning groups of the same name and GID as the user(s UID)) and all users share one primary…

Clemens Bergmann
- 305
- 1
- 4
- 13