reiserfs: check directory items on read from disk
While verifying the leaf item that we read from the disk, reiserfs
doesn't check the directory items, this could cause a crash when we
read a directory item from the disk that has an invalid deh_location.
This patch adds a check to the directory items read from the disk that
does a bounds check on deh_location for the directory entries. Any
directory entry header with a directory entry offset greater than the
item length is considered invalid.
Signed-off-by: Shreyansh Chouhan <email@example.com>
Signed-off-by: Jan Kara <firstname.lastname@example.org>
1 file changed