Unexpected change of file owner:group

Mikkel L. Ellertson mikkel at infinity-ltd.com
Fri Jan 20 16:05:28 UTC 2006


J. K. Cliburn wrote:
> On 1/20/06, Paul Howarth <paul at city-fan.org> wrote:
> 
>>If the directory is group-writable, any member of the group can achieve
>>the same result by doing:
>>
>>$ cp junk junk.new
>>$ rm junk
>>$ mv junk.new junk
> 
> 
> Learn something new every day.  From the chmod manpage:
> 
> When the sticky bit is set on a directory, files in that
> directory may be unlinked or renamed only by root or
> their owner.  Without the sticky bit, anyone able to
> write to the directory can delete or rename files.
> 
Take a look at the /tmp directory - it is set up that way.

Mikkel
-- 

  Do not meddle in the affairs of dragons,
for thou art crunchy and taste good with Ketchup!




More information about the fedora-list mailing list