android_kernel_oneplus_msm8998/fs/ext4
Theodore Ts'o fb751efb29 ext4: always verify the magic number in xattr blocks
commit 513f86d73855ce556ea9522b6bfd79f87356dc3a upstream.

If there an inode points to a block which is also some other type of
metadata block (such as a block allocation bitmap), the
buffer_verified flag can be set when it was validated as that other
metadata block type; however, it would make a really terrible external
attribute block.  The reason why we use the verified flag is to avoid
constantly reverifying the block.  However, it doesn't take much
overhead to make sure the magic number of the xattr block is correct,
and this will avoid potential crashes.

This addresses CVE-2018-10879.

https://bugzilla.kernel.org/show_bug.cgi?id=200001

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Reviewed-by: Andreas Dilger <adilger@dilger.ca>
[Backported to 4.4: adjust context]
Signed-off-by: Daniel Rosenberg <drosen@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-10-13 09:11:33 +02:00
..
acl.c ext4: Don't clear SGID when inheriting ACLs 2017-10-12 11:27:35 +02:00
acl.h
balloc.c ext4: check for allocation block validity with block group locked 2018-08-06 16:24:40 +02:00
bitmap.c
block_validity.c
crypto.c
crypto_fname.c
crypto_key.c fscrypt: lock mutex before checking for bounce page pool 2017-11-30 08:37:25 +00:00
crypto_policy.c
dir.c ext4: avoid divide by zero fault when deleting corrupted inline directories 2018-09-29 03:08:53 -07:00
ext4.h ext4: add more inode number paranoia checks 2018-07-11 16:03:49 +02:00
ext4_crypto.h
ext4_extents.h ext4: verify the depth of extent tree in ext4_find_extent() 2018-07-11 16:03:48 +02:00
ext4_jbd2.c
ext4_jbd2.h
extents.c ext4: verify the depth of extent tree in ext4_find_extent() 2018-07-11 16:03:48 +02:00
extents_status.c
extents_status.h
file.c ext4: fix off-by-one on max nr_pages in ext4_find_unwritten_pgoff() 2018-04-13 19:50:11 +02:00
fsync.c
hash.c
ialloc.c ext4: fix check to prevent initializing reserved inodes 2018-08-15 17:42:04 +02:00
indirect.c
inline.c ext4: avoid divide by zero fault when deleting corrupted inline directories 2018-09-29 03:08:53 -07:00
inode.c ext4: fix inline data updates with checksums enabled 2018-08-06 16:24:40 +02:00
ioctl.c
Kconfig
Makefile
mballoc.c ext4: fix spectre gadget in ext4_mb_regular_allocator() 2018-08-24 13:27:00 +02:00
mballoc.h
migrate.c
mmp.c ext4: don't mark mmp buffer head dirty 2018-09-29 03:08:54 -07:00
move_extent.c
namei.c ext4: reset error code in ext4_find_entry in fallback 2018-09-05 09:18:38 +02:00
page-io.c
readpage.c
resize.c ext4: fix online resizing for bigalloc file systems with a 1k block size 2018-09-29 03:08:54 -07:00
super.c ext4: recalucate superblock checksum after updating free blocks/inodes 2018-09-29 03:08:54 -07:00
symlink.c don't put symlink bodies in pagecache into highmem 2018-02-16 20:09:38 +01:00
sysfs.c ext4: sysfs: print ext4_super_block fields as little-endian 2018-09-05 09:18:38 +02:00
truncate.h
xattr.c ext4: always verify the magic number in xattr blocks 2018-10-13 09:11:33 +02:00
xattr.h ext4: fix deadlock between inline_data and ext4_expand_extra_isize_ea() 2018-04-24 09:32:10 +02:00
xattr_security.c
xattr_trusted.c
xattr_user.c