Permissions and directories
I am trying to puzzle out a permission issue.
I have a partition with a mountpoint /mnt/documents /mnt/documents is of course owned by root and only root has write permission. I want users to be able to copy folders and files into /mnt/documents but they are not allowed to. Of course I could setup /mnt/documents/user/ with full user permissions but this seems like an unnecessary layer. I do not want to give users write permission for /mnt/documents because then they could potentially delete the directory. So how do I give users permission to copy to /mnt/documents/ without write permission for the /mnt/documents file itself? TIA |
EDIT: Didn't read well the first post, sorry
|
I think, you can setup the directory like /tmp so any users can write to that directory, but they can only handle their own files or directories, but not those owned by others.
Code:
$> ls -ld /tmp |
These are either backup files or shared files.
So setting up the directory as drwxrwxrwt should not case any problems with the directory itself being deletable by any user? |
Quote:
You can just create a /t directory in root, switch normal user do: "cd /t ; mkdir ttt; touch aa ; rm -rf /t" -> You will get permission deny for those that you have not ownership, only those that belongs to you gets deleted. The directory is not delete-able by any user, it is just write-able by any user. |
Thanks.
Alan |
You welcome. Glad to know this solved your problem.
|
All times are GMT -5. The time now is 05:10 PM. |