Understanding parent directory permissions and ownership?
If a parent directory is owned, for example, by root:root inside the directory a user that don't have sudo rights can't create files and folders. But if i user with sudo rights create folders and files inside the directory and change the ownership of the files and folders to the user with no sudo rights the user with no sudo rights can't delete these files and folders but can change their permissions. Is this all the user with no sudo rights can do?
|
you mixed two different things. The permissions on files/directories and the sudo rights.
see man chmod for example about permissions or here: https://en.wikipedia.org/wiki/File_system_permissions |
One difference to remember between files and directories is that the execute bit for directories simply allows 'passing through' the given directory. So with the following settings you can pass through X and A but not B, but in no case actually list the files.
Code:
sudo mkdir -p /tmp/X/A/Y/ |
All times are GMT -5. The time now is 03:38 AM. |