File Write Permission Rules
Steve Mawer
scm at datlog.co.uk
Mon Feb 13 22:40:32 AEST 1989
In article <306 at wubios.wustl.edu> david at wubios.wustl.edu (David J. Camp) writes:
>We have a strange situation where a program can write to a file even
>though it does not have write permission.
> I would have required write permission to
>the file itself in order that it be removed.
>-David-
I too, have thought this behaviour bizarre. However, the (logical) answer
is that deleting a file does *not* involve writing to it, only to the
directory. Therefore, if you can write to a directory, you can delete
the file.
If you want to protect your files, match the permissions of the file with
those of the directory. (I know this is not a good answer if you want
users to be able to *create* personal files in the directory.)
--
Steve C. Mawer <scm at datlog.co.uk> or < {backbone}!ukc!datlog!scm >
Voice: +44 1 863 0383 (x2153)
More information about the Comp.unix.questions
mailing list