Date
July 17, 2025, 11:11 p.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 16.539580] ================================================================== [ 16.539903] BUG: KASAN: slab-use-after-free in krealloc_uaf+0x180/0x520 [ 16.540349] Read of size 1 at addr fff00000c0b98200 by task kunit_try_catch/164 [ 16.540962] [ 16.541142] CPU: 1 UID: 0 PID: 164 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT [ 16.541303] Tainted: [B]=BAD_PAGE, [N]=TEST [ 16.541388] Hardware name: linux,dummy-virt (DT) [ 16.541707] Call trace: [ 16.541932] show_stack+0x20/0x38 (C) [ 16.542087] dump_stack_lvl+0x8c/0xd0 [ 16.542186] print_report+0x118/0x5d0 [ 16.542347] kasan_report+0xdc/0x128 [ 16.542757] __kasan_check_byte+0x54/0x70 [ 16.542986] krealloc_noprof+0x44/0x360 [ 16.543127] krealloc_uaf+0x180/0x520 [ 16.543327] kunit_try_run_case+0x170/0x3f0 [ 16.543414] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 16.543491] kthread+0x328/0x630 [ 16.543781] ret_from_fork+0x10/0x20 [ 16.544060] [ 16.544199] Allocated by task 164: [ 16.544340] kasan_save_stack+0x3c/0x68 [ 16.544386] kasan_save_track+0x20/0x40 [ 16.544948] kasan_save_alloc_info+0x40/0x58 [ 16.545047] __kasan_kmalloc+0xd4/0xd8 [ 16.545218] __kmalloc_cache_noprof+0x16c/0x3c0 [ 16.545608] krealloc_uaf+0xc8/0x520 [ 16.546015] kunit_try_run_case+0x170/0x3f0 [ 16.546167] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 16.546291] kthread+0x328/0x630 [ 16.546393] ret_from_fork+0x10/0x20 [ 16.546559] [ 16.546952] Freed by task 164: [ 16.547018] kasan_save_stack+0x3c/0x68 [ 16.547149] kasan_save_track+0x20/0x40 [ 16.547328] kasan_save_free_info+0x4c/0x78 [ 16.547406] __kasan_slab_free+0x6c/0x98 [ 16.547839] kfree+0x214/0x3c8 [ 16.548010] krealloc_uaf+0x12c/0x520 [ 16.548062] kunit_try_run_case+0x170/0x3f0 [ 16.548472] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 16.548755] kthread+0x328/0x630 [ 16.548928] ret_from_fork+0x10/0x20 [ 16.548981] [ 16.549002] The buggy address belongs to the object at fff00000c0b98200 [ 16.549002] which belongs to the cache kmalloc-256 of size 256 [ 16.549165] The buggy address is located 0 bytes inside of [ 16.549165] freed 256-byte region [fff00000c0b98200, fff00000c0b98300) [ 16.549631] [ 16.549825] The buggy address belongs to the physical page: [ 16.549916] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x100b98 [ 16.550368] head: order:1 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 [ 16.550531] flags: 0xbfffe0000000040(head|node=0|zone=2|lastcpupid=0x1ffff) [ 16.550647] page_type: f5(slab) [ 16.550781] raw: 0bfffe0000000040 fff00000c0001b40 dead000000000122 0000000000000000 [ 16.550838] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 16.551050] head: 0bfffe0000000040 fff00000c0001b40 dead000000000122 0000000000000000 [ 16.551155] head: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 16.551315] head: 0bfffe0000000001 ffffc1ffc302e601 00000000ffffffff 00000000ffffffff [ 16.551367] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000002 [ 16.551406] page dumped because: kasan: bad access detected [ 16.551461] [ 16.551493] Memory state around the buggy address: [ 16.551524] fff00000c0b98100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 16.551585] fff00000c0b98180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 16.551639] >fff00000c0b98200: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 16.551689] ^ [ 16.551716] fff00000c0b98280: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 16.552307] fff00000c0b98300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 16.552571] ================================================================== [ 16.557892] ================================================================== [ 16.557969] BUG: KASAN: slab-use-after-free in krealloc_uaf+0x4c8/0x520 [ 16.558395] Read of size 1 at addr fff00000c0b98200 by task kunit_try_catch/164 [ 16.558479] [ 16.558516] CPU: 1 UID: 0 PID: 164 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT [ 16.558600] Tainted: [B]=BAD_PAGE, [N]=TEST [ 16.558927] Hardware name: linux,dummy-virt (DT) [ 16.559010] Call trace: [ 16.559264] show_stack+0x20/0x38 (C) [ 16.559429] dump_stack_lvl+0x8c/0xd0 [ 16.559668] print_report+0x118/0x5d0 [ 16.560060] kasan_report+0xdc/0x128 [ 16.560199] __asan_report_load1_noabort+0x20/0x30 [ 16.560483] krealloc_uaf+0x4c8/0x520 [ 16.560589] kunit_try_run_case+0x170/0x3f0 [ 16.560638] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 16.560689] kthread+0x328/0x630 [ 16.560731] ret_from_fork+0x10/0x20 [ 16.560778] [ 16.560796] Allocated by task 164: [ 16.560823] kasan_save_stack+0x3c/0x68 [ 16.560876] kasan_save_track+0x20/0x40 [ 16.560912] kasan_save_alloc_info+0x40/0x58 [ 16.560950] __kasan_kmalloc+0xd4/0xd8 [ 16.561303] __kmalloc_cache_noprof+0x16c/0x3c0 [ 16.561372] krealloc_uaf+0xc8/0x520 [ 16.561407] kunit_try_run_case+0x170/0x3f0 [ 16.561443] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 16.561486] kthread+0x328/0x630 [ 16.561520] ret_from_fork+0x10/0x20 [ 16.561563] [ 16.561582] Freed by task 164: [ 16.561617] kasan_save_stack+0x3c/0x68 [ 16.561653] kasan_save_track+0x20/0x40 [ 16.561688] kasan_save_free_info+0x4c/0x78 [ 16.561726] __kasan_slab_free+0x6c/0x98 [ 16.561773] kfree+0x214/0x3c8 [ 16.561804] krealloc_uaf+0x12c/0x520 [ 16.561848] kunit_try_run_case+0x170/0x3f0 [ 16.562589] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 16.562715] kthread+0x328/0x630 [ 16.562750] ret_from_fork+0x10/0x20 [ 16.562784] [ 16.562826] The buggy address belongs to the object at fff00000c0b98200 [ 16.562826] which belongs to the cache kmalloc-256 of size 256 [ 16.563104] The buggy address is located 0 bytes inside of [ 16.563104] freed 256-byte region [fff00000c0b98200, fff00000c0b98300) [ 16.563467] [ 16.563669] The buggy address belongs to the physical page: [ 16.563942] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x100b98 [ 16.564229] head: order:1 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 [ 16.564403] flags: 0xbfffe0000000040(head|node=0|zone=2|lastcpupid=0x1ffff) [ 16.564513] page_type: f5(slab) [ 16.564633] raw: 0bfffe0000000040 fff00000c0001b40 dead000000000122 0000000000000000 [ 16.564701] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 16.565107] head: 0bfffe0000000040 fff00000c0001b40 dead000000000122 0000000000000000 [ 16.565207] head: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 16.565341] head: 0bfffe0000000001 ffffc1ffc302e601 00000000ffffffff 00000000ffffffff [ 16.565511] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000002 [ 16.565591] page dumped because: kasan: bad access detected [ 16.565665] [ 16.565683] Memory state around the buggy address: [ 16.565734] fff00000c0b98100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 16.566033] fff00000c0b98180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 16.566116] >fff00000c0b98200: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 16.566282] ^ [ 16.566448] fff00000c0b98280: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 16.566609] fff00000c0b98300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 16.566650] ==================================================================
[ 12.180589] ================================================================== [ 12.181156] BUG: KASAN: slab-use-after-free in krealloc_uaf+0x1b8/0x5e0 [ 12.181475] Read of size 1 at addr ffff888100a22600 by task kunit_try_catch/181 [ 12.181852] [ 12.181951] CPU: 1 UID: 0 PID: 181 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT(voluntary) [ 12.181998] Tainted: [B]=BAD_PAGE, [N]=TEST [ 12.182009] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 12.182031] Call Trace: [ 12.182061] <TASK> [ 12.182079] dump_stack_lvl+0x73/0xb0 [ 12.182107] print_report+0xd1/0x610 [ 12.182142] ? __virt_addr_valid+0x1db/0x2d0 [ 12.182165] ? krealloc_uaf+0x1b8/0x5e0 [ 12.182185] ? kasan_complete_mode_report_info+0x64/0x200 [ 12.182207] ? krealloc_uaf+0x1b8/0x5e0 [ 12.182232] kasan_report+0x141/0x180 [ 12.182254] ? krealloc_uaf+0x1b8/0x5e0 [ 12.182277] ? krealloc_uaf+0x1b8/0x5e0 [ 12.182298] __kasan_check_byte+0x3d/0x50 [ 12.182319] krealloc_noprof+0x3f/0x340 [ 12.182342] krealloc_uaf+0x1b8/0x5e0 [ 12.182363] ? __pfx_krealloc_uaf+0x10/0x10 [ 12.182383] ? finish_task_switch.isra.0+0x153/0x700 [ 12.182405] ? __switch_to+0x47/0xf50 [ 12.182441] ? __schedule+0x10cc/0x2b60 [ 12.182464] ? __pfx_read_tsc+0x10/0x10 [ 12.182484] ? ktime_get_ts64+0x86/0x230 [ 12.182527] kunit_try_run_case+0x1a5/0x480 [ 12.182552] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.182573] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 12.182619] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 12.182641] ? __kthread_parkme+0x82/0x180 [ 12.182661] ? preempt_count_sub+0x50/0x80 [ 12.182684] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.182707] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.182730] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 12.182753] kthread+0x337/0x6f0 [ 12.182771] ? trace_preempt_on+0x20/0xc0 [ 12.182794] ? __pfx_kthread+0x10/0x10 [ 12.182813] ? _raw_spin_unlock_irq+0x47/0x80 [ 12.182834] ? calculate_sigpending+0x7b/0xa0 [ 12.182858] ? __pfx_kthread+0x10/0x10 [ 12.182878] ret_from_fork+0x116/0x1d0 [ 12.182896] ? __pfx_kthread+0x10/0x10 [ 12.182915] ret_from_fork_asm+0x1a/0x30 [ 12.182948] </TASK> [ 12.182958] [ 12.190680] Allocated by task 181: [ 12.190881] kasan_save_stack+0x45/0x70 [ 12.191069] kasan_save_track+0x18/0x40 [ 12.191263] kasan_save_alloc_info+0x3b/0x50 [ 12.191473] __kasan_kmalloc+0xb7/0xc0 [ 12.191672] __kmalloc_cache_noprof+0x189/0x420 [ 12.191885] krealloc_uaf+0xbb/0x5e0 [ 12.192069] kunit_try_run_case+0x1a5/0x480 [ 12.192273] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.192502] kthread+0x337/0x6f0 [ 12.192714] ret_from_fork+0x116/0x1d0 [ 12.192890] ret_from_fork_asm+0x1a/0x30 [ 12.193089] [ 12.193183] Freed by task 181: [ 12.193358] kasan_save_stack+0x45/0x70 [ 12.193530] kasan_save_track+0x18/0x40 [ 12.193873] kasan_save_free_info+0x3f/0x60 [ 12.194075] __kasan_slab_free+0x56/0x70 [ 12.194276] kfree+0x222/0x3f0 [ 12.194453] krealloc_uaf+0x13d/0x5e0 [ 12.194659] kunit_try_run_case+0x1a5/0x480 [ 12.194844] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.195088] kthread+0x337/0x6f0 [ 12.195209] ret_from_fork+0x116/0x1d0 [ 12.195342] ret_from_fork_asm+0x1a/0x30 [ 12.195495] [ 12.195570] The buggy address belongs to the object at ffff888100a22600 [ 12.195570] which belongs to the cache kmalloc-256 of size 256 [ 12.196083] The buggy address is located 0 bytes inside of [ 12.196083] freed 256-byte region [ffff888100a22600, ffff888100a22700) [ 12.196616] [ 12.196712] The buggy address belongs to the physical page: [ 12.196919] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x100a22 [ 12.197434] head: order:1 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 [ 12.197755] flags: 0x200000000000040(head|node=0|zone=2) [ 12.197936] page_type: f5(slab) [ 12.198067] raw: 0200000000000040 ffff888100041b40 dead000000000122 0000000000000000 [ 12.198397] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 12.198989] head: 0200000000000040 ffff888100041b40 dead000000000122 0000000000000000 [ 12.199382] head: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 12.199795] head: 0200000000000001 ffffea0004028881 00000000ffffffff 00000000ffffffff [ 12.200032] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000002 [ 12.200407] page dumped because: kasan: bad access detected [ 12.200669] [ 12.200812] Memory state around the buggy address: [ 12.200969] ffff888100a22500: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.201193] ffff888100a22580: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.201511] >ffff888100a22600: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.202123] ^ [ 12.202289] ffff888100a22680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.202599] ffff888100a22700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.202881] ================================================================== [ 12.204128] ================================================================== [ 12.204699] BUG: KASAN: slab-use-after-free in krealloc_uaf+0x53c/0x5e0 [ 12.205006] Read of size 1 at addr ffff888100a22600 by task kunit_try_catch/181 [ 12.205306] [ 12.205393] CPU: 1 UID: 0 PID: 181 Comm: kunit_try_catch Tainted: G B N 6.16.0-rc6 #1 PREEMPT(voluntary) [ 12.205435] Tainted: [B]=BAD_PAGE, [N]=TEST [ 12.205445] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 12.205466] Call Trace: [ 12.205482] <TASK> [ 12.205498] dump_stack_lvl+0x73/0xb0 [ 12.205525] print_report+0xd1/0x610 [ 12.205546] ? __virt_addr_valid+0x1db/0x2d0 [ 12.205568] ? krealloc_uaf+0x53c/0x5e0 [ 12.205588] ? kasan_complete_mode_report_info+0x64/0x200 [ 12.205609] ? krealloc_uaf+0x53c/0x5e0 [ 12.205642] kasan_report+0x141/0x180 [ 12.205675] ? krealloc_uaf+0x53c/0x5e0 [ 12.205702] __asan_report_load1_noabort+0x18/0x20 [ 12.205738] krealloc_uaf+0x53c/0x5e0 [ 12.205759] ? __pfx_krealloc_uaf+0x10/0x10 [ 12.205779] ? finish_task_switch.isra.0+0x153/0x700 [ 12.205802] ? __switch_to+0x47/0xf50 [ 12.205828] ? __schedule+0x10cc/0x2b60 [ 12.205851] ? __pfx_read_tsc+0x10/0x10 [ 12.205870] ? ktime_get_ts64+0x86/0x230 [ 12.205894] kunit_try_run_case+0x1a5/0x480 [ 12.205917] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.205939] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 12.205962] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 12.205985] ? __kthread_parkme+0x82/0x180 [ 12.206005] ? preempt_count_sub+0x50/0x80 [ 12.206027] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.206060] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.206084] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 12.206107] kthread+0x337/0x6f0 [ 12.206125] ? trace_preempt_on+0x20/0xc0 [ 12.206149] ? __pfx_kthread+0x10/0x10 [ 12.206168] ? _raw_spin_unlock_irq+0x47/0x80 [ 12.206198] ? calculate_sigpending+0x7b/0xa0 [ 12.206227] ? __pfx_kthread+0x10/0x10 [ 12.206247] ret_from_fork+0x116/0x1d0 [ 12.206284] ? __pfx_kthread+0x10/0x10 [ 12.206303] ret_from_fork_asm+0x1a/0x30 [ 12.206336] </TASK> [ 12.206356] [ 12.217997] Allocated by task 181: [ 12.218293] kasan_save_stack+0x45/0x70 [ 12.218500] kasan_save_track+0x18/0x40 [ 12.219002] kasan_save_alloc_info+0x3b/0x50 [ 12.219284] __kasan_kmalloc+0xb7/0xc0 [ 12.219664] __kmalloc_cache_noprof+0x189/0x420 [ 12.220011] krealloc_uaf+0xbb/0x5e0 [ 12.220356] kunit_try_run_case+0x1a5/0x480 [ 12.220549] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.221006] kthread+0x337/0x6f0 [ 12.221410] ret_from_fork+0x116/0x1d0 [ 12.221888] ret_from_fork_asm+0x1a/0x30 [ 12.222165] [ 12.222392] Freed by task 181: [ 12.222569] kasan_save_stack+0x45/0x70 [ 12.222910] kasan_save_track+0x18/0x40 [ 12.223102] kasan_save_free_info+0x3f/0x60 [ 12.223296] __kasan_slab_free+0x56/0x70 [ 12.223476] kfree+0x222/0x3f0 [ 12.223927] krealloc_uaf+0x13d/0x5e0 [ 12.224206] kunit_try_run_case+0x1a5/0x480 [ 12.224543] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.224930] kthread+0x337/0x6f0 [ 12.225098] ret_from_fork+0x116/0x1d0 [ 12.225270] ret_from_fork_asm+0x1a/0x30 [ 12.225451] [ 12.225538] The buggy address belongs to the object at ffff888100a22600 [ 12.225538] which belongs to the cache kmalloc-256 of size 256 [ 12.226797] The buggy address is located 0 bytes inside of [ 12.226797] freed 256-byte region [ffff888100a22600, ffff888100a22700) [ 12.227563] [ 12.227814] The buggy address belongs to the physical page: [ 12.228261] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x100a22 [ 12.228934] head: order:1 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 [ 12.229348] flags: 0x200000000000040(head|node=0|zone=2) [ 12.229777] page_type: f5(slab) [ 12.230021] raw: 0200000000000040 ffff888100041b40 dead000000000122 0000000000000000 [ 12.230505] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 12.231287] head: 0200000000000040 ffff888100041b40 dead000000000122 0000000000000000 [ 12.232003] head: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 12.232662] head: 0200000000000001 ffffea0004028881 00000000ffffffff 00000000ffffffff [ 12.233018] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000002 [ 12.233337] page dumped because: kasan: bad access detected [ 12.233567] [ 12.233880] Memory state around the buggy address: [ 12.234311] ffff888100a22500: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.235211] ffff888100a22580: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.235754] >ffff888100a22600: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.236080] ^ [ 12.236233] ffff888100a22680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.236518] ffff888100a22700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.237302] ==================================================================