]> git.baikalelectronics.ru Git - kernel.git/commit
ext4: fix use-after-free race with debug_want_extra_isize
authorBarret Rhoden <brho@google.com>
Thu, 25 Apr 2019 15:55:50 +0000 (11:55 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 25 Apr 2019 15:55:50 +0000 (11:55 -0400)
commitc337ed56cc999d169f03f0b5e4ac8aada496502a
tree4c26d579cd4786eb3db4388078f025233d0beea5
parenteb725d20fca13675b96cd63d9d7a5a607a03e89e
ext4: fix use-after-free race with debug_want_extra_isize

When remounting with debug_want_extra_isize, we were not performing the
same checks that we do during a normal mount.  That allowed us to set a
value for s_want_extra_isize that reached outside the s_inode_size.

Fixes: d8f94ffae19d ("ext4: clean up feature test macros with predicate functions")
Reported-by: syzbot+f584efa0ac7213c226b7@syzkaller.appspotmail.com
Reviewed-by: Jan Kara <jack@suse.cz>
Signed-off-by: Barret Rhoden <brho@google.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@vger.kernel.org
fs/ext4/super.c