This is rational - if you have the ability to move it, you have the ability
to chown it.

If the chown were not an explicit next step, users and applications would
need to track users, groups, and permissions for each file they moved.
On Feb 8, 2013 8:43 AM, "Filip Kocina" <[email protected]> wrote:

> Hi all,
>
> I'd like to ask you why the owner and the group of a file is retained
> while moving a file via mv. I was surprised when I made a file as root
> in home directory of another user and moved this file as this another
> user into /tmp. I mean the preservation is rather logical, but if this
> another user renamed this file to a not very smooth-tongued name, the
> user who owns this file could be compromised. I know there is an easy
> solution: not to move file into a directory of another user, but still,
> this behavior of mv is little weird for me.
>
> Thank you in advance for explanation.
>
> --
> Filip Kocina
> E-mail: [email protected]
>
>

Reply via email to