Date
July 15, 2025, 2:09 p.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 20.138359] ================================================================== [ 20.138434] BUG: KASAN: slab-use-after-free in strlen+0xa8/0xb0 [ 20.138483] Read of size 1 at addr fff00000c59caad0 by task kunit_try_catch/261 [ 20.138698] [ 20.138872] CPU: 0 UID: 0 PID: 261 Comm: kunit_try_catch Tainted: G B N 6.15.7-rc1 #1 PREEMPT [ 20.138970] Tainted: [B]=BAD_PAGE, [N]=TEST [ 20.139027] Hardware name: linux,dummy-virt (DT) [ 20.139100] Call trace: [ 20.139126] show_stack+0x20/0x38 (C) [ 20.139178] dump_stack_lvl+0x8c/0xd0 [ 20.139240] print_report+0x118/0x5d0 [ 20.139288] kasan_report+0xdc/0x128 [ 20.139335] __asan_report_load1_noabort+0x20/0x30 [ 20.139402] strlen+0xa8/0xb0 [ 20.139459] kasan_strings+0x418/0xb00 [ 20.139510] kunit_try_run_case+0x170/0x3f0 [ 20.139563] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 20.139619] kthread+0x328/0x630 [ 20.139675] ret_from_fork+0x10/0x20 [ 20.139726] [ 20.139761] Allocated by task 261: [ 20.139800] kasan_save_stack+0x3c/0x68 [ 20.139843] kasan_save_track+0x20/0x40 [ 20.139881] kasan_save_alloc_info+0x40/0x58 [ 20.139924] __kasan_kmalloc+0xd4/0xd8 [ 20.139970] __kmalloc_cache_noprof+0x16c/0x3c0 [ 20.140011] kasan_strings+0xc8/0xb00 [ 20.140052] kunit_try_run_case+0x170/0x3f0 [ 20.140093] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 20.140140] kthread+0x328/0x630 [ 20.140184] ret_from_fork+0x10/0x20 [ 20.140453] [ 20.140479] Freed by task 261: [ 20.140508] kasan_save_stack+0x3c/0x68 [ 20.140715] kasan_save_track+0x20/0x40 [ 20.141068] kasan_save_free_info+0x4c/0x78 [ 20.141180] __kasan_slab_free+0x6c/0x98 [ 20.141404] kfree+0x214/0x3c8 [ 20.141755] kasan_strings+0x24c/0xb00 [ 20.141810] kunit_try_run_case+0x170/0x3f0 [ 20.141853] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 20.142245] kthread+0x328/0x630 [ 20.142799] ret_from_fork+0x10/0x20 [ 20.143185] [ 20.143242] The buggy address belongs to the object at fff00000c59caac0 [ 20.143242] which belongs to the cache kmalloc-32 of size 32 [ 20.143401] The buggy address is located 16 bytes inside of [ 20.143401] freed 32-byte region [fff00000c59caac0, fff00000c59caae0) [ 20.143716] [ 20.143883] The buggy address belongs to the physical page: [ 20.144014] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1059ca [ 20.144086] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 20.144158] page_type: f5(slab) [ 20.144199] raw: 0bfffe0000000000 fff00000c0001780 dead000000000122 0000000000000000 [ 20.144531] raw: 0000000000000000 0000000080400040 00000000f5000000 0000000000000000 [ 20.144670] page dumped because: kasan: bad access detected [ 20.144747] [ 20.144780] Memory state around the buggy address: [ 20.145103] fff00000c59ca980: 00 00 00 fc fc fc fc fc 00 00 00 fc fc fc fc fc [ 20.145190] fff00000c59caa00: 00 00 00 fc fc fc fc fc 00 00 07 fc fc fc fc fc [ 20.145251] >fff00000c59caa80: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 20.145565] ^ [ 20.145668] fff00000c59cab00: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 20.145752] fff00000c59cab80: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 20.145796] ==================================================================
[ 12.952760] ================================================================== [ 12.953057] BUG: KASAN: slab-use-after-free in strlen+0x8f/0xb0 [ 12.953349] Read of size 1 at addr ffff8881022482d0 by task kunit_try_catch/278 [ 12.953636] [ 12.953810] CPU: 0 UID: 0 PID: 278 Comm: kunit_try_catch Tainted: G B N 6.15.7-rc1 #1 PREEMPT(voluntary) [ 12.953851] Tainted: [B]=BAD_PAGE, [N]=TEST [ 12.953863] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 12.953895] Call Trace: [ 12.953906] <TASK> [ 12.953919] dump_stack_lvl+0x73/0xb0 [ 12.953941] print_report+0xd1/0x610 [ 12.953962] ? __virt_addr_valid+0x1db/0x2d0 [ 12.953982] ? strlen+0x8f/0xb0 [ 12.953999] ? kasan_complete_mode_report_info+0x64/0x200 [ 12.954021] ? strlen+0x8f/0xb0 [ 12.954039] kasan_report+0x141/0x180 [ 12.954061] ? strlen+0x8f/0xb0 [ 12.954084] __asan_report_load1_noabort+0x18/0x20 [ 12.954104] strlen+0x8f/0xb0 [ 12.954123] kasan_strings+0x57b/0xe80 [ 12.954142] ? trace_hardirqs_on+0x37/0xe0 [ 12.954164] ? __pfx_kasan_strings+0x10/0x10 [ 12.954184] ? finish_task_switch.isra.0+0x153/0x700 [ 12.954205] ? __switch_to+0x5d9/0xf60 [ 12.954224] ? dequeue_task_fair+0x166/0x4e0 [ 12.954247] ? __schedule+0x10cc/0x2b60 [ 12.954268] ? __pfx_read_tsc+0x10/0x10 [ 12.954287] ? ktime_get_ts64+0x86/0x230 [ 12.954310] kunit_try_run_case+0x1a5/0x480 [ 12.954329] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.954347] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 12.954369] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 12.954392] ? __kthread_parkme+0x82/0x180 [ 12.954412] ? preempt_count_sub+0x50/0x80 [ 12.954434] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.954456] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.954478] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 12.954500] kthread+0x337/0x6f0 [ 12.954516] ? trace_preempt_on+0x20/0xc0 [ 12.954537] ? __pfx_kthread+0x10/0x10 [ 12.954554] ? _raw_spin_unlock_irq+0x47/0x80 [ 12.954575] ? calculate_sigpending+0x7b/0xa0 [ 12.954595] ? __pfx_kthread+0x10/0x10 [ 12.954613] ret_from_fork+0x41/0x80 [ 12.954632] ? __pfx_kthread+0x10/0x10 [ 12.954649] ret_from_fork_asm+0x1a/0x30 [ 12.954679] </TASK> [ 12.954688] [ 12.962804] Allocated by task 278: [ 12.962985] kasan_save_stack+0x45/0x70 [ 12.963162] kasan_save_track+0x18/0x40 [ 12.963322] kasan_save_alloc_info+0x3b/0x50 [ 12.963465] __kasan_kmalloc+0xb7/0xc0 [ 12.963595] __kmalloc_cache_noprof+0x189/0x420 [ 12.963744] kasan_strings+0xc0/0xe80 [ 12.963873] kunit_try_run_case+0x1a5/0x480 [ 12.964084] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.964393] kthread+0x337/0x6f0 [ 12.964559] ret_from_fork+0x41/0x80 [ 12.964736] ret_from_fork_asm+0x1a/0x30 [ 12.965209] [ 12.965315] Freed by task 278: [ 12.965477] kasan_save_stack+0x45/0x70 [ 12.965643] kasan_save_track+0x18/0x40 [ 12.965941] kasan_save_free_info+0x3f/0x60 [ 12.966138] __kasan_slab_free+0x56/0x70 [ 12.966328] kfree+0x222/0x3f0 [ 12.966468] kasan_strings+0x2aa/0xe80 [ 12.966648] kunit_try_run_case+0x1a5/0x480 [ 12.966923] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.967113] kthread+0x337/0x6f0 [ 12.967228] ret_from_fork+0x41/0x80 [ 12.967354] ret_from_fork_asm+0x1a/0x30 [ 12.967514] [ 12.967608] The buggy address belongs to the object at ffff8881022482c0 [ 12.967608] which belongs to the cache kmalloc-32 of size 32 [ 12.968201] The buggy address is located 16 bytes inside of [ 12.968201] freed 32-byte region [ffff8881022482c0, ffff8881022482e0) [ 12.968690] [ 12.968759] The buggy address belongs to the physical page: [ 12.968939] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x102248 [ 12.969183] flags: 0x200000000000000(node=0|zone=2) [ 12.969342] page_type: f5(slab) [ 12.969460] raw: 0200000000000000 ffff888100041780 dead000000000122 0000000000000000 [ 12.970131] raw: 0000000000000000 0000000080400040 00000000f5000000 0000000000000000 [ 12.970467] page dumped because: kasan: bad access detected [ 12.970717] [ 12.970808] Memory state around the buggy address: [ 12.971043] ffff888102248180: fa fb fb fb fc fc fc fc 00 00 07 fc fc fc fc fc [ 12.971499] ffff888102248200: 00 00 00 fc fc fc fc fc 00 00 00 fc fc fc fc fc [ 12.971786] >ffff888102248280: 00 00 07 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 12.972116] ^ [ 12.972364] ffff888102248300: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 12.972624] ffff888102248380: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 12.973003] ==================================================================