Date
May 12, 2025, 6:12 p.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 20.811335] ================================================================== [ 20.811722] BUG: KASAN: slab-use-after-free in strlen+0xa8/0xb0 [ 20.811991] Read of size 1 at addr fff00000c66e72d0 by task kunit_try_catch/248 [ 20.812254] [ 20.812392] CPU: 1 UID: 0 PID: 248 Comm: kunit_try_catch Tainted: G B N 6.14.7-rc1 #1 [ 20.812500] Tainted: [B]=BAD_PAGE, [N]=TEST [ 20.812537] Hardware name: linux,dummy-virt (DT) [ 20.812580] Call trace: [ 20.812612] show_stack+0x20/0x38 (C) [ 20.812680] dump_stack_lvl+0x8c/0xd0 [ 20.813493] print_report+0x118/0x608 [ 20.813775] kasan_report+0xdc/0x128 [ 20.813849] __asan_report_load1_noabort+0x20/0x30 [ 20.813911] strlen+0xa8/0xb0 [ 20.813965] kasan_strings+0x304/0x8d8 [ 20.814022] kunit_try_run_case+0x170/0x3f0 [ 20.814113] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 20.814181] kthread+0x318/0x620 [ 20.814238] ret_from_fork+0x10/0x20 [ 20.814299] [ 20.817660] Allocated by task 248: [ 20.818029] kasan_save_stack+0x3c/0x68 [ 20.818374] kasan_save_track+0x20/0x40 [ 20.818632] kasan_save_alloc_info+0x40/0x58 [ 20.818972] __kasan_kmalloc+0xd4/0xd8 [ 20.819240] __kmalloc_cache_noprof+0x15c/0x3c0 [ 20.819535] kasan_strings+0xb0/0x8d8 [ 20.819731] kunit_try_run_case+0x170/0x3f0 [ 20.820126] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 20.820475] kthread+0x318/0x620 [ 20.820647] ret_from_fork+0x10/0x20 [ 20.821213] [ 20.821430] Freed by task 248: [ 20.821703] kasan_save_stack+0x3c/0x68 [ 20.822084] kasan_save_track+0x20/0x40 [ 20.822401] kasan_save_free_info+0x4c/0x78 [ 20.822887] __kasan_slab_free+0x6c/0x98 [ 20.823200] kfree+0x214/0x3c8 [ 20.823495] kasan_strings+0x124/0x8d8 [ 20.823752] kunit_try_run_case+0x170/0x3f0 [ 20.824048] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 20.824399] kthread+0x318/0x620 [ 20.824620] ret_from_fork+0x10/0x20 [ 20.824938] [ 20.825135] The buggy address belongs to the object at fff00000c66e72c0 [ 20.825135] which belongs to the cache kmalloc-32 of size 32 [ 20.825725] The buggy address is located 16 bytes inside of [ 20.825725] freed 32-byte region [fff00000c66e72c0, fff00000c66e72e0) [ 20.826363] [ 20.826705] The buggy address belongs to the physical page: [ 20.827024] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1066e7 [ 20.827485] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 20.827925] page_type: f5(slab) [ 20.828235] raw: 0bfffe0000000000 fff00000c0001780 dead000000000122 0000000000000000 [ 20.828614] raw: 0000000000000000 0000000080400040 00000000f5000000 0000000000000000 [ 20.828973] page dumped because: kasan: bad access detected [ 20.829315] [ 20.829455] Memory state around the buggy address: [ 20.829756] fff00000c66e7180: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 20.830107] fff00000c66e7200: fa fb fb fb fc fc fc fc 00 00 07 fc fc fc fc fc [ 20.830859] >fff00000c66e7280: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 20.831136] ^ [ 20.831358] fff00000c66e7300: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 20.831998] fff00000c66e7380: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 20.832559] ==================================================================
[ 14.362334] ================================================================== [ 14.363148] BUG: KASAN: slab-use-after-free in strlen+0x8f/0xb0 [ 14.364013] Read of size 1 at addr ffff888101b3b550 by task kunit_try_catch/267 [ 14.364806] [ 14.364922] CPU: 1 UID: 0 PID: 267 Comm: kunit_try_catch Tainted: G B N 6.14.7-rc1 #1 [ 14.364972] Tainted: [B]=BAD_PAGE, [N]=TEST [ 14.364984] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 14.365009] Call Trace: [ 14.365030] <TASK> [ 14.365051] dump_stack_lvl+0x73/0xb0 [ 14.365082] print_report+0xd1/0x650 [ 14.365104] ? __virt_addr_valid+0x1db/0x2d0 [ 14.365127] ? strlen+0x8f/0xb0 [ 14.365147] ? kasan_complete_mode_report_info+0x64/0x200 [ 14.365173] ? strlen+0x8f/0xb0 [ 14.365192] kasan_report+0x140/0x180 [ 14.365212] ? strlen+0x8f/0xb0 [ 14.365236] __asan_report_load1_noabort+0x18/0x20 [ 14.365258] strlen+0x8f/0xb0 [ 14.365279] kasan_strings+0x425/0xb60 [ 14.365299] ? __pfx_kasan_strings+0x10/0x10 [ 14.365321] ? ktime_get_ts64+0xfb/0x230 [ 14.365345] ? ktime_get_ts64+0x86/0x230 [ 14.365369] kunit_try_run_case+0x1a6/0x480 [ 14.365392] ? __pfx_kunit_try_run_case+0x10/0x10 [ 14.365413] ? _raw_spin_lock_irqsave+0xa2/0x110 [ 14.365434] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 14.365459] ? __kthread_parkme+0x82/0x160 [ 14.365482] ? preempt_count_sub+0x50/0x80 [ 14.365507] ? __pfx_kunit_try_run_case+0x10/0x10 [ 14.365528] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 14.365554] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 14.365579] kthread+0x324/0x6e0 [ 14.365600] ? trace_preempt_on+0x20/0xc0 [ 14.365623] ? __pfx_kthread+0x10/0x10 [ 14.365645] ? _raw_spin_unlock_irq+0x47/0x80 [ 14.365668] ? calculate_sigpending+0x7b/0xa0 [ 14.365689] ? __pfx_kthread+0x10/0x10 [ 14.365711] ret_from_fork+0x41/0x80 [ 14.365732] ? __pfx_kthread+0x10/0x10 [ 14.365759] ret_from_fork_asm+0x1a/0x30 [ 14.365791] </TASK> [ 14.365802] [ 14.375091] Allocated by task 267: [ 14.375341] kasan_save_stack+0x45/0x70 [ 14.375561] kasan_save_track+0x18/0x40 [ 14.375734] kasan_save_alloc_info+0x3b/0x50 [ 14.375915] __kasan_kmalloc+0xb7/0xc0 [ 14.376102] __kmalloc_cache_noprof+0x18a/0x420 [ 14.376415] kasan_strings+0xb9/0xb60 [ 14.376568] kunit_try_run_case+0x1a6/0x480 [ 14.376714] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 14.377002] kthread+0x324/0x6e0 [ 14.377210] ret_from_fork+0x41/0x80 [ 14.377397] ret_from_fork_asm+0x1a/0x30 [ 14.377574] [ 14.377645] Freed by task 267: [ 14.377811] kasan_save_stack+0x45/0x70 [ 14.378031] kasan_save_track+0x18/0x40 [ 14.378197] kasan_save_free_info+0x3f/0x60 [ 14.378396] __kasan_slab_free+0x56/0x70 [ 14.378584] kfree+0x224/0x3f0 [ 14.378749] kasan_strings+0x13c/0xb60 [ 14.378950] kunit_try_run_case+0x1a6/0x480 [ 14.379178] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 14.379447] kthread+0x324/0x6e0 [ 14.379612] ret_from_fork+0x41/0x80 [ 14.379780] ret_from_fork_asm+0x1a/0x30 [ 14.380002] [ 14.380128] The buggy address belongs to the object at ffff888101b3b540 [ 14.380128] which belongs to the cache kmalloc-32 of size 32 [ 14.380615] The buggy address is located 16 bytes inside of [ 14.380615] freed 32-byte region [ffff888101b3b540, ffff888101b3b560) [ 14.381138] [ 14.381249] The buggy address belongs to the physical page: [ 14.381515] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x101b3b [ 14.381897] flags: 0x200000000000000(node=0|zone=2) [ 14.382159] page_type: f5(slab) [ 14.382359] raw: 0200000000000000 ffff888100041780 dead000000000122 0000000000000000 [ 14.382701] raw: 0000000000000000 0000000080400040 00000000f5000000 0000000000000000 [ 14.382940] page dumped because: kasan: bad access detected [ 14.383113] [ 14.383218] Memory state around the buggy address: [ 14.383457] ffff888101b3b400: 00 00 00 04 fc fc fc fc fa fb fb fb fc fc fc fc [ 14.383803] ffff888101b3b480: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 14.384165] >ffff888101b3b500: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 14.384528] ^ [ 14.384785] ffff888101b3b580: fa fb fb fb fc fc fc fc fa fb fb fb fc fc fc fc [ 14.385120] ffff888101b3b600: 00 00 00 fc fc fc fc fc fa fb fb fb fc fc fc fc [ 14.385330] ==================================================================