Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-08 Thread Jeffrey Altman
On 7/8/2017 9:01 PM, Theodore Ts'o wrote: > On Sat, Jul 08, 2017 at 12:44:54PM -0700, Linus Torvalds wrote: >> Yeah, I think attributes are likely much better than some random crazy >> ioctl interface. They can be listed with generic tools, and have >> various scripting interfaces in ways that

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-08 Thread Jeffrey Altman
On 7/8/2017 9:01 PM, Theodore Ts'o wrote: > On Sat, Jul 08, 2017 at 12:44:54PM -0700, Linus Torvalds wrote: >> Yeah, I think attributes are likely much better than some random crazy >> ioctl interface. They can be listed with generic tools, and have >> various scripting interfaces in ways that

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-08 Thread Theodore Ts'o
On Sat, Jul 08, 2017 at 12:44:54PM -0700, Linus Torvalds wrote: > Yeah, I think attributes are likely much better than some random crazy > ioctl interface. They can be listed with generic tools, and have > various scripting interfaces in ways that ioctl's do not sanely have. I personally don't

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-08 Thread Theodore Ts'o
On Sat, Jul 08, 2017 at 12:44:54PM -0700, Linus Torvalds wrote: > Yeah, I think attributes are likely much better than some random crazy > ioctl interface. They can be listed with generic tools, and have > various scripting interfaces in ways that ioctl's do not sanely have. I personally don't

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-08 Thread Linus Torvalds
On Thu, Jul 6, 2017 at 11:27 AM, Andreas Dilger wrote: > > IMHO, xattrs are a fairly reasonable interface for accessing > filesystem-specific > attributes of a file that do not have generic equivalents on other > filesystems. > I can't see there being much value to having

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-08 Thread Linus Torvalds
On Thu, Jul 6, 2017 at 11:27 AM, Andreas Dilger wrote: > > IMHO, xattrs are a fairly reasonable interface for accessing > filesystem-specific > attributes of a file that do not have generic equivalents on other > filesystems. > I can't see there being much value to having AFS-specific syscalls,

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-06 Thread Andreas Dilger
On Jul 6, 2017, at 10:14 AM, David Howells wrote: > > Christoph Hellwig wrote: > >> NAK. Don't overload xattrs with magic behavior just to avoid the need >> to do proper syscalls or ioctls. > > How? This has to work on non-files, files you can't open

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-06 Thread Andreas Dilger
On Jul 6, 2017, at 10:14 AM, David Howells wrote: > > Christoph Hellwig wrote: > >> NAK. Don't overload xattrs with magic behavior just to avoid the need >> to do proper syscalls or ioctls. > > How? This has to work on non-files, files you can't open and mountpoints. > You can't do an

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-06 Thread David Howells
Christoph Hellwig wrote: > NAK. Don't overload xattrs with magic behavior just to avoid the need > to do proper syscalls or ioctls. How? This has to work on non-files, files you can't open and mountpoints. You can't do an ioctl() on a file opened O_PATH: if

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-06 Thread David Howells
Christoph Hellwig wrote: > NAK. Don't overload xattrs with magic behavior just to avoid the need > to do proper syscalls or ioctls. How? This has to work on non-files, files you can't open and mountpoints. You can't do an ioctl() on a file opened O_PATH: if (unlikely(f->f_flags &

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-06 Thread Christoph Hellwig
NAK. Don't overload xattrs with magic behavior just to avoid the need to do proper syscalls or ioctls. This makes them harder to discover, audit and security fix. On Thu, Jul 06, 2017 at 03:50:27PM +0100, David Howells wrote: > Add xattrs to allow the user to get/set metadata in lieu of having

Re: [PATCH 2/2] afs: Add metadata xattrs

2017-07-06 Thread Christoph Hellwig
NAK. Don't overload xattrs with magic behavior just to avoid the need to do proper syscalls or ioctls. This makes them harder to discover, audit and security fix. On Thu, Jul 06, 2017 at 03:50:27PM +0100, David Howells wrote: > Add xattrs to allow the user to get/set metadata in lieu of having

[PATCH 2/2] afs: Add metadata xattrs

2017-07-06 Thread David Howells
Add xattrs to allow the user to get/set metadata in lieu of having pioctl() available. The following xattrs are now available: (*) afs.cell The name of the cell in which the vnode's volume resides. (*) afs.fid The volume ID, vnode ID and vnode uniquifier of the file as three hex

[PATCH 2/2] afs: Add metadata xattrs

2017-07-06 Thread David Howells
Add xattrs to allow the user to get/set metadata in lieu of having pioctl() available. The following xattrs are now available: (*) afs.cell The name of the cell in which the vnode's volume resides. (*) afs.fid The volume ID, vnode ID and vnode uniquifier of the file as three hex