Re: [patch] rm can have undesired side-effects
- From: perryh@xxxxxxxxxxxxxx
- Date: Sun, 29 Oct 2006 18:11:54 -0800
... deleted files are lost.
Not if another hard link exists!
I think a very strong case can be made that the *intent* of -P --
to prevent retrieval of the contents by reading the filesystem's
free space -- implies that it should affect only the "real" removal
of the file, when its blocks are released because the link count
has become zero. At that point, we by definition are only wiping
out data which is eligible to be overwritten by any process that
happens to be allocating space on the same filesystem, and which
can no longer be read by "normal" filesystem operations, anyway.
In this interpretation, "rm -P" when the link count exceeds 1 is
an erroneous command.
I'd at least allow rm -P to wipe a file with a non-zero remaining
link count only under the same restrictions applied to files that
are not writable by the invoker of rm.
_______________________________________________
freebsd-hackers@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@xxxxxxxxxxx"
- Follow-Ups:
- Re: [patch] rm can have undesired side-effects
- From: Peter Jeremy
- Re: [patch] rm can have undesired side-effects
- References:
- [patch] rm can have undesired side-effects
- From: Romain Tartiere
- Re: [patch] rm can have undesired side-effects
- From: Joerg Pernfuss
- [patch] rm can have undesired side-effects
- Prev by Date: Re: [patch] rm can have undesired side-effects
- Next by Date: Re: [patch] rm can have undesired side-effects
- Previous by thread: Re: [patch] rm can have undesired side-effects
- Next by thread: Re: [patch] rm can have undesired side-effects
- Index(es):