syzbot


KASAN: slab-out-of-bounds Read in ea_get

Status: upstream: reported C repro on 2023/06/01 07:39
Bug presence: origin:upstream
[Documentation on labels]
Reported-by: syzbot+dd80cf7671216c88549c@syzkaller.appspotmail.com
First crash: 497d, last: 2d01h
Fix bisection: failed (error log, bisect log)
  
Bug presence (1)
Date Name Commit Repro Result
2023/06/02 upstream (ToT) 9e87b63ed37e C [report] KASAN: slab-out-of-bounds Read in ea_get
Similar bugs (6)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.19 KASAN: slab-out-of-bounds Read in ea_get 3 703d 736d 0/1 auto-obsoleted due to no activity on 2023/03/06 17:23
linux-6.1 KASAN: slab-out-of-bounds Read in ea_get origin:upstream C 5 7d07h 495d 0/3 upstream: reported C repro on 2023/06/02 15:16
upstream KASAN: slab-out-of-bounds Read in ea_get (2) jfs C 33 95d 159d 26/28 fixed on 2024/07/09 19:14
linux-4.14 KASAN: slab-out-of-bounds Read in ea_get C 1 595d 734d 0/1 upstream: reported C repro on 2022/10/07 03:56
upstream KASAN: slab-out-of-bounds Read in ea_get (3) jfs 4 57d 47d 0/28 upstream: reported on 2024/08/23 15:15
upstream KASAN: slab-out-of-bounds Read in ea_get jfs C inconclusive 29 359d 736d 0/28 closed as dup on 2022/10/05 09:10
Last patch testing requests (3)
Created Duration User Patch Repo Result
2024/10/08 11:51 11m retest repro linux-5.15.y report log
2024/10/08 11:51 20m retest repro linux-5.15.y OK log
2024/10/08 11:51 10m retest repro linux-5.15.y report log

Sample crash report:
ffff8880759ebff0: e8 bf 9e 75 80 88 ff ff 00 00 00 00 00 00 00 00  ...u............
ffff8880759ec000: 00 c0 9e 75 80 88 ff ff 00 c0 9e 75 80 88 ff ff  ...u.......u....
ffff8880759ec010: 00 00 00 00 00 00 00 00 04 00 00 00 00 00 00 00  ................
ffff8880759ec020: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
ffff8880759ec030: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
==================================================================
BUG: KASAN: slab-out-of-bounds in hex_dump_to_buffer+0x72d/0xba0 lib/hexdump.c:193
Read of size 1 at addr ffff8880759ec040 by task syz-executor167/3504

CPU: 0 PID: 3504 Comm: syz-executor167 Not tainted 5.15.118-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/27/2023
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e3/0x2cb lib/dump_stack.c:106
 print_address_description+0x63/0x3b0 mm/kasan/report.c:248
 __kasan_report mm/kasan/report.c:434 [inline]
 kasan_report+0x16b/0x1c0 mm/kasan/report.c:451
 hex_dump_to_buffer+0x72d/0xba0 lib/hexdump.c:193
 print_hex_dump+0x13b/0x250 lib/hexdump.c:276
 ea_get+0xcdc/0x1280 fs/jfs/xattr.c:561
 jfs_listxattr+0xe0/0x810 fs/jfs/xattr.c:867
 vfs_listxattr fs/xattr.c:448 [inline]
 listxattr+0x282/0x2e0 fs/xattr.c:783
 path_listxattr fs/xattr.c:807 [inline]
 __do_sys_listxattr fs/xattr.c:819 [inline]
 __se_sys_listxattr fs/xattr.c:816 [inline]
 __x64_sys_listxattr+0x172/0x230 fs/xattr.c:816
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7ff9e23f3a49
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 51 14 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fff6c06bec8 EFLAGS: 00000246 ORIG_RAX: 00000000000000c2
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007ff9e23f3a49
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000020000000
RBP: 00007ff9e23b3050 R08: 0000000000005ed8 R09: 0000000000000000
R10: 00007fff6c06bd90 R11: 0000000000000246 R12: 00007ff9e23b30e0
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
 </TASK>

Allocated by task 3504:
 kasan_save_stack mm/kasan/common.c:38 [inline]
 kasan_set_track mm/kasan/common.c:46 [inline]
 set_alloc_info mm/kasan/common.c:434 [inline]
 __kasan_slab_alloc+0x8e/0xc0 mm/kasan/common.c:467
 kasan_slab_alloc include/linux/kasan.h:254 [inline]
 slab_post_alloc_hook+0x53/0x380 mm/slab.h:519
 slab_alloc_node mm/slub.c:3220 [inline]
 slab_alloc mm/slub.c:3228 [inline]
 kmem_cache_alloc+0xf3/0x280 mm/slub.c:3233
 jfs_alloc_inode+0x17/0x50 fs/jfs/super.c:105
 alloc_inode fs/inode.c:236 [inline]
 iget_locked+0x194/0x7f0 fs/inode.c:1202
 jfs_iget+0x1e/0x3b0 fs/jfs/inode.c:29
 jfs_lookup+0x222/0x400 fs/jfs/namei.c:1462
 __lookup_slow+0x275/0x3d0 fs/namei.c:1659
 lookup_slow+0x53/0x70 fs/namei.c:1676
 walk_component+0x48c/0x610 fs/namei.c:1972
 lookup_last fs/namei.c:2427 [inline]
 path_lookupat+0x16f/0x450 fs/namei.c:2451
 filename_lookup+0x230/0x5c0 fs/namei.c:2480
 user_path_at_empty+0x40/0x180 fs/namei.c:2853
 user_path_at include/linux/namei.h:57 [inline]
 path_listxattr fs/xattr.c:804 [inline]
 __do_sys_listxattr fs/xattr.c:819 [inline]
 __se_sys_listxattr fs/xattr.c:816 [inline]
 __x64_sys_listxattr+0x108/0x230 fs/xattr.c:816
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x61/0xcb

The buggy address belongs to the object at ffff8880759eb780
 which belongs to the cache jfs_ip of size 2240
The buggy address is located 0 bytes to the right of
 2240-byte region [ffff8880759eb780, ffff8880759ec040)
The buggy address belongs to the page:
page:ffffea0001d67a00 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x759e8
head:ffffea0001d67a00 order:3 compound_mapcount:0 compound_pincount:0
flags: 0xfff00000010200(slab|head|node=0|zone=1|lastcpupid=0x7ff)
raw: 00fff00000010200 0000000000000000 dead000000000122 ffff8881460908c0
raw: 0000000000000000 00000000800d000d 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 3, migratetype Reclaimable, gfp_mask 0xd2050(__GFP_IO|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_RECLAIMABLE), pid 3504, ts 42560322985, free_ts 10984527890
 prep_new_page mm/page_alloc.c:2426 [inline]
 get_page_from_freelist+0x322a/0x33c0 mm/page_alloc.c:4159
 __alloc_pages+0x272/0x700 mm/page_alloc.c:5421
 alloc_slab_page mm/slub.c:1775 [inline]
 allocate_slab mm/slub.c:1912 [inline]
 new_slab+0xbb/0x4b0 mm/slub.c:1975
 ___slab_alloc+0x6f6/0xe10 mm/slub.c:3008
 __slab_alloc mm/slub.c:3095 [inline]
 slab_alloc_node mm/slub.c:3186 [inline]
 slab_alloc mm/slub.c:3228 [inline]
 kmem_cache_alloc+0x18e/0x280 mm/slub.c:3233
 jfs_alloc_inode+0x17/0x50 fs/jfs/super.c:105
 alloc_inode fs/inode.c:236 [inline]
 new_inode_pseudo+0x60/0x210 fs/inode.c:937
 new_inode+0x25/0x1d0 fs/inode.c:966
 jfs_fill_super+0x404/0xc70 fs/jfs/super.c:549
 mount_bdev+0x2c9/0x3f0 fs/super.c:1378
 legacy_get_tree+0xeb/0x180 fs/fs_context.c:610
 vfs_get_tree+0x88/0x270 fs/super.c:1508
 do_new_mount+0x28b/0xae0 fs/namespace.c:2994
 do_mount fs/namespace.c:3337 [inline]
 __do_sys_mount fs/namespace.c:3545 [inline]
 __se_sys_mount+0x2d5/0x3c0 fs/namespace.c:3522
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x61/0xcb
page last free stack trace:
 reset_page_owner include/linux/page_owner.h:24 [inline]
 free_pages_prepare mm/page_alloc.c:1340 [inline]
 free_pcp_prepare mm/page_alloc.c:1391 [inline]
 free_unref_page_prepare+0xc34/0xcf0 mm/page_alloc.c:3317
 free_unref_page+0x95/0x2d0 mm/page_alloc.c:3396
 free_contig_range+0x95/0xf0 mm/page_alloc.c:9340
 destroy_args+0xfe/0x97f mm/debug_vm_pgtable.c:1018
 debug_vm_pgtable+0x40d/0x462 mm/debug_vm_pgtable.c:1331
 do_one_initcall+0x22b/0x7a0 init/main.c:1306
 do_initcall_level+0x157/0x207 init/main.c:1379
 do_initcalls+0x49/0x86 init/main.c:1395
 kernel_init_freeable+0x43c/0x5c5 init/main.c:1619
 kernel_init+0x19/0x290 init/main.c:1510
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:298

Memory state around the buggy address:
 ffff8880759ebf00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffff8880759ebf80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
>ffff8880759ec000: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc
                                           ^
 ffff8880759ec080: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
 ffff8880759ec100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
==================================================================

Crashes (18):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/06/24 03:29 linux-5.15.y f67653019430 79782afc .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan KASAN: slab-out-of-bounds Read in ea_get
2023/06/01 08:50 linux-5.15.y 0ab06468cbd1 babc4389 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/05/03 01:40 linux-5.15.y 284087d4f7d5 ddfc15a1 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/05/03 01:21 linux-5.15.y 284087d4f7d5 ddfc15a1 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/05/02 20:21 linux-5.15.y 284087d4f7d5 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/05/02 20:21 linux-5.15.y 284087d4f7d5 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/05/01 05:34 linux-5.15.y b925f60c6ee7 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/05/01 00:40 linux-5.15.y b925f60c6ee7 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/05/01 00:40 linux-5.15.y b925f60c6ee7 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/04/30 16:15 linux-5.15.y b925f60c6ee7 3ce4924c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/04/30 16:14 linux-5.15.y b925f60c6ee7 3ce4924c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/04/29 23:13 linux-5.15.y b925f60c6ee7 f10afd69 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/04/29 20:30 linux-5.15.y b925f60c6ee7 f10afd69 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/04/29 20:30 linux-5.15.y b925f60c6ee7 f10afd69 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/04/29 19:01 linux-5.15.y b925f60c6ee7 27e33c58 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/04/29 18:44 linux-5.15.y b925f60c6ee7 27e33c58 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2024/04/29 18:44 linux-5.15.y b925f60c6ee7 27e33c58 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
2023/06/01 07:38 linux-5.15.y 0ab06468cbd1 babc4389 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 KASAN: slab-out-of-bounds Read in ea_get
* Struck through repros no longer work on HEAD.