linux/fs/squashfs
Tetsuo Handa bc107a619f squashfs: verify inode mode when loading from disk
The inode mode loaded from corrupted disk might by error contain the file
type bits.  Since the file type bits are set by squashfs_read_inode()
using bitwise OR, the file type bits must not be set by
squashfs_new_inode() from squashfs_read_inode(); otherwise, an invalid
file type bits later confuses may_open().

Link: https://lkml.kernel.org/r/f63d8d11-2254-4fc3-9292-9a43a93b374e@I-love.SAKURA.ne.jp
Reported-by: syzbot <syzbot+895c23f6917da440ed0d@syzkaller.appspotmail.com>
Closes: https://syzkaller.appspot.com/bug?extid=895c23f6917da440ed0d
Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Reviewed-by: Phillip Lougher <phillip@squashfs.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2025-09-13 17:32:46 -07:00
..
Kconfig squashfs: add optional full compressed block caching 2025-05-27 19:40:33 -07:00
Makefile
block.c squashfs: fix incorrect argument to sizeof in kmalloc_array call 2025-07-19 19:08:27 -07:00
cache.c squashfs: fix invalid pointer dereference in squashfs_cache_delete 2025-03-16 17:40:24 -07:00
decompressor.c
decompressor.h
decompressor_multi.c
decompressor_multi_percpu.c squashfs: fix percpu address space issues in decompressor_multi_percpu.c 2024-09-09 16:47:41 -07:00
decompressor_single.c
dir.c
export.c
file.c squashfs: pass the inode to squashfs_readahead_fragment() 2025-07-09 22:57:50 -07:00
file_cache.c squashfs; convert squashfs_copy_cache() to take a folio 2025-01-24 22:47:22 -08:00
file_direct.c squashfs: convert squashfs_readpage_block() to take a folio 2025-01-24 22:47:22 -08:00
fragment.c
id.c
inode.c squashfs: verify inode mode when loading from disk 2025-09-13 17:32:46 -07:00
lz4_wrapper.c
lzo_wrapper.c
namei.c
page_actor.c Squashfs: Update page_actor to not use page->index 2024-08-19 14:08:20 +02:00
page_actor.h Squashfs: Ensure all readahead pages have been used 2024-08-23 13:11:36 +02:00
squashfs.h squashfs: convert squashfs_fill_page() to take a folio 2025-01-24 22:47:22 -08:00
squashfs_fs.h
squashfs_fs_i.h
squashfs_fs_sb.h
super.c squashfs: fix memory leak in squashfs_fill_super 2025-08-19 16:35:53 -07:00
symlink.c
xattr.c
xattr.h
xattr_id.c
xz_wrapper.c
zlib_wrapper.c
zstd_wrapper.c