syzbot


KASAN: global-out-of-bounds Read in nr_header

Status: closed as invalid on 2025/03/17 11:18
Subsystems: hams
[Documentation on labels]
First crash: 212d, last: 212d

Sample crash report:
==================================================================
BUG: KASAN: global-out-of-bounds in nr_header+0xfa/0x3f0 net/netrom/nr_dev.c:78
Read of size 7 at addr ffffffff8c1c2b60 by task dhcpcd/5655

CPU: 1 UID: 0 PID: 5655 Comm: dhcpcd Not tainted 6.13.0-syzkaller-09585-gb4b0881156fb #0
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:94 [inline]
 dump_stack_lvl+0x116/0x1f0 lib/dump_stack.c:120
 print_address_description mm/kasan/report.c:378 [inline]
 print_report+0xc3/0x620 mm/kasan/report.c:489
 kasan_report+0xd9/0x110 mm/kasan/report.c:602
 check_region_inline mm/kasan/generic.c:183 [inline]
 kasan_check_range+0xef/0x1a0 mm/kasan/generic.c:189
 __asan_memcpy+0x23/0x60 mm/kasan/shadow.c:105
 nr_header+0xfa/0x3f0 net/netrom/nr_dev.c:78
 dev_hard_header include/linux/netdevice.h:3357 [inline]
 vlan_dev_hard_header+0x13f/0x520 net/8021q/vlan_dev.c:83
 dev_hard_header include/linux/netdevice.h:3357 [inline]
 lapbeth_data_transmit+0x2bf/0x370 drivers/net/wan/lapbether.c:257
 lapb_data_transmit+0x93/0xc0 net/lapb/lapb_iface.c:447
 lapb_transmit_buffer+0xce/0x390 net/lapb/lapb_out.c:149
 lapb_send_control+0x1ce/0x320 net/lapb/lapb_subr.c:251
 lapb_establish_data_link+0xeb/0x110 net/lapb/lapb_out.c:163
 lapb_device_event+0x398/0x570 net/lapb/lapb_iface.c:512
 notifier_call_chain+0xb7/0x410 kernel/notifier.c:85
 call_netdevice_notifiers_info+0xbe/0x140 net/core/dev.c:2141
 call_netdevice_notifiers_extack net/core/dev.c:2179 [inline]
 call_netdevice_notifiers net/core/dev.c:2193 [inline]
 __dev_notify_flags+0x12d/0x2e0 net/core/dev.c:9211
 dev_change_flags+0x10c/0x160 net/core/dev.c:9249
 devinet_ioctl+0x11d9/0x1f50 net/ipv4/devinet.c:1208
 inet_ioctl+0x3aa/0x3f0 net/ipv4/af_inet.c:1001
 sock_do_ioctl+0x116/0x280 net/socket.c:1194
 sock_ioctl+0x228/0x6c0 net/socket.c:1313
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:906 [inline]
 __se_sys_ioctl fs/ioctl.c:892 [inline]
 __x64_sys_ioctl+0x190/0x200 fs/ioctl.c:892
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xcd/0x250 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fb23f584d49
Code: 5c c3 48 8d 44 24 08 48 89 54 24 e0 48 89 44 24 c0 48 8d 44 24 d0 48 89 44 24 c8 b8 10 00 00 00 c7 44 24 b8 10 00 00 00 0f 05 <41> 89 c0 3d 00 f0 ff ff 76 10 48 8b 15 ae 60 0d 00 f7 d8 41 83 c8
RSP: 002b:00007ffe5835c438 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007fb23f4b66c0 RCX: 00007fb23f584d49
RDX: 00007ffe5836c628 RSI: 0000000000008914 RDI: 0000000000000011
RBP: 00007ffe5837c7e8 R08: 00007ffe5836c5e8 R09: 00007ffe5836c598
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffe5836c628 R14: 0000000000000028 R15: 0000000000008914
 </TASK>

The buggy address belongs to the variable:
 bcast_addr+0x0/0x14a0

The buggy address belongs to the physical page:
page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0xc1c2
flags: 0xfff00000002000(reserved|node=0|zone=1|lastcpupid=0x7ff)
raw: 00fff00000002000 ffffea0000307088 ffffea0000307088 0000000000000000
raw: 0000000000000000 0000000000000000 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner info is not present (never set?)

Memory state around the buggy address:
 ffffffff8c1c2a00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffffffff8c1c2a80: 00 00 00 00 00 00 00 00 00 00 f9 f9 f9 f9 f9 f9
>ffffffff8c1c2b00: 00 00 00 00 00 00 f9 f9 f9 f9 f9 f9 06 f9 f9 f9
                                                       ^
 ffffffff8c1c2b80: f9 f9 f9 f9 00 00 00 00 00 06 f9 f9 f9 f9 f9 f9
 ffffffff8c1c2c00: 03 f9 f9 f9 f9 f9 f9 f9 00 00 00 00 00 f9 f9 f9
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/01/31 09:18 upstream b4b0881156fb 4c6ac32f .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream KASAN: global-out-of-bounds Read in nr_header
* Struck through repros no longer work on HEAD.