[lkml]   [1996]   [Jul]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: How does chown(2) works with symlinks?
    > The fact that chmod(2) could return an 'ELOOP' error (According to
    > manpages 1.8) suggest that chmod() used to follow the symlink. This
    > not the case anymore.

    this may be a reminder from the old, broken days or just stolen fron
    a broken system...

    > Personally I think that it should resolve the symlink. Access and
    > ownership should be controled by the file that the symlink points to.

    at least for chown(1) this is a *bad* idea.
    small example: you have to change the change the UID of a directory tree
    from one user (e.g. moving to an other insitute; other working group etc.).


    chown -R new_user.new_group ~new_user/.

    may have *nasty* "side effects" when the user has a symbolic link like this one:

    # ls -l ~new_user/private
    total 0
    lrwxrwxrwx 1 old_user old_group 11 Jul 11 19:30 ATARI! -> /etc/passwd

    All SCSI disks will from now on ___ _____
    be required to send an email notice 0--,| /OOOOOOO\
    24 hours prior to complete hardware failure! <_/ / /OOOOOOOOOOO\
    Harald Koenig, \/\/\/\/\/\/\/\/\/
    Inst.f.Theoret.Astrophysik // / \\ \ ^^^^^ ^^^^^

     \ /
      Last update: 2005-03-22 13:38    [W:0.019 / U:0.964 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site