Date
July 22, 2025, 5:13 a.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 32.627828] ================================================================== [ 32.627994] BUG: KASAN: slab-use-after-free in kasan_strings+0x95c/0xb00 [ 32.628073] Read of size 1 at addr fff00000c9227a10 by task kunit_try_catch/290 [ 32.628397] [ 32.628460] CPU: 1 UID: 0 PID: 290 Comm: kunit_try_catch Tainted: G B W N 6.16.0-rc7-next-20250722 #1 PREEMPT [ 32.628850] Tainted: [B]=BAD_PAGE, [W]=WARN, [N]=TEST [ 32.628902] Hardware name: linux,dummy-virt (DT) [ 32.629014] Call trace: [ 32.629077] show_stack+0x20/0x38 (C) [ 32.629230] dump_stack_lvl+0x8c/0xd0 [ 32.629354] print_report+0x118/0x5e8 [ 32.629501] kasan_report+0xdc/0x128 [ 32.629552] __asan_report_load1_noabort+0x20/0x30 [ 32.629603] kasan_strings+0x95c/0xb00 [ 32.630023] kunit_try_run_case+0x170/0x3f0 [ 32.630146] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 32.630308] kthread+0x328/0x630 [ 32.630406] ret_from_fork+0x10/0x20 [ 32.630589] [ 32.630648] Allocated by task 290: [ 32.630680] kasan_save_stack+0x3c/0x68 [ 32.631032] kasan_save_track+0x20/0x40 [ 32.631107] kasan_save_alloc_info+0x40/0x58 [ 32.631220] __kasan_kmalloc+0xd4/0xd8 [ 32.631297] __kmalloc_cache_noprof+0x16c/0x3c0 [ 32.631383] kasan_strings+0xc8/0xb00 [ 32.631425] kunit_try_run_case+0x170/0x3f0 [ 32.631599] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 32.631676] kthread+0x328/0x630 [ 32.631712] ret_from_fork+0x10/0x20 [ 32.632185] [ 32.632249] Freed by task 290: [ 32.632339] kasan_save_stack+0x3c/0x68 [ 32.632389] kasan_save_track+0x20/0x40 [ 32.632474] kasan_save_free_info+0x4c/0x78 [ 32.632869] __kasan_slab_free+0x6c/0x98 [ 32.632940] kfree+0x214/0x3c8 [ 32.633077] kasan_strings+0x24c/0xb00 [ 32.633169] kunit_try_run_case+0x170/0x3f0 [ 32.633302] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 32.633381] kthread+0x328/0x630 [ 32.633418] ret_from_fork+0x10/0x20 [ 32.633746] [ 32.633831] The buggy address belongs to the object at fff00000c9227a00 [ 32.633831] which belongs to the cache kmalloc-32 of size 32 [ 32.633963] The buggy address is located 16 bytes inside of [ 32.633963] freed 32-byte region [fff00000c9227a00, fff00000c9227a20) [ 32.634076] [ 32.634166] The buggy address belongs to the physical page: [ 32.634266] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x109227 [ 32.634661] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 32.634855] page_type: f5(slab) [ 32.634924] raw: 0bfffe0000000000 fff00000c0001780 dead000000000122 0000000000000000 [ 32.635123] raw: 0000000000000000 0000000080400040 00000000f5000000 0000000000000000 [ 32.635211] page dumped because: kasan: bad access detected [ 32.635344] [ 32.635365] Memory state around the buggy address: [ 32.635400] fff00000c9227900: 00 00 00 fc fc fc fc fc 00 00 00 fc fc fc fc fc [ 32.635782] fff00000c9227980: 00 00 07 fc fc fc fc fc 00 00 00 fc fc fc fc fc [ 32.636155] >fff00000c9227a00: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 32.636224] ^ [ 32.636325] fff00000c9227a80: fa fb fb fb fc fc fc fc 00 00 00 fc fc fc fc fc [ 32.636432] fff00000c9227b00: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 32.636590] ==================================================================
[ 27.014017] ================================================================== [ 27.014287] BUG: KASAN: slab-use-after-free in kasan_strings+0xcbc/0xe80 [ 27.014502] Read of size 1 at addr ffff888106006150 by task kunit_try_catch/307 [ 27.015010] [ 27.015123] CPU: 1 UID: 0 PID: 307 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc7-next-20250722 #1 PREEMPT(voluntary) [ 27.015180] Tainted: [B]=BAD_PAGE, [N]=TEST [ 27.015193] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 27.015214] Call Trace: [ 27.015228] <TASK> [ 27.015242] dump_stack_lvl+0x73/0xb0 [ 27.015270] print_report+0xd1/0x640 [ 27.015294] ? __virt_addr_valid+0x1db/0x2d0 [ 27.015319] ? kasan_strings+0xcbc/0xe80 [ 27.015340] ? kasan_complete_mode_report_info+0x64/0x200 [ 27.015367] ? kasan_strings+0xcbc/0xe80 [ 27.015389] kasan_report+0x141/0x180 [ 27.015413] ? kasan_strings+0xcbc/0xe80 [ 27.015440] __asan_report_load1_noabort+0x18/0x20 [ 27.015477] kasan_strings+0xcbc/0xe80 [ 27.015498] ? trace_hardirqs_on+0x37/0xe0 [ 27.015522] ? __pfx_kasan_strings+0x10/0x10 [ 27.015543] ? finish_task_switch.isra.0+0x153/0x700 [ 27.015566] ? __switch_to+0x47/0xf80 [ 27.015591] ? __schedule+0x10da/0x2b60 [ 27.015617] ? __pfx_read_tsc+0x10/0x10 [ 27.015639] ? ktime_get_ts64+0x86/0x230 [ 27.015664] kunit_try_run_case+0x1a5/0x480 [ 27.015690] ? __pfx_kunit_try_run_case+0x10/0x10 [ 27.015715] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 27.015740] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 27.015766] ? __kthread_parkme+0x82/0x180 [ 27.015786] ? preempt_count_sub+0x50/0x80 [ 27.015810] ? __pfx_kunit_try_run_case+0x10/0x10 [ 27.015846] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 27.015871] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 27.015896] kthread+0x337/0x6f0 [ 27.015916] ? trace_preempt_on+0x20/0xc0 [ 27.015939] ? __pfx_kthread+0x10/0x10 [ 27.015960] ? _raw_spin_unlock_irq+0x47/0x80 [ 27.015984] ? calculate_sigpending+0x7b/0xa0 [ 27.016008] ? __pfx_kthread+0x10/0x10 [ 27.016031] ret_from_fork+0x116/0x1d0 [ 27.016051] ? __pfx_kthread+0x10/0x10 [ 27.016071] ret_from_fork_asm+0x1a/0x30 [ 27.016103] </TASK> [ 27.016113] [ 27.023956] Allocated by task 307: [ 27.024128] kasan_save_stack+0x45/0x70 [ 27.024337] kasan_save_track+0x18/0x40 [ 27.024648] kasan_save_alloc_info+0x3b/0x50 [ 27.024887] __kasan_kmalloc+0xb7/0xc0 [ 27.025061] __kmalloc_cache_noprof+0x189/0x420 [ 27.025290] kasan_strings+0xc0/0xe80 [ 27.025499] kunit_try_run_case+0x1a5/0x480 [ 27.025702] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 27.025951] kthread+0x337/0x6f0 [ 27.026104] ret_from_fork+0x116/0x1d0 [ 27.026308] ret_from_fork_asm+0x1a/0x30 [ 27.026655] [ 27.026752] Freed by task 307: [ 27.026901] kasan_save_stack+0x45/0x70 [ 27.027082] kasan_save_track+0x18/0x40 [ 27.027287] kasan_save_free_info+0x3f/0x60 [ 27.027434] __kasan_slab_free+0x56/0x70 [ 27.027686] kfree+0x222/0x3f0 [ 27.027867] kasan_strings+0x2aa/0xe80 [ 27.028047] kunit_try_run_case+0x1a5/0x480 [ 27.028277] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 27.028576] kthread+0x337/0x6f0 [ 27.028708] ret_from_fork+0x116/0x1d0 [ 27.028902] ret_from_fork_asm+0x1a/0x30 [ 27.029087] [ 27.029155] The buggy address belongs to the object at ffff888106006140 [ 27.029155] which belongs to the cache kmalloc-32 of size 32 [ 27.029731] The buggy address is located 16 bytes inside of [ 27.029731] freed 32-byte region [ffff888106006140, ffff888106006160) [ 27.030254] [ 27.030345] The buggy address belongs to the physical page: [ 27.030653] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x106006 [ 27.030980] flags: 0x200000000000000(node=0|zone=2) [ 27.031207] page_type: f5(slab) [ 27.031351] raw: 0200000000000000 ffff888100041780 dead000000000122 0000000000000000 [ 27.031803] raw: 0000000000000000 0000000080400040 00000000f5000000 0000000000000000 [ 27.032057] page dumped because: kasan: bad access detected [ 27.032239] [ 27.032310] Memory state around the buggy address: [ 27.032465] ffff888106006000: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 27.032683] ffff888106006080: 00 00 00 fc fc fc fc fc 00 00 00 fc fc fc fc fc [ 27.032953] >ffff888106006100: 00 00 07 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 27.033695] ^ [ 27.033980] ffff888106006180: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 27.034504] ffff888106006200: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 27.034822] ==================================================================