Joshua C. wrote:
2009/1/19 Ralf Ertzinger <fedora@xxxxxxxxxxxxxx>:
This has been the way of UNIX since the dawn of time. Deleting a file
is a directory operation, so the permissions on the directory apply,
not the permissions on the file.
You should not be able to modify the file in place, however (but
you could delete it and create a new one, which would be owned by
you and not root).
I think this concers only deleting a file. But I shouldn't be allowed
to rename it, should I? in kde3 I couldn't delete those files. why?
Renaming in unix-like file systems is equivalent to linking the file
into the directory with a new name and then removing the old one.
Still a directory level operation.
Try this:
[bmr@bmr ~]# su -
Password:
[root@bmr bmr]# umask 066
[root@bmr bmr]# touch pony
[root@bmr bmr]# su - bmr
[bmr@bmr ~]$ mv pony not-yours
[bmr@bmr ~]$ ll not-yours
-rw------- 1 root root 0 2009-01-19 19:08 not-yours
[bmr@bmr ~]$ cat not-yours
cat: not-yours: Permission denied
[bmr@bmr ~]$ rm not-yours
rm: remove write-protected regular empty file `not-yours'? y
[bmr@bmr ~]$ ll not-yours
ls: cannot access not-yours: No such file or directory
I can move (rename), or delete, but not access this file.
Regards,
Bryn.
--
fedora-devel-list mailing list
fedora-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-devel-list