syzbot


KASAN: global-out-of-bounds Read in macvlan_hard_header (3)

Status: upstream: reported on 2022/08/12 09:35
Reported-by: syzbot+f98474db42abaf86c7b5@syzkaller.appspotmail.com
First crash: 56d, last: 56d
similar bugs (2):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KASAN: global-out-of-bounds Read in macvlan_hard_header 1 778d 774d 0/24 auto-closed as invalid on 2020/10/15 18:25
upstream KASAN: global-out-of-bounds Read in macvlan_hard_header (2) 1 330d 330d 0/24 auto-closed as invalid on 2022/02/05 22:58

Sample crash report:
IPv6: ADDRCONF(NETDEV_CHANGE): team1: link becomes ready
==================================================================
BUG: KASAN: global-out-of-bounds in dev_hard_header include/linux/netdevice.h:3043 [inline]
BUG: KASAN: global-out-of-bounds in macvlan_hard_header+0x12b/0x150 drivers/net/macvlan.c:594
Read of size 8 at addr ffffffff8f2bd590 by task kworker/1:1/32

CPU: 1 PID: 32 Comm: kworker/1:1 Not tainted 5.19.0-rc8-syzkaller-00130-g8eaa1d110800 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/22/2022
Workqueue: mld mld_ifc_work
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106
 print_address_description.constprop.0.cold+0xf/0x495 mm/kasan/report.c:313
 print_report mm/kasan/report.c:429 [inline]
 kasan_report.cold+0xf4/0x1c6 mm/kasan/report.c:491
 dev_hard_header include/linux/netdevice.h:3043 [inline]
 macvlan_hard_header+0x12b/0x150 drivers/net/macvlan.c:594
 dev_hard_header include/linux/netdevice.h:3046 [inline]
 neigh_resolve_output net/core/neighbour.c:1523 [inline]
 neigh_resolve_output+0x4b3/0x840 net/core/neighbour.c:1508
 neigh_output include/net/neighbour.h:549 [inline]
 ip6_finish_output2+0x564/0x1520 net/ipv6/ip6_output.c:134
 __ip6_finish_output net/ipv6/ip6_output.c:195 [inline]
 ip6_finish_output+0x844/0x1170 net/ipv6/ip6_output.c:206
 NF_HOOK_COND include/linux/netfilter.h:296 [inline]
 ip6_output+0x1ed/0x540 net/ipv6/ip6_output.c:227
 dst_output include/net/dst.h:451 [inline]
 NF_HOOK include/linux/netfilter.h:307 [inline]
 NF_HOOK include/linux/netfilter.h:301 [inline]
 mld_sendpack+0xa09/0xe70 net/ipv6/mcast.c:1820
 mld_send_cr net/ipv6/mcast.c:2121 [inline]
 mld_ifc_work+0x71c/0xdc0 net/ipv6/mcast.c:2653
 process_one_work+0x996/0x1610 kernel/workqueue.c:2289
 worker_thread+0x665/0x1080 kernel/workqueue.c:2436
 kthread+0x2e9/0x3a0 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:306
 </TASK>

The buggy address belongs to the variable:
 nr_zapped_lock_chains+0x10/0x40

Memory state around the buggy address:
 ffffffff8f2bd480: 00 00 00 00 f9 f9 f9 f9 04 f9 f9 f9 f9 f9 f9 f9
 ffffffff8f2bd500: 04 f9 f9 f9 f9 f9 f9 f9 04 f9 f9 f9 f9 f9 f9 f9
>ffffffff8f2bd580: 00 f9 f9 f9 f9 f9 f9 f9 00 00 00 00 00 00 00 00
                         ^
 ffffffff8f2bd600: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
 ffffffff8f2bd680: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
==================================================================

Crashes (1):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci-upstream-net-this-kasan-gce 2022/08/08 01:41 net 8eaa1d110800 88e3a122 .config log report info KASAN: global-out-of-bounds Read in macvlan_hard_header
* Struck through repros no longer work on HEAD.