ext4: sanity check the block and cluster size at mount time
authorTheodore Ts'o <tytso@mit.edu>
Fri, 18 Nov 2016 18:00:24 +0000 (13:00 -0500)
committerBen Hutchings <ben@decadent.org.uk>
Thu, 23 Feb 2017 03:51:01 +0000 (03:51 +0000)
commit29f07fabd4b093ff5352bb0e7051880092163dcd
tree25cc7b2406aab11e7a7e45f82b4435ba53b81e4a
parentb2decb623a42f21e5fe878fe3f9e612e06b62106
ext4: sanity check the block and cluster size at mount time

commit 8cdf3372fe8368f56315e66bea9f35053c418093 upstream.

If the block size or cluster size is insane, reject the mount.  This
is important for security reasons (although we shouldn't be just
depending on this check).

Ref: http://www.securityfocus.com/archive/1/539661
Ref: https://bugzilla.redhat.com/show_bug.cgi?id=1332506
Reported-by: Borislav Petkov <bp@alien8.de>
Reported-by: Nikolay Borisov <kernel@kyup.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
fs/ext4/ext4.h
fs/ext4/super.c