Questions tagged [umask]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer
793 views

ubuntu change default files and folders permission

i have ubuntu 10.04 on my server. when i was create a file by ftp, php and ... files permission is 600 and folders is 700. how can i change default files permission into 644 and folders to 755? ...
user avatar
1 vote
1 answer
2k views

CentOS - Apache - Is it possible to add umask directive to httpd.conf or vhost.conf file?

Yesterday, I was finally able to get my apache process to write files to a directory by setting the umask to 002 in the /etc/sysconfig/httpd script, but I was wondering if it's possible to set this ...
Mike Purcell's user avatar
  • 1,738
15 votes
2 answers
29k views

Can I override my umask using ACLs to make all files created in a given directory world readable?

Assume that my umask is 0077. I have a directory, foo, that I want to have special permissions applied to it. All files I create in foo should be world readable, and all directories should be world ...
stickmangumby's user avatar
4 votes
2 answers
3k views

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 ...
Belmin Fernandez's user avatar
1 vote
1 answer
674 views

Modifying umask for all users not functioning

I have modified /etc/login.defs and set the umask to 002 but it fails to be changed when I exit or logout and log back in. My bashrc file does NOT contain any umask settings. from /etc/login.defs # ...
Ben's user avatar
  • 3,880
0 votes
2 answers
1k views

Setting umask /etc/apache2/envvar not working Ubuntu 10.04 [duplicate]

I am trying to set the default umask to umask 002. I tried adding it to: /etc/apache2/envvar /etc/profile But after restarting Apache it hasn't changed? Still 0022. Where do I have to put it? ...
Bob's user avatar
  • 1
0 votes
1 answer
1k views

Change syslog log file's owner/group?

Is there a way to have syslog create a log file that's not owned by root? I've got several jboss application servers that I've got logging to a server. Everyone's running CentOS. Right now, all of ...
David's user avatar
  • 103
1 vote
2 answers
3k views

Setting umask 002 for the apache, lighttpd, ... didn't work?

I'm trying to make the files that created by webserver (Apache, lighttpd, ...) can be writable by the ftp users. Adding apache to nobody group and the vise versa. umask 002 for ftp works fine. But the ...
quanta's user avatar
  • 51.8k
3 votes
1 answer
2k views

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, ...
JDS's user avatar
  • 2,628
3 votes
2 answers
521 views

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, ...
Spacen Jasset's user avatar
2 votes
2 answers
325 views

umask in Ubuntu Server 10

This is on a test machine, not production. I included the following in a user's .bashrc: umask 000 I relogged in. When I go to create a file in my home directory, say using vi test.txt, the file ...
djdy's user avatar
  • 583
0 votes
1 answer
1k views

Per-user umask over all ssh connections

Following on from How to setup ssh's umask for all type of connections Is it possible to do this on a per-user basis? Here's what I have at the minute: /etc/pam.d/ssh sesssion optional pam.umask....
The Pixel Developer's user avatar
0 votes
2 answers
1k views

In Linux, how do I umask differently for files and directories?

I wish to have something in my .bashrc that will mask the file permissions as 022 (resulting in new files having permission rwxr--r--) and the directory permissions as 066 (resulting in new ...
Cody's user avatar
  • 1
3 votes
1 answer
5k views

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, ...
Alan W. Smith's user avatar
1 vote
1 answer
247 views

Changing default permssion on ubuntu 10.4 server

I have a a Joomla CMS which is a PHP script that needs to write new files and directories, I changed the umask value and I ended up re-installing the system :-s. Can you please guide me step by step ...
Sakhar's user avatar
  • 11
2 votes
1 answer
4k views

Set default umask for everything in Debian Squeese, included sftp

How can I change the umask for ssh and sftp in debian squeeze. I have changed the umask from 022 to 002 in /etc/profile and /etc/login.defs and modified Subsystem sftp /usr/lib/openssh/sftp-...
user68802's user avatar
  • 203
0 votes
2 answers
948 views

wrong "permission denied" in linux?

root@SERVER:~# cat /etc/passwd | grep www-data www-data:x:33:33:www-data:/var/www:/bin/sh root@SERVER:~# ls -al /cluster/www/html/tmp/reportexport_274.xml -rwxrwxrwx 1 www-data www-data 908 2011-03-...
Fivetide's user avatar
0 votes
2 answers
2k views

Default File Permissions (Passenger, Rails, Ubuntu Server)

I've deployed a Rails application that is using page caching and is run via Passenger on Ubuntu Server. Rails caching simply uses Ruby's File.open to write the cached files. Unfortunately these files ...
lipsum123483's user avatar
0 votes
1 answer
682 views

Home folder permission in Ubuntu for apache public_html

I read a lot about that here, but I guess I just can't get it. So here is what I got: I have Ubuntu 10.04 installed and I just created vhost for a domain, let's call it example.com. I also created a ...
John Gold's user avatar
13 votes
4 answers
18k views

How to get full control of umask/PAM/permissions?

// Updated Feb 8 - Outstanding issues in brief: How to umask directories differently from files? How to umask on Nautilus copy/paste? How to set umask for SSHFS? OUR SITUATION Several people from ...
user avatar
38 votes
10 answers
68k views

How to setup ssh's umask for all type of connections

I've been searching for a way to setup OpenSSH's umask to 0027 in a consistent way across all connection types. By connection types I'm referring to: sftp scp ssh hostname ssh hostname program The ...
Unode's user avatar
  • 493
1 vote
2 answers
906 views

Apache 2.2 umask in FreeBSD

I have Apache 2.2 running under FreeBSD 7 (and 8). It runs with the system default umask of 022, and I need it to be 002 so that www group members can make changes without having to chase it with ...
dukeOfOak's user avatar
2 votes
1 answer
4k views

Setting default file permissions in shared directory using ACL and umask

We have a Linux box running Ubuntu 10.04. It's primary function is a web server and it is configured with (I think) a conventional LAMP stack. Developers have access to a common directory "dev" which ...
duncmc's user avatar
  • 175
2 votes
1 answer
343 views

Is it possible to avoid umask 0002?

Is it possible to give an automatic ability to modify files(folders and all recursively) created by one user to another within one specified folder (let's say "shared") on the basis of both users ...
Anatoly's user avatar
  • 21
16 votes
2 answers
114k views

Default owner/permissions of created files via VSFTPD

How do I set the default values of directories and files created to be 775 ? My understanding is that I need to modify the umask on VSFTPD, but how do I know what to change it to?
Ben's user avatar
  • 3,880
4 votes
3 answers
7k views

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 ...
kayahr's user avatar
  • 313
1 vote
2 answers
2k views

vsftpd seems to disreguard umask

I configured my vsftpd to allow virtual users to upload file. However I wanted all uploaded files to not be downloadable, thus depriving a potential attacker the usefulness of storing his nefarious ...
Chen Levy's user avatar
  • 283
8 votes
3 answers
19k views

Ways to set umask on Ubuntu for daemon processes

I have an http daemon server process (yaws) that I would like to have server write any new files with a umask of 002, so that another user in the same group can modify, move, or delete files created ...
mp3foley's user avatar
  • 618
2 votes
2 answers
8k views

Understanding Permissions with ProFTPD (Especially Group Write)

I have proftpd running under user proftpd. I have a new virtual server in ProFTPD called "example.com" pointing to /var/www/example.com. I have chowned the /var/www/example.com folder with user "...
ServerChecker's user avatar
16 votes
2 answers
32k views

How do I set default permissions for SFTP for an Ubuntu Server?

We have an Ubuntu 10.04 server. How can I set it so that new files created (or copied) over SFTP or SSH have g+rw and g+rwx permissions (where appropriate)? I'm also using setgid (chmod g+s) so that ...
wag2639's user avatar
  • 2,165
2 votes
2 answers
8k views

Apache umask 002 not changing permissions

I have used [root ~]$ echo "umask 002" >> /etc/sysconfig/httpd [root ~]$ service httpd restart restarted apache many times but whenever i install something from script the directories are ...
user avatar
4 votes
1 answer
1k views

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's user avatar
  • 425
0 votes
2 answers
861 views

Proper umask on linux webservers?

Most VPS have a team of 1+ user(s) that don't do anything but configure the system and work on the web site and/or database. I would assume all the team members would be a group like "developers" so ...
Xeoncross's user avatar
  • 4,539
1 vote
1 answer
282 views

All users of a group can edit each others files (Linux)

I want anyone in group www-data to have write access to /var/www. For example, if 'a' and 'b' are in group www-data and 'a' creates a file in /var/www - then 'b' will be able to edit it. The problem ...
Xeoncross's user avatar
  • 4,539
4 votes
2 answers
7k views

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; <?php file_put_contents("./file.txt",""); then apache creates this file without write permission to the group, -rw-r--r-- 1 www-data ...
Devrim's user avatar
  • 1,187
16 votes
4 answers
26k views

Specify default group and permissions for new files in a certain directory

I have a certain directory in which there is a project shared by multiple users. These users use SSH to gain access to this directory and modify/create files. This project should only be writeable to ...
mislav's user avatar
  • 263

1
2