]> git.hungrycats.org Git - linux/commit
fs/ntfs3: Validate ff offset
authorlei lu <llfamsec@gmail.com>
Tue, 28 May 2024 18:52:22 +0000 (02:52 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 27 Jul 2024 09:36:15 +0000 (11:36 +0200)
commit82c94e6a7bd116724738aa67eba6f5fedf3a3319
treeec13174401dacb9d2b2b6b87344ea328c316890c
parentc114d2b88f8b226d4b2acf5a1ba0412cde6c31dd
fs/ntfs3: Validate ff offset

commit 50c47879650b4c97836a0086632b3a2e300b0f06 upstream.

This adds sanity checks for ff offset. There is a check
on rt->first_free at first, but walking through by ff
without any check. If the second ff is a large offset.
We may encounter an out-of-bound read.

Signed-off-by: lei lu <llfamsec@gmail.com>
Signed-off-by: Konstantin Komarov <almaz.alexandrovich@paragon-software.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/ntfs3/fslog.c