Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1267093
| From | Al Viro <viro@ZenIV.linux.org.uk> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: fs: out of bounds on stack in iov_iter_advance |
| Date | 2015-11-11 11:30 +0100 |
| Message-ID | <qtAP8-1we-27@gated-at.bofh.it> (permalink) |
| References | (5 earlier) <qttNE-5dn-3@gated-at.bofh.it> <qtuql-5NC-5@gated-at.bofh.it> <qtvmq-6mF-3@gated-at.bofh.it> <qtyki-8g4-13@gated-at.bofh.it> <qtyNj-ei-9@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Wed, Nov 11, 2015 at 07:16:36PM +1100, Stephen Rothwell wrote:
> Hi Al,
>
> On Wed, 11 Nov 2015 07:43:30 +0000 Al Viro <viro@ZenIV.linux.org.uk> wrote:
> >
> > dax_io fix isn't there, neither is overlayfs magic.h patch - both are
> > already in other trees. I would like to get xattr series in as well,
> > but that's a separate pull request, if you'd accept them in this window in
> > the first place. richacl stuff isn't there as well, and I think that one
> > is clear "leave it for 4.5" fodder.
>
> So could you please remove the 4.5 stuff from your for-next branch
> until after the merge window closes.
Done.
> Also, I noticed these new warnings today:
>
> fs/orangefs/xattr.c:509:9: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
> .get = pvfs2_xattr_get_trusted,
> ^
> fs/orangefs/xattr.c:509:9: note: (near initialization for 'pvfs2_xattr_trusted_handler.get')
> fs/orangefs/xattr.c:510:9: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
> .set = pvfs2_xattr_set_trusted,
> ^
> fs/orangefs/xattr.c:510:9: note: (near initialization for 'pvfs2_xattr_trusted_handler.set')
> fs/orangefs/xattr.c:520:9: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
> .get = pvfs2_xattr_get_default,
> ^
> fs/orangefs/xattr.c:520:9: note: (near initialization for 'pvfs2_xattr_default_handler.get')
> fs/orangefs/xattr.c:521:9: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
> .set = pvfs2_xattr_set_default,
> ^
> fs/orangefs/xattr.c:521:9: note: (near initialization for 'pvfs2_xattr_default_handler.set')
That's "xattr handlers: Pass handler to operations instead of flags" fallout,
trivially adjusted (typical change is
-ext2_xattr_security_list(struct dentry *dentry, char *list, size_t list_size,
- const char *name, size_t name_len, int type)
+ext2_xattr_security_list(const struct xattr_handler *handler,
+ struct dentry *dentry, char *list, size_t list_size,
+ const char *name, size_t name_len)
with type replaced with handler->flags if it's used anywhere in the body;
AFAICS, none of orangefs instances use it at all, so it's just a matter of
changing the argument lists in pvfs2_xattr_[gs]et_{default,trusted},
adding const struct xattr_handler *handler in the beginning and removing
the last argument; callers in pvfs2_ioctl() should simply use
pvfs2_inode_[gs]etxattr()).
Note, however, that orangefs in linux-next lacks a lot of fixes (see
vfs.git#orangefs-untested for some; AFAICS, those are missing from all
branches in orangefs git tree) and there are problems I don't know
how to fix, mostly due to the lack of documentation. The last I've
heard from them was that they were putting such docs together; hopefully
once that get done we'll be able to sort the rest of that thing out.
It'll be after -rc1, though.
So xattr conflicts are the least of the problems there; those are easy
to adjust for, there are more serious issues in the entire thing ;-/
BTW, while we are at it - pvfs2_listxattr() doesn't even validate
resp.listxattr.returned_count, so a bogus response from buggered
server will do really interesting things to the kernel.
I'll cook the minimal fixup for API change after I get some sleep and
send it your way, unless somebody gets there first...
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: fs: out of bounds on stack in iov_iter_advance Al Viro <viro@ZenIV.linux.org.uk> - 2015-11-06 02:40 +0100
Re: fs: out of bounds on stack in iov_iter_advance Al Viro <viro@ZenIV.linux.org.uk> - 2015-11-06 03:20 +0100
Re: fs: out of bounds on stack in iov_iter_advance Linus Torvalds <torvalds@linux-foundation.org> - 2015-11-06 04:40 +0100
Re: fs: out of bounds on stack in iov_iter_advance Jens Axboe <axboe@kernel.dk> - 2015-11-06 17:10 +0100
Re: fs: out of bounds on stack in iov_iter_advance Linus Torvalds <torvalds@linux-foundation.org> - 2015-11-11 03:30 +0100
Re: fs: out of bounds on stack in iov_iter_advance Jens Axboe <axboe@kernel.dk> - 2015-11-11 03:30 +0100
Re: fs: out of bounds on stack in iov_iter_advance Linus Torvalds <torvalds@linux-foundation.org> - 2015-11-11 03:40 +0100
Re: fs: out of bounds on stack in iov_iter_advance Jens Axboe <axboe@kernel.dk> - 2015-11-11 03:50 +0100
Re: fs: out of bounds on stack in iov_iter_advance Jens Axboe <axboe@kernel.dk> - 2015-11-11 03:50 +0100
Re: fs: out of bounds on stack in iov_iter_advance Al Viro <viro@ZenIV.linux.org.uk> - 2015-11-11 04:10 +0100
Re: fs: out of bounds on stack in iov_iter_advance Jens Axboe <axboe@kernel.dk> - 2015-11-11 04:10 +0100
Re: fs: out of bounds on stack in iov_iter_advance Jens Axboe <axboe@kernel.dk> - 2015-11-11 03:50 +0100
Re: fs: out of bounds on stack in iov_iter_advance Sasha Levin <sasha.levin@oracle.com> - 2015-11-11 04:30 +0100
Re: fs: out of bounds on stack in iov_iter_advance Al Viro <viro@ZenIV.linux.org.uk> - 2015-11-11 04:00 +0100
Re: fs: out of bounds on stack in iov_iter_advance Al Viro <viro@ZenIV.linux.org.uk> - 2015-11-11 04:40 +0100
Re: fs: out of bounds on stack in iov_iter_advance Linus Torvalds <torvalds@linux-foundation.org> - 2015-11-11 05:40 +0100
Re: fs: out of bounds on stack in iov_iter_advance Al Viro <viro@ZenIV.linux.org.uk> - 2015-11-11 08:50 +0100
Re: fs: out of bounds on stack in iov_iter_advance Stephen Rothwell <sfr@canb.auug.org.au> - 2015-11-11 09:20 +0100
Re: fs: out of bounds on stack in iov_iter_advance Stephen Rothwell <sfr@canb.auug.org.au> - 2015-11-11 11:30 +0100
Re: fs: out of bounds on stack in iov_iter_advance Mike Marshall <hubcap@omnibond.com> - 2015-11-11 17:30 +0100
Re: fs: out of bounds on stack in iov_iter_advance Al Viro <viro@ZenIV.linux.org.uk> - 2015-11-11 17:40 +0100
Re: fs: out of bounds on stack in iov_iter_advance Mike Marshall <hubcap@omnibond.com> - 2015-11-11 18:00 +0100
Re: fs: out of bounds on stack in iov_iter_advance Al Viro <viro@ZenIV.linux.org.uk> - 2015-11-11 11:30 +0100
Re: fs: out of bounds on stack in iov_iter_advance Al Viro <viro@ZenIV.linux.org.uk> - 2015-11-11 17:40 +0100
Re: fs: out of bounds on stack in iov_iter_advance Stephen Rothwell <sfr@canb.auug.org.au> - 2015-11-11 22:50 +0100
csiph-web