How can i make user always create files + folders with 775 permission ? Please help
Hello,
I am trying to achieve the following on Debian, i need to have testuser create all his files + folders with 775 permission, everything this user creates i would like for it to have that permission. I would be VERY appreciative if someone could tell me how to do this. --- What will also work would be some way i could set a folder to always have that permission no matter what is written in it and by who. |
Have a look at umask.
|
Quote:
Reading about it but still no luck so far. |
Read some more?
|
in the users .bash_profile or .bashrc file add the line:
Code:
umask 0002 |
Thank you for your replies.
I have umask 0002 If i create a new file via SFTP, it gets permission 0644 rw-r--r-- , i also need write for the group so it didnt do the trick :(. |
Quote:
this is a REMOTE login that should have been posted in the very first post and NOT just finding this out in post #6 what software are you using and what is the host? and you REALLY DO NOT !!!!! want remote users using 775 |
Quote:
|
Quote:
-- So, i have 2 users, we'll call them user1 and user2. User1 will have access to SFTP + SSH, user2 will have access only to FTP. If user1 creates a file, user2 will not have write permission for that file when connected to FTP. I need to give user2 write access to the file, how can i do this? |
Quote:
|
Quote:
Quote:
|
Quote:
|
Hello
Maybe this has to do with SFTP? If the idea is that they can transfer files but not run scripts, I think you need to put the umask in the sshd config. http://riaschissl.bestsolution.at/20...mask-for-sftp/ |
Quote:
user1:x:1000:user2 user2:x:1001:user1 Should i change something ? hmm. Maybe they are not added correctly ? |
Quote:
Quote:
|
All times are GMT -5. The time now is 02:05 AM. |