Comment 13 for bug 152879

Revision history for this message
Holger Berndt (berndth) wrote :

The bug description reveals a misunderstanding of the permissions system. File creation and deletion are operations on the _containing directory_ and are affected by the permissions set on that directory. You can create and delete files if you have +w on the parent directory. File permissions, on the other hand, don't have any influence on that.

As a consequence the statement
> You have to be the owner of the file to do this.
is wrong, too. Try it: Create a file with permissions 400 and owner "root" in your home directory. You will be able to delete it even as a normal user. I repeat: This is not a bug, but the way unixoid permissions work.

In addition, this behavior is completely consistent with the permission display in Nautilus when the "show_advanced_permissions" switch is off.

Now, since that seems to be a common misunderstanding, the GNU project decided to add a warning for that special case to 'rm'. However, that is clearly an enhancement request, and not a bug.