Skip to content
Commit fbbf7799 authored by Sahitya Tummala's avatar Sahitya Tummala Committed by Jaegeuk Kim
Browse files

f2fs: add a condition to detect overflow in f2fs_ioc_gc_range()



end = range.start + range.len;

If the range.start/range.len is a very large value, then end can overflow
in this operation. It results into a crash in get_valid_blocks() when
accessing the invalid range.start segno.

This issue is reported in ioctl fuzz testing.

Signed-off-by: default avatarSahitya Tummala <stummala@codeaurora.org>
Reviewed-by: default avatarChao Yu <yuchao0@huawei.com>
Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
parent 8223ecc4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment