ext4: ignore e_value_offs for xattrs with value-in-ea-inode
authorTheodore Ts'o <tytso@mit.edu>
Wed, 10 Apr 2019 04:37:36 +0000 (00:37 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 21 May 2019 16:50:18 +0000 (18:50 +0200)
commit01bb84a8d9f557636c432a0743fd25ec77a91248
tree84956cddfde0df5d22d9791b28983a6c24c59675
parent4197a149744e6fba8768400cafefaa41d108267d
ext4: ignore e_value_offs for xattrs with value-in-ea-inode

commit e5d01196c0428a206f307e9ee5f6842964098ff0 upstream.

In other places in fs/ext4/xattr.c, if e_value_inum is non-zero, the
code ignores the value in e_value_offs.  The e_value_offs *should* be
zero, but we shouldn't depend upon it, since it might not be true in a
corrupted/fuzzed file system.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=202897
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=202877
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/ext4/xattr.c