WSL2-Linux-Kernel/fs/udf
Jan Kara 6a43e3c210 udf: Avoid using corrupted block bitmap buffer
commit a90d4471146de21745980cba51ce88e7926bcc4f upstream.

When the filesystem block bitmap is corrupted, we detect the corruption
while loading the bitmap and fail the allocation with error. However the
next allocation from the same bitmap will notice the bitmap buffer is
already loaded and tries to allocate from the bitmap with mixed results
(depending on the exact nature of the bitmap corruption). Fix the
problem by using BH_verified bit to indicate whether the bitmap is valid
or not.

Reported-by: syzbot+5f682cd029581f9edfd1@syzkaller.appspotmail.com
CC: stable@vger.kernel.org
Link: https://patch.msgid.link/20240617154201.29512-2-jack@suse.cz
Fixes: 1e0d4adf17 ("udf: Check consistency of Space Bitmap Descriptor")
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-08-19 05:45:13 +02:00
..
Kconfig
Makefile
balloc.c udf: Avoid using corrupted block bitmap buffer 2024-08-19 05:45:13 +02:00
dir.c udf: Fix crash after seekdir 2021-11-25 09:48:46 +01:00
directory.c
ecma_167.h udf: Get rid of 0-length arrays in struct fileIdentDesc 2021-08-11 16:54:44 +02:00
file.c udf: Do not update file length for failed writes to inline files 2023-03-10 09:39:59 +01:00
ialloc.c udf: Fix error handling in udf_new_inode() 2022-01-27 11:05:02 +01:00
inode.c udf: initialize newblock to 0 2023-09-19 12:22:53 +02:00
lowlevel.c
misc.c udf_get_extendedattr() had no boundary checks. 2021-08-23 13:35:19 +02:00
namei.c udf: Avoid double brelse() in udf_rename() 2022-12-31 13:14:40 +01:00
osta_udf.h udf: Get rid of 0-length arrays 2021-08-11 16:54:44 +02:00
partition.c
super.c udf: Avoid using corrupted block bitmap buffer 2024-08-19 05:45:13 +02:00
symlink.c fs: make helpers idmap mount aware 2021-01-24 14:27:20 +01:00
truncate.c udf: Do not bother looking for prealloc extents if i_lenExtents matches i_size 2022-12-21 17:36:36 +01:00
udf_i.h udf: Preserve link count of system files 2023-03-10 09:40:00 +01:00
udf_sb.h udf: Define EFSCORRUPTED error code 2023-03-10 09:39:46 +01:00
udfdecl.h udf: Get rid of 0-length arrays in struct fileIdentDesc 2021-08-11 16:54:44 +02:00
udfend.h
udftime.c udf: udftime: prevent overflow in udf_disk_stamp_to_time() 2024-07-05 09:14:28 +02:00
unicode.c udf: Fix uninitialized array access for some pathnames 2023-07-27 08:46:58 +02:00