[lkml]   [1996]   [Jul]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: How does chown(2) works with symlinks?
In, Linus Torvalds <> wrote:

>which should always work the way you expect. If you use "chown()" on the
>pathname it will change the synlink itself (if you think about it, that is
>actually the reasonable behaviour: otherwise you could never change the owner
>of the symlink).

This also protects against all sorts of nasty games with symlinks,
for example the well - known xterm bug, where the program did, as root,

<=== user could do a "rm somefile; ln -s /etc/profile somefile"

 \ /
  Last update: 2005-03-22 13:38    [W:0.105 / U:1.448 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site