Date
May 13, 2025, 12:07 p.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 21.098347] ================================================================== [ 21.098966] BUG: KASAN: slab-use-after-free in mempool_uaf_helper+0x314/0x340 [ 21.099289] Read of size 1 at addr fff00000c4065f00 by task kunit_try_catch/227 [ 21.099357] [ 21.099566] CPU: 1 UID: 0 PID: 227 Comm: kunit_try_catch Tainted: G B N 6.15.0-rc6-next-20250513 #1 PREEMPT [ 21.099781] Tainted: [B]=BAD_PAGE, [N]=TEST [ 21.099855] Hardware name: linux,dummy-virt (DT) [ 21.099908] Call trace: [ 21.099984] show_stack+0x20/0x38 (C) [ 21.100111] dump_stack_lvl+0x8c/0xd0 [ 21.100191] print_report+0x118/0x608 [ 21.100245] kasan_report+0xdc/0x128 [ 21.100296] __asan_report_load1_noabort+0x20/0x30 [ 21.100354] mempool_uaf_helper+0x314/0x340 [ 21.100561] mempool_kmalloc_uaf+0xc4/0x120 [ 21.100675] kunit_try_run_case+0x170/0x3f0 [ 21.100929] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 21.101001] kthread+0x328/0x630 [ 21.101310] ret_from_fork+0x10/0x20 [ 21.101586] [ 21.101646] Allocated by task 227: [ 21.101691] kasan_save_stack+0x3c/0x68 [ 21.101760] kasan_save_track+0x20/0x40 [ 21.101881] kasan_save_alloc_info+0x40/0x58 [ 21.101936] __kasan_mempool_unpoison_object+0x11c/0x180 [ 21.102003] remove_element+0x130/0x1f8 [ 21.102100] mempool_alloc_preallocated+0x58/0xc0 [ 21.102190] mempool_uaf_helper+0xa4/0x340 [ 21.102264] mempool_kmalloc_uaf+0xc4/0x120 [ 21.102335] kunit_try_run_case+0x170/0x3f0 [ 21.102413] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 21.102500] kthread+0x328/0x630 [ 21.102567] ret_from_fork+0x10/0x20 [ 21.102634] [ 21.102678] Freed by task 227: [ 21.102750] kasan_save_stack+0x3c/0x68 [ 21.102797] kasan_save_track+0x20/0x40 [ 21.102840] kasan_save_free_info+0x4c/0x78 [ 21.102886] __kasan_mempool_poison_object+0xc0/0x150 [ 21.102983] mempool_free+0x28c/0x328 [ 21.103092] mempool_uaf_helper+0x104/0x340 [ 21.103142] mempool_kmalloc_uaf+0xc4/0x120 [ 21.103182] kunit_try_run_case+0x170/0x3f0 [ 21.103235] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 21.103321] kthread+0x328/0x630 [ 21.103371] ret_from_fork+0x10/0x20 [ 21.103419] [ 21.103479] The buggy address belongs to the object at fff00000c4065f00 [ 21.103479] which belongs to the cache kmalloc-128 of size 128 [ 21.103551] The buggy address is located 0 bytes inside of [ 21.103551] freed 128-byte region [fff00000c4065f00, fff00000c4065f80) [ 21.103619] [ 21.103645] The buggy address belongs to the physical page: [ 21.103684] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x104065 [ 21.103760] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 21.103878] page_type: f5(slab) [ 21.103931] raw: 0bfffe0000000000 fff00000c0001a00 dead000000000122 0000000000000000 [ 21.103995] raw: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000 [ 21.104040] page dumped because: kasan: bad access detected [ 21.104073] [ 21.104638] Memory state around the buggy address: [ 21.104809] fff00000c4065e00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 21.104873] fff00000c4065e80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 21.104926] >fff00000c4065f00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 21.105235] ^ [ 21.105327] fff00000c4065f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 21.105388] fff00000c4066000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 21.105455] ================================================================== [ 21.144481] ================================================================== [ 21.144586] BUG: KASAN: slab-use-after-free in mempool_uaf_helper+0x314/0x340 [ 21.144752] Read of size 1 at addr fff00000c661e240 by task kunit_try_catch/231 [ 21.144836] [ 21.144891] CPU: 1 UID: 0 PID: 231 Comm: kunit_try_catch Tainted: G B N 6.15.0-rc6-next-20250513 #1 PREEMPT [ 21.145213] Tainted: [B]=BAD_PAGE, [N]=TEST [ 21.145253] Hardware name: linux,dummy-virt (DT) [ 21.145548] Call trace: [ 21.145594] show_stack+0x20/0x38 (C) [ 21.145664] dump_stack_lvl+0x8c/0xd0 [ 21.145778] print_report+0x118/0x608 [ 21.145866] kasan_report+0xdc/0x128 [ 21.145920] __asan_report_load1_noabort+0x20/0x30 [ 21.145991] mempool_uaf_helper+0x314/0x340 [ 21.146049] mempool_slab_uaf+0xc0/0x118 [ 21.146112] kunit_try_run_case+0x170/0x3f0 [ 21.146176] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 21.146490] kthread+0x328/0x630 [ 21.146573] ret_from_fork+0x10/0x20 [ 21.146634] [ 21.146659] Allocated by task 231: [ 21.146697] kasan_save_stack+0x3c/0x68 [ 21.147292] kasan_save_track+0x20/0x40 [ 21.147718] kasan_save_alloc_info+0x40/0x58 [ 21.147794] __kasan_mempool_unpoison_object+0xbc/0x180 [ 21.147867] remove_element+0x16c/0x1f8 [ 21.147922] mempool_alloc_preallocated+0x58/0xc0 [ 21.147979] mempool_uaf_helper+0xa4/0x340 [ 21.148027] mempool_slab_uaf+0xc0/0x118 [ 21.148070] kunit_try_run_case+0x170/0x3f0 [ 21.148112] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 21.148161] kthread+0x328/0x630 [ 21.148203] ret_from_fork+0x10/0x20 [ 21.148245] [ 21.148270] Freed by task 231: [ 21.148307] kasan_save_stack+0x3c/0x68 [ 21.148352] kasan_save_track+0x20/0x40 [ 21.148392] kasan_save_free_info+0x4c/0x78 [ 21.148436] __kasan_mempool_poison_object+0xc0/0x150 [ 21.148483] mempool_free+0x28c/0x328 [ 21.149034] mempool_uaf_helper+0x104/0x340 [ 21.149189] mempool_slab_uaf+0xc0/0x118 [ 21.149242] kunit_try_run_case+0x170/0x3f0 [ 21.149304] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 21.149674] kthread+0x328/0x630 [ 21.149734] ret_from_fork+0x10/0x20 [ 21.149849] [ 21.149883] The buggy address belongs to the object at fff00000c661e240 [ 21.149883] which belongs to the cache test_cache of size 123 [ 21.150001] The buggy address is located 0 bytes inside of [ 21.150001] freed 123-byte region [fff00000c661e240, fff00000c661e2bb) [ 21.150075] [ 21.150103] The buggy address belongs to the physical page: [ 21.150452] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10661e [ 21.150549] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff) [ 21.150615] page_type: f5(slab) [ 21.150806] raw: 0bfffe0000000000 fff00000c6617640 dead000000000122 0000000000000000 [ 21.151060] raw: 0000000000000000 0000000080150015 00000000f5000000 0000000000000000 [ 21.151107] page dumped because: kasan: bad access detected [ 21.151144] [ 21.151167] Memory state around the buggy address: [ 21.151207] fff00000c661e100: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 21.151747] fff00000c661e180: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 21.151812] >fff00000c661e200: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb [ 21.151857] ^ [ 21.151900] fff00000c661e280: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 21.151955] fff00000c661e300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 21.152073] ==================================================================
[ 12.614902] ================================================================== [ 12.615431] BUG: KASAN: slab-use-after-free in mempool_uaf_helper+0x392/0x400 [ 12.615933] Read of size 1 at addr ffff8881039e2200 by task kunit_try_catch/244 [ 12.616244] [ 12.616355] CPU: 1 UID: 0 PID: 244 Comm: kunit_try_catch Tainted: G B N 6.15.0-rc6-next-20250513 #1 PREEMPT(voluntary) [ 12.616407] Tainted: [B]=BAD_PAGE, [N]=TEST [ 12.616420] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 12.616441] Call Trace: [ 12.616454] <TASK> [ 12.616472] dump_stack_lvl+0x73/0xb0 [ 12.616504] print_report+0xd1/0x650 [ 12.616528] ? __virt_addr_valid+0x1db/0x2d0 [ 12.616554] ? mempool_uaf_helper+0x392/0x400 [ 12.616577] ? kasan_complete_mode_report_info+0x64/0x200 [ 12.616601] ? mempool_uaf_helper+0x392/0x400 [ 12.616640] kasan_report+0x141/0x180 [ 12.616663] ? mempool_uaf_helper+0x392/0x400 [ 12.616691] __asan_report_load1_noabort+0x18/0x20 [ 12.616715] mempool_uaf_helper+0x392/0x400 [ 12.616739] ? __pfx_mempool_uaf_helper+0x10/0x10 [ 12.616764] ? __pfx_sched_clock_cpu+0x10/0x10 [ 12.616786] ? irqentry_exit+0x2a/0x60 [ 12.616808] ? sysvec_apic_timer_interrupt+0x50/0x90 [ 12.616834] mempool_kmalloc_uaf+0xef/0x140 [ 12.616857] ? __pfx_mempool_kmalloc_uaf+0x10/0x10 [ 12.616884] ? __pfx_mempool_kmalloc+0x10/0x10 [ 12.616904] ? __pfx_mempool_kfree+0x10/0x10 [ 12.616925] ? __pfx_mempool_kmalloc_uaf+0x10/0x10 [ 12.616951] ? __pfx_mempool_kmalloc_uaf+0x10/0x10 [ 12.616976] kunit_try_run_case+0x1a5/0x480 [ 12.617001] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.617023] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 12.617046] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 12.617068] ? __kthread_parkme+0x82/0x180 [ 12.617090] ? preempt_count_sub+0x50/0x80 [ 12.617116] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.617140] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.617165] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 12.617198] kthread+0x337/0x6f0 [ 12.617218] ? trace_preempt_on+0x20/0xc0 [ 12.617242] ? __pfx_kthread+0x10/0x10 [ 12.617264] ? _raw_spin_unlock_irq+0x47/0x80 [ 12.617285] ? calculate_sigpending+0x7b/0xa0 [ 12.617310] ? __pfx_kthread+0x10/0x10 [ 12.617333] ret_from_fork+0x116/0x1d0 [ 12.617352] ? __pfx_kthread+0x10/0x10 [ 12.617373] ret_from_fork_asm+0x1a/0x30 [ 12.617406] </TASK> [ 12.617418] [ 12.626702] Allocated by task 244: [ 12.627027] kasan_save_stack+0x45/0x70 [ 12.627347] kasan_save_track+0x18/0x40 [ 12.627660] kasan_save_alloc_info+0x3b/0x50 [ 12.627872] __kasan_mempool_unpoison_object+0x1a9/0x200 [ 12.628113] remove_element+0x11e/0x190 [ 12.628642] mempool_alloc_preallocated+0x4d/0x90 [ 12.628899] mempool_uaf_helper+0x96/0x400 [ 12.629215] mempool_kmalloc_uaf+0xef/0x140 [ 12.629598] kunit_try_run_case+0x1a5/0x480 [ 12.629926] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.630489] kthread+0x337/0x6f0 [ 12.630720] ret_from_fork+0x116/0x1d0 [ 12.630910] ret_from_fork_asm+0x1a/0x30 [ 12.631098] [ 12.631421] Freed by task 244: [ 12.631638] kasan_save_stack+0x45/0x70 [ 12.631959] kasan_save_track+0x18/0x40 [ 12.632154] kasan_save_free_info+0x3f/0x60 [ 12.632495] __kasan_mempool_poison_object+0x131/0x1d0 [ 12.632735] mempool_free+0x2ec/0x380 [ 12.632904] mempool_uaf_helper+0x11a/0x400 [ 12.633097] mempool_kmalloc_uaf+0xef/0x140 [ 12.633729] kunit_try_run_case+0x1a5/0x480 [ 12.634012] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.634440] kthread+0x337/0x6f0 [ 12.634767] ret_from_fork+0x116/0x1d0 [ 12.635074] ret_from_fork_asm+0x1a/0x30 [ 12.635470] [ 12.635742] The buggy address belongs to the object at ffff8881039e2200 [ 12.635742] which belongs to the cache kmalloc-128 of size 128 [ 12.636438] The buggy address is located 0 bytes inside of [ 12.636438] freed 128-byte region [ffff8881039e2200, ffff8881039e2280) [ 12.637122] [ 12.637424] The buggy address belongs to the physical page: [ 12.637770] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1039e2 [ 12.638111] flags: 0x200000000000000(node=0|zone=2) [ 12.638725] page_type: f5(slab) [ 12.638976] raw: 0200000000000000 ffff888100041a00 dead000000000122 0000000000000000 [ 12.639513] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000 [ 12.640027] page dumped because: kasan: bad access detected [ 12.640596] [ 12.640698] Memory state around the buggy address: [ 12.640920] ffff8881039e2100: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.641458] ffff8881039e2180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.641922] >ffff8881039e2200: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.642529] ^ [ 12.642709] ffff8881039e2280: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.643008] ffff8881039e2300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 12.643537] ================================================================== [ 12.670824] ================================================================== [ 12.671315] BUG: KASAN: slab-use-after-free in mempool_uaf_helper+0x392/0x400 [ 12.671552] Read of size 1 at addr ffff8881029e4240 by task kunit_try_catch/248 [ 12.672028] [ 12.672286] CPU: 0 UID: 0 PID: 248 Comm: kunit_try_catch Tainted: G B N 6.15.0-rc6-next-20250513 #1 PREEMPT(voluntary) [ 12.672348] Tainted: [B]=BAD_PAGE, [N]=TEST [ 12.672361] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 12.672383] Call Trace: [ 12.672396] <TASK> [ 12.672424] dump_stack_lvl+0x73/0xb0 [ 12.672476] print_report+0xd1/0x650 [ 12.672499] ? __virt_addr_valid+0x1db/0x2d0 [ 12.672524] ? mempool_uaf_helper+0x392/0x400 [ 12.672546] ? kasan_complete_mode_report_info+0x64/0x200 [ 12.672569] ? mempool_uaf_helper+0x392/0x400 [ 12.672591] kasan_report+0x141/0x180 [ 12.672624] ? mempool_uaf_helper+0x392/0x400 [ 12.672692] __asan_report_load1_noabort+0x18/0x20 [ 12.672714] mempool_uaf_helper+0x392/0x400 [ 12.672764] ? __pfx_mempool_uaf_helper+0x10/0x10 [ 12.672812] ? __pfx_sched_clock_cpu+0x10/0x10 [ 12.672854] ? finish_task_switch.isra.0+0x153/0x700 [ 12.672881] mempool_slab_uaf+0xea/0x140 [ 12.672900] ? __pfx_mempool_slab_uaf+0x10/0x10 [ 12.672933] ? __pfx_mempool_alloc_slab+0x10/0x10 [ 12.672953] ? __pfx_mempool_free_slab+0x10/0x10 [ 12.672975] ? __pfx_read_tsc+0x10/0x10 [ 12.672996] ? ktime_get_ts64+0x86/0x230 [ 12.673022] kunit_try_run_case+0x1a5/0x480 [ 12.673046] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.673068] ? _raw_spin_lock_irqsave+0xa1/0x100 [ 12.673092] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 12.673114] ? __kthread_parkme+0x82/0x180 [ 12.673136] ? preempt_count_sub+0x50/0x80 [ 12.673159] ? __pfx_kunit_try_run_case+0x10/0x10 [ 12.673199] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.673223] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 12.673246] kthread+0x337/0x6f0 [ 12.673266] ? trace_preempt_on+0x20/0xc0 [ 12.673289] ? __pfx_kthread+0x10/0x10 [ 12.673310] ? _raw_spin_unlock_irq+0x47/0x80 [ 12.673330] ? calculate_sigpending+0x7b/0xa0 [ 12.673354] ? __pfx_kthread+0x10/0x10 [ 12.673376] ret_from_fork+0x116/0x1d0 [ 12.673394] ? __pfx_kthread+0x10/0x10 [ 12.673415] ret_from_fork_asm+0x1a/0x30 [ 12.673446] </TASK> [ 12.673457] [ 12.686082] Allocated by task 248: [ 12.686373] kasan_save_stack+0x45/0x70 [ 12.686969] kasan_save_track+0x18/0x40 [ 12.687388] kasan_save_alloc_info+0x3b/0x50 [ 12.687890] __kasan_mempool_unpoison_object+0x1bb/0x200 [ 12.688406] remove_element+0x11e/0x190 [ 12.688817] mempool_alloc_preallocated+0x4d/0x90 [ 12.688978] mempool_uaf_helper+0x96/0x400 [ 12.689116] mempool_slab_uaf+0xea/0x140 [ 12.689377] kunit_try_run_case+0x1a5/0x480 [ 12.689911] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.690427] kthread+0x337/0x6f0 [ 12.690931] ret_from_fork+0x116/0x1d0 [ 12.691334] ret_from_fork_asm+0x1a/0x30 [ 12.691575] [ 12.691659] Freed by task 248: [ 12.691771] kasan_save_stack+0x45/0x70 [ 12.691907] kasan_save_track+0x18/0x40 [ 12.692040] kasan_save_free_info+0x3f/0x60 [ 12.692182] __kasan_mempool_poison_object+0x131/0x1d0 [ 12.692348] mempool_free+0x2ec/0x380 [ 12.692478] mempool_uaf_helper+0x11a/0x400 [ 12.692713] mempool_slab_uaf+0xea/0x140 [ 12.693075] kunit_try_run_case+0x1a5/0x480 [ 12.693473] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 12.694051] kthread+0x337/0x6f0 [ 12.694395] ret_from_fork+0x116/0x1d0 [ 12.694998] ret_from_fork_asm+0x1a/0x30 [ 12.695396] [ 12.695638] The buggy address belongs to the object at ffff8881029e4240 [ 12.695638] which belongs to the cache test_cache of size 123 [ 12.696790] The buggy address is located 0 bytes inside of [ 12.696790] freed 123-byte region [ffff8881029e4240, ffff8881029e42bb) [ 12.697948] [ 12.698121] The buggy address belongs to the physical page: [ 12.698420] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1029e4 [ 12.698678] flags: 0x200000000000000(node=0|zone=2) [ 12.698842] page_type: f5(slab) [ 12.698972] raw: 0200000000000000 ffff888101ce88c0 dead000000000122 0000000000000000 [ 12.699204] raw: 0000000000000000 0000000080150015 00000000f5000000 0000000000000000 [ 12.699427] page dumped because: kasan: bad access detected [ 12.699597] [ 12.699772] Memory state around the buggy address: [ 12.700470] ffff8881029e4100: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 12.701174] ffff8881029e4180: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 12.702135] >ffff8881029e4200: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb [ 12.702876] ^ [ 12.703386] ffff8881029e4280: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc [ 12.704157] ffff8881029e4300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 12.705011] ==================================================================