Florian Coulmier
2009-03-17 11:14:54 UTC
Hello,
I have a proftpd 1.3.1 on a linux server that I use in production
environnement. My default umask is 0027, wich create files in 640 mode
and directories in 750 mode.
However, for some directories, I need a 0007 umask, to add group write
to files and directories created (in my case, the group is apache).
Everything work fine when I use this configuration :
<Directory /usr/local/user/dir1>
umask 0007 0007
</Directory>
What I mean by "everything work fine" is that :
- When I create directory /usr/local/user/dir1, it has mode 770 (OK).
- When I create directory /usr/local/user/dir1/sdir1, it also has mode
770 (OK).
- When I create file /usr/local/user/dir1/sdir1/file1, it has mode 660
(OK).
But, I have some problems with umask when I use globing in the
directory directive :
<Directory /usr/local/*/dir1>
umask 0007 0007
</Directory>
With this configuration, I have the following problems :
- When I create directory /usr/local/user/dir1, it has mode 770 (OK).
- When I create directory /usr/local/user/dir1/sdir1, it has mode 750
(NOT OK).
- When I create file /usr/local/user/dir1/sdir1/file1, it has mode 640
(NOT OK).
It seems that the umask is not applied recursively when globing is
used in the "Directory" section.
It is very important for me to make the umask directive work with
globing. Has anyone else already encountered this problem and managed
to solve it or found a workarround ?
Thanks for your help.
Florian Coulmier
I have a proftpd 1.3.1 on a linux server that I use in production
environnement. My default umask is 0027, wich create files in 640 mode
and directories in 750 mode.
However, for some directories, I need a 0007 umask, to add group write
to files and directories created (in my case, the group is apache).
Everything work fine when I use this configuration :
<Directory /usr/local/user/dir1>
umask 0007 0007
</Directory>
What I mean by "everything work fine" is that :
- When I create directory /usr/local/user/dir1, it has mode 770 (OK).
- When I create directory /usr/local/user/dir1/sdir1, it also has mode
770 (OK).
- When I create file /usr/local/user/dir1/sdir1/file1, it has mode 660
(OK).
But, I have some problems with umask when I use globing in the
directory directive :
<Directory /usr/local/*/dir1>
umask 0007 0007
</Directory>
With this configuration, I have the following problems :
- When I create directory /usr/local/user/dir1, it has mode 770 (OK).
- When I create directory /usr/local/user/dir1/sdir1, it has mode 750
(NOT OK).
- When I create file /usr/local/user/dir1/sdir1/file1, it has mode 640
(NOT OK).
It seems that the umask is not applied recursively when globing is
used in the "Directory" section.
It is very important for me to make the umask directive work with
globing. Has anyone else already encountered this problem and managed
to solve it or found a workarround ?
Thanks for your help.
Florian Coulmier