LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   rights/restrictions (https://www.linuxquestions.org/questions/linux-newbie-8/rights-restrictions-140488/)

Emanon 01-30-2004 04:02 PM

rights/restrictions
 
Is there any way to make a user able to write to a directory but not delete files in the directory? i'm running SuSE8.1 with reiserfs.
it would be even cooler if you know any way to get it to work over samba.

bstempi 01-30-2004 04:14 PM

I can't help you as far as the file permisions go, but i BELIEVE (it may be wrong) that you can use pam restriction to help you do this over SMB.

If you have the latest version of samba, there will be an availiabe option in the config file "obey pam restrictions = yes" (or no). Pam restrictions, if i remember correctly, applys the local users restrictions to them.

for example, if you have user 'eman', and he has a home dir '/home/eman', and his home directory is such that he can write but not delete, then applying the pam settings would also do the same thing over samba. when he tries to access the share with that user name, he will be able to write in it, but not delete anything. I may be totally wrong and talking out of my ass, so wait for someone else to verify this before you try. i hope this helps.

zaphod_es 01-30-2004 04:45 PM

By "write to a directory" do you mean create new files or edit existing ones. If the latter what you ask is default behaviour.

When a directory gives group permissions of r-x and the files in that directory have rwx group permissions the group members can edit files but neither create nor delete the files.

If you want users to be able to creat new files but not be allowed to delete them I cannot help you, it sounds illogical.

ZB


All times are GMT -5. The time now is 06:35 AM.