Date
July 18, 2025, 11:11 p.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 17.658732] ================================================================== [ 17.658803] BUG: KASAN: slab-use-after-free in strcmp+0xc0/0xc8 [ 17.658944] Read of size 1 at addr fff00000c7848510 by task kunit_try_catch/259 [ 17.659004] [ 17.659318] CPU: 0 UID: 0 PID: 259 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT [ 17.659432] Tainted: [B]=BAD_PAGE, [N]=TEST [ 17.659521] Hardware name: linux,dummy-virt (DT) [ 17.659588] Call trace: [ 17.659616] show_stack+0x20/0x38 (C) [ 17.659908] dump_stack_lvl+0x8c/0xd0 [ 17.659977] print_report+0x118/0x5d0 [ 17.660028] kasan_report+0xdc/0x128 [ 17.660170] __asan_report_load1_noabort+0x20/0x30 [ 17.660232] strcmp+0xc0/0xc8 [ 17.660301] kasan_strings+0x340/0xb00 [ 17.660588] kunit_try_run_case+0x170/0x3f0 [ 17.660650] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 17.660801] kthread+0x328/0x630 [ 17.660854] ret_from_fork+0x10/0x20 [ 17.661227] [ 17.661304] Allocated by task 259: [ 17.661400] kasan_save_stack+0x3c/0x68 [ 17.661643] kasan_save_track+0x20/0x40 [ 17.661952] kasan_save_alloc_info+0x40/0x58 [ 17.662077] __kasan_kmalloc+0xd4/0xd8 [ 17.662213] __kmalloc_cache_noprof+0x16c/0x3c0 [ 17.662270] kasan_strings+0xc8/0xb00 [ 17.662460] kunit_try_run_case+0x170/0x3f0 [ 17.662530] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 17.662576] kthread+0x328/0x630 [ 17.662622] ret_from_fork+0x10/0x20 [ 17.662661] [ 17.662683] Freed by task 259: [ 17.662723] kasan_save_stack+0x3c/0x68 [ 17.662763] kasan_save_track+0x20/0x40 [ 17.662825] kasan_save_free_info+0x4c/0x78 [ 17.662866] __kasan_slab_free+0x6c/0x98 [ 17.662921] kfree+0x214/0x3c8 [ 17.662956] kasan_strings+0x24c/0xb00 [ 17.662994] kunit_try_run_case+0x170/0x3f0 [ 17.663050] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 17.663095] kthread+0x328/0x630 [ 17.663138] ret_from_fork+0x10/0x20 [ 17.663177] [ 17.663200] The buggy address belongs to the object at fff00000c7848500 [ 17.663200] which belongs to the cache kmalloc-32 of size 32 [ 17.663274] The buggy address is located 16 bytes inside of [ 17.663274] freed 32-byte region [fff00000c7848500, fff00000c7848520) [ 17.663349] [ 17.663372] The buggy address belongs to the physical page: [ 17.663503] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x107848 [ 17.664046] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 17.664128] page_type: f5(slab) [ 17.664314] raw: 0bfffe0000000000 fff00000c0001780 dead000000000122 0000000000000000 [ 17.664565] raw: 0000000000000000 0000000080400040 00000000f5000000 0000000000000000 [ 17.664621] page dumped because: kasan: bad access detected [ 17.664783] [ 17.664827] Memory state around the buggy address: [ 17.665115] fff00000c7848400: 00 00 00 fc fc fc fc fc 00 00 00 fc fc fc fc fc [ 17.665199] fff00000c7848480: 00 00 00 fc fc fc fc fc 00 00 07 fc fc fc fc fc [ 17.665519] >fff00000c7848500: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 17.665603] ^ [ 17.665658] fff00000c7848580: fa fb fb fb fc fc fc fc 00 00 00 fc fc fc fc fc [ 17.665728] fff00000c7848600: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 17.665768] ==================================================================
[ 14.098976] ================================================================== [ 14.100930] BUG: KASAN: slab-use-after-free in strcmp+0xb0/0xc0 [ 14.101588] Read of size 1 at addr ffff888103a23e10 by task kunit_try_catch/278 [ 14.102863] [ 14.103051] CPU: 0 UID: 0 PID: 278 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT(voluntary) [ 14.103101] Tainted: [B]=BAD_PAGE, [N]=TEST [ 14.103417] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 14.103444] Call Trace: [ 14.103480] <TASK> [ 14.103498] dump_stack_lvl+0x73/0xb0 [ 14.103531] print_report+0xd1/0x610 [ 14.103555] ? __virt_addr_valid+0x1db/0x2d0 [ 14.103578] ? strcmp+0xb0/0xc0 [ 14.103595] ? kasan_complete_mode_report_info+0x64/0x200 [ 14.103619] ? strcmp+0xb0/0xc0 [ 14.103635] kasan_report+0x141/0x180 [ 14.103657] ? strcmp+0xb0/0xc0 [ 14.103678] __asan_report_load1_noabort+0x18/0x20 [ 14.103703] strcmp+0xb0/0xc0 [ 14.103721] kasan_strings+0x431/0xe80 [ 14.103741] ? trace_hardirqs_on+0x37/0xe0 [ 14.103764] ? __pfx_kasan_strings+0x10/0x10 [ 14.103784] ? finish_task_switch.isra.0+0x153/0x700 [ 14.103806] ? __switch_to+0x47/0xf50 [ 14.103832] ? __schedule+0x10cc/0x2b60 [ 14.103855] ? __pfx_read_tsc+0x10/0x10 [ 14.103876] ? ktime_get_ts64+0x86/0x230 [ 14.103900] kunit_try_run_case+0x1a5/0x480 [ 14.103926] ? __pfx_kunit_try_run_case+0x10/0x10 [ 14.103948] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 14.103972] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 14.104016] ? __kthread_parkme+0x82/0x180 [ 14.104037] ? preempt_count_sub+0x50/0x80 [ 14.104060] ? __pfx_kunit_try_run_case+0x10/0x10 [ 14.104084] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 14.104108] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 14.104133] kthread+0x337/0x6f0 [ 14.104152] ? trace_preempt_on+0x20/0xc0 [ 14.104173] ? __pfx_kthread+0x10/0x10 [ 14.104192] ? _raw_spin_unlock_irq+0x47/0x80 [ 14.104214] ? calculate_sigpending+0x7b/0xa0 [ 14.104238] ? __pfx_kthread+0x10/0x10 [ 14.104258] ret_from_fork+0x116/0x1d0 [ 14.104278] ? __pfx_kthread+0x10/0x10 [ 14.104309] ret_from_fork_asm+0x1a/0x30 [ 14.104338] </TASK> [ 14.104348] [ 14.116052] Allocated by task 278: [ 14.116197] kasan_save_stack+0x45/0x70 [ 14.116356] kasan_save_track+0x18/0x40 [ 14.116523] kasan_save_alloc_info+0x3b/0x50 [ 14.116672] __kasan_kmalloc+0xb7/0xc0 [ 14.116899] __kmalloc_cache_noprof+0x189/0x420 [ 14.117131] kasan_strings+0xc0/0xe80 [ 14.117325] kunit_try_run_case+0x1a5/0x480 [ 14.117626] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 14.117853] kthread+0x337/0x6f0 [ 14.118042] ret_from_fork+0x116/0x1d0 [ 14.118212] ret_from_fork_asm+0x1a/0x30 [ 14.118388] [ 14.118517] Freed by task 278: [ 14.118667] kasan_save_stack+0x45/0x70 [ 14.118923] kasan_save_track+0x18/0x40 [ 14.119127] kasan_save_free_info+0x3f/0x60 [ 14.119335] __kasan_slab_free+0x56/0x70 [ 14.119515] kfree+0x222/0x3f0 [ 14.119670] kasan_strings+0x2aa/0xe80 [ 14.119814] kunit_try_run_case+0x1a5/0x480 [ 14.120033] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 14.120239] kthread+0x337/0x6f0 [ 14.120368] ret_from_fork+0x116/0x1d0 [ 14.120499] ret_from_fork_asm+0x1a/0x30 [ 14.120636] [ 14.120708] The buggy address belongs to the object at ffff888103a23e00 [ 14.120708] which belongs to the cache kmalloc-32 of size 32 [ 14.121255] The buggy address is located 16 bytes inside of [ 14.121255] freed 32-byte region [ffff888103a23e00, ffff888103a23e20) [ 14.121736] [ 14.121806] The buggy address belongs to the physical page: [ 14.121977] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x103a23 [ 14.122217] flags: 0x200000000000000(node=0|zone=2) [ 14.122569] page_type: f5(slab) [ 14.122746] raw: 0200000000000000 ffff888100041780 dead000000000122 0000000000000000 [ 14.123091] raw: 0000000000000000 0000000000400040 00000000f5000000 0000000000000000 [ 14.123441] page dumped because: kasan: bad access detected [ 14.123808] [ 14.123896] Memory state around the buggy address: [ 14.124110] ffff888103a23d00: 00 00 07 fc fc fc fc fc 00 00 00 fc fc fc fc fc [ 14.124401] ffff888103a23d80: 00 00 00 fc fc fc fc fc 00 00 07 fc fc fc fc fc [ 14.124760] >ffff888103a23e00: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 14.124982] ^ [ 14.125111] ffff888103a23e80: fa fb fb fb fc fc fc fc 00 00 00 fc fc fc fc fc [ 14.125336] ffff888103a23f00: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 14.125650] ==================================================================