================================================================== BUG: KASAN: slab-use-after-free in ax25cmp+0x2bc/0x410 net/ax25/ax25_addr.c:119 Read of size 1 at addr ffff888056463808 by task kworker/u8:11/7511 CPU: 0 UID: 0 PID: 7511 Comm: kworker/u8:11 Not tainted syzkaller #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/02/2025 Workqueue: events_unbound nsim_dev_trap_report_work Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0xca/0x240 mm/kasan/report.c:482 kasan_report+0x118/0x150 mm/kasan/report.c:595 ax25cmp+0x2bc/0x410 net/ax25/ax25_addr.c:119 ax25_find_cb+0x130/0x3a0 net/ax25/af_ax25.c:236 ax25_send_frame+0x2f6/0x9f0 net/ax25/ax25_out.c:55 rose_send_frame+0x111/0x220 net/rose/rose_link.c:106 rose_transmit_restart_request net/rose/rose_link.c:198 [inline] rose_t0timer_expiry+0x143/0x350 net/rose/rose_link.c:83 call_timer_fn+0x17e/0x5f0 kernel/time/timer.c:1747 expire_timers kernel/time/timer.c:1798 [inline] __run_timers kernel/time/timer.c:2372 [inline] __run_timer_base+0x61a/0x860 kernel/time/timer.c:2384 run_timer_base kernel/time/timer.c:2393 [inline] run_timer_softirq+0xb7/0x180 kernel/time/timer.c:2403 handle_softirqs+0x286/0x870 kernel/softirq.c:622 __do_softirq kernel/softirq.c:656 [inline] invoke_softirq kernel/softirq.c:496 [inline] __irq_exit_rcu+0xca/0x1f0 kernel/softirq.c:723 irq_exit_rcu+0x9/0x30 kernel/softirq.c:739 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1052 [inline] sysvec_apic_timer_interrupt+0xa6/0xc0 arch/x86/kernel/apic/apic.c:1052 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:697 RIP: 0010:crng_make_state+0x406/0x700 drivers/char/random.c:394 Code: 77 8e e8 ed e5 30 06 e9 56 fe ff ff e8 73 f3 a7 fc e8 ae 51 2e 06 4d 85 f6 74 8c e8 64 f3 a7 fc fb 48 c7 44 24 40 0e 36 e0 45 <48> 8b 44 24 38 4a c7 04 20 00 00 00 00 66 42 c7 44 20 09 00 00 42 RSP: 0018:ffffc9001fedf720 EFLAGS: 00000293 RAX: ffffffff8518106c RBX: 0000000000000000 RCX: ffff888024c48000 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 RBP: ffffc9001fedf810 R08: ffffffff8f7ce777 R09: 1ffffffff1ef9cee R10: dffffc0000000000 R11: fffffbfff1ef9cef R12: dffffc0000000000 R13: ffff8880b8836390 R14: 0000000000000200 R15: ffff8880b88363e0 _get_random_bytes+0xd5/0x210 drivers/char/random.c:406 nsim_dev_trap_skb_build drivers/net/netdevsim/dev.c:790 [inline] nsim_dev_trap_report drivers/net/netdevsim/dev.c:820 [inline] nsim_dev_trap_report_work+0x69e/0xb80 drivers/net/netdevsim/dev.c:866 process_one_work kernel/workqueue.c:3263 [inline] process_scheduled_works+0xae1/0x17b0 kernel/workqueue.c:3346 worker_thread+0x8a0/0xda0 kernel/workqueue.c:3427 kthread+0x711/0x8a0 kernel/kthread.c:463 ret_from_fork+0x4bc/0x870 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Allocated by task 762: kasan_save_stack mm/kasan/common.c:56 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:77 poison_kmalloc_redzone mm/kasan/common.c:400 [inline] __kasan_kmalloc+0x93/0xb0 mm/kasan/common.c:417 kasan_kmalloc include/linux/kasan.h:262 [inline] __kmalloc_cache_noprof+0x3d5/0x6f0 mm/slub.c:5771 kmalloc_noprof include/linux/slab.h:957 [inline] rose_add_node+0x23a/0xeb0 net/rose/rose_route.c:85 rose_rt_ioctl+0xce2/0x1240 net/rose/rose_route.c:748 rose_ioctl+0x3ce/0x8b0 net/rose/af_rose.c:1381 sock_do_ioctl+0xdc/0x300 net/socket.c:1254 sock_ioctl+0x576/0x790 net/socket.c:1375 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:597 [inline] __se_sys_ioctl+0xfc/0x170 fs/ioctl.c:583 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0xfa0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f Freed by task 15676: kasan_save_stack mm/kasan/common.c:56 [inline] kasan_save_track+0x3e/0x80 mm/kasan/common.c:77 __kasan_save_free_info+0x46/0x50 mm/kasan/generic.c:587 kasan_save_free_info mm/kasan/kasan.h:406 [inline] poison_slab_object mm/kasan/common.c:252 [inline] __kasan_slab_free+0x5c/0x80 mm/kasan/common.c:284 kasan_slab_free include/linux/kasan.h:234 [inline] slab_free_hook mm/slub.c:2543 [inline] slab_free mm/slub.c:6638 [inline] kfree+0x19a/0x6d0 mm/slub.c:6845 rose_neigh_put include/net/rose.h:166 [inline] rose_timer_expiry+0x4cb/0x600 net/rose/rose_timer.c:183 call_timer_fn+0x17e/0x5f0 kernel/time/timer.c:1747 expire_timers kernel/time/timer.c:1798 [inline] __run_timers kernel/time/timer.c:2372 [inline] __run_timer_base+0x61a/0x860 kernel/time/timer.c:2384 run_timer_base kernel/time/timer.c:2393 [inline] run_timer_softirq+0xb7/0x180 kernel/time/timer.c:2403 handle_softirqs+0x286/0x870 kernel/softirq.c:622 __do_softirq kernel/softirq.c:656 [inline] invoke_softirq kernel/softirq.c:496 [inline] __irq_exit_rcu+0xca/0x1f0 kernel/softirq.c:723 irq_exit_rcu+0x9/0x30 kernel/softirq.c:739 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1052 [inline] sysvec_apic_timer_interrupt+0xa6/0xc0 arch/x86/kernel/apic/apic.c:1052 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:697 The buggy address belongs to the object at ffff888056463800 which belongs to the cache kmalloc-512 of size 512 The buggy address is located 8 bytes inside of freed 512-byte region [ffff888056463800, ffff888056463a00) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x56460 head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 anon flags: 0xfff00000000040(head|node=0|zone=1|lastcpupid=0x7ff) page_type: f5(slab) raw: 00fff00000000040 ffff88801a026c80 0000000000000000 dead000000000001 raw: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000 head: 00fff00000000040 ffff88801a026c80 0000000000000000 dead000000000001 head: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000 head: 00fff00000000002 ffffea0001591801 00000000ffffffff 00000000ffffffff head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000004 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 2, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 5831, tgid 5831 (syz-executor), ts 97858047187, free_ts 27088315827 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x240/0x2a0 mm/page_alloc.c:1850 prep_new_page mm/page_alloc.c:1858 [inline] get_page_from_freelist+0x2365/0x2440 mm/page_alloc.c:3884 __alloc_frozen_pages_noprof+0x181/0x370 mm/page_alloc.c:5183 alloc_pages_mpol+0x232/0x4a0 mm/mempolicy.c:2416 alloc_slab_page mm/slub.c:3059 [inline] allocate_slab+0x96/0x350 mm/slub.c:3232 new_slab mm/slub.c:3286 [inline] ___slab_alloc+0xf56/0x1990 mm/slub.c:4655 __slab_alloc+0x65/0x100 mm/slub.c:4778 __slab_alloc_node mm/slub.c:4854 [inline] slab_alloc_node mm/slub.c:5276 [inline] __do_kmalloc_node mm/slub.c:5649 [inline] __kmalloc_noprof+0x471/0x7f0 mm/slub.c:5662 kmalloc_noprof include/linux/slab.h:961 [inline] kzalloc_noprof include/linux/slab.h:1094 [inline] fib6_info_alloc+0x30/0xf0 net/ipv6/ip6_fib.c:155 ip6_route_info_create+0x142/0x860 net/ipv6/route.c:3809 ip6_route_add+0x49/0x1b0 net/ipv6/route.c:3938 addrconf_add_mroute net/ipv6/addrconf.c:2552 [inline] addrconf_add_dev+0x24f/0x340 net/ipv6/addrconf.c:2570 inet6_addr_add+0x1a1/0xc00 net/ipv6/addrconf.c:3032 inet6_rtm_newaddr+0x93d/0xd20 net/ipv6/addrconf.c:5059 rtnetlink_rcv_msg+0x7cf/0xb70 net/core/rtnetlink.c:6951 netlink_rcv_skb+0x208/0x470 net/netlink/af_netlink.c:2552 page last free pid 1 tgid 1 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1394 [inline] __free_frozen_pages+0xbc4/0xd30 mm/page_alloc.c:2906 __free_pages mm/page_alloc.c:5302 [inline] free_contig_range+0x1bd/0x4a0 mm/page_alloc.c:7146 destroy_args+0x69/0x660 mm/debug_vm_pgtable.c:958 debug_vm_pgtable+0x39f/0x3b0 mm/debug_vm_pgtable.c:1345 do_one_initcall+0x236/0x820 init/main.c:1283 do_initcall_level+0x104/0x190 init/main.c:1345 do_initcalls+0x59/0xa0 init/main.c:1361 kernel_init_freeable+0x334/0x4b0 init/main.c:1593 kernel_init+0x1d/0x1d0 init/main.c:1483 ret_from_fork+0x4bc/0x870 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 Memory state around the buggy address: ffff888056463700: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888056463780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff888056463800: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff888056463880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff888056463900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ================================================================== ---------------- Code disassembly (best guess): 0: 77 8e ja 0xffffff90 2: e8 ed e5 30 06 call 0x630e5f4 7: e9 56 fe ff ff jmp 0xfffffe62 c: e8 73 f3 a7 fc call 0xfca7f384 11: e8 ae 51 2e 06 call 0x62e51c4 16: 4d 85 f6 test %r14,%r14 19: 74 8c je 0xffffffa7 1b: e8 64 f3 a7 fc call 0xfca7f384 20: fb sti 21: 48 c7 44 24 40 0e 36 movq $0x45e0360e,0x40(%rsp) 28: e0 45 * 2a: 48 8b 44 24 38 mov 0x38(%rsp),%rax <-- trapping instruction 2f: 4a c7 04 20 00 00 00 movq $0x0,(%rax,%r12,1) 36: 00 37: 66 42 c7 44 20 09 00 movw $0x0,0x9(%rax,%r12,1) 3e: 00 3f: 42 rex.X