lkml.org 
[lkml]   [2020]   [Mar]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Have RESOLVE_* flags superseded AT_* flags for new syscalls?
On Mon, Mar 02, 2020 at 02:50:03PM +0000, David Howells wrote:
> Christian Brauner <christian.brauner@ubuntu.com> wrote:
>
> > I think we settled this and can agree on RESOLVE_NO_SYMLINKS being the
> > right thing to do, i.e. not resolving symlinks will stay opt-in.
> > Or is your worry even with the current semantics of openat2()? I don't
> > see the issue since O_NOFOLLOW still works with openat2().
>
> Say, for example, my home dir is on a network volume somewhere and /home has a
> symlink pointing to it. RESOLVE_NO_SYMLINKS cannot be used to access a file
> inside my homedir if the pathwalk would go through /home/dhowells - this would
> affect fsinfo() - so RESOLVE_NO_SYMLINKS is not a substitute for
> AT_SYMLINK_NOFOLLOW (O_NOFOLLOW would not come into it).

I think we didn't really have this issue/face that question because
openat() never supported AT_SYMLINK_{NO}FOLLOW. Whereas e.g. fsinfo()
does. So in such cases we are back to: either allow both AT_* and
RESOLVE_* flags (imho not the best option) or add (a) new RESOLVE_*
variant(s). It seems we leaned toward the latter so far...

Christian

\
 
 \ /
  Last update: 2020-03-02 16:06    [W:0.093 / U:0.144 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site