Jan Kara 483831ad04 ext4: fix check for block being out of directory size
commit 61a1d87a324ad5e3ed27c6699dfc93218fcf3201 upstream.

The check in __ext4_read_dirblock() for block being outside of directory
size was wrong because it compared block number against directory size
in bytes. Fix it.

Fixes: 65f8ea4cd57d ("ext4: check if directory block is within i_size")
CVE: CVE-2022-1184
CC: stable@vger.kernel.org
Signed-off-by: Jan Kara <jack@suse.cz>
Reviewed-by: Lukas Czerner <lczerner@redhat.com>
Link: https://lore.kernel.org/r/20220822114832.1482-1-jack@suse.cz
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-10-26 13:25:13 +02:00
..
2020-10-16 11:11:22 -07:00
2021-09-18 13:40:15 +02:00
2020-09-10 14:03:31 -07:00
2022-06-09 10:21:16 +02:00
2020-08-04 21:02:38 -04:00
2020-10-23 11:33:41 -07:00
2020-05-14 16:44:24 +02:00
2020-10-23 11:33:41 -07:00
2020-08-27 16:06:47 -04:00
2020-07-31 08:16:01 +02:00