================================================================== BUG: KASAN: slab-out-of-bounds in erspan_build_header+0x392/0x3b0 net/ipv4/ip_gre.c:706 Read of size 2 at addr ffff8880a01ddb0b by task syz-executor.5/19169 CPU: 1 PID: 19169 Comm: syz-executor.5 Not tainted 4.14.111 #1 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x138/0x19c lib/dump_stack.c:53 print_address_description.cold+0x7c/0x1dc mm/kasan/report.c:252 kasan_report_error mm/kasan/report.c:351 [inline] kasan_report mm/kasan/report.c:409 [inline] kasan_report.cold+0xaf/0x2b5 mm/kasan/report.c:393 __asan_report_load_n_noabort+0xf/0x20 mm/kasan/report.c:440 erspan_build_header+0x392/0x3b0 net/ipv4/ip_gre.c:706 erspan_xmit net/ipv4/ip_gre.c:748 [inline] erspan_xmit+0x3ec/0x11c0 net/ipv4/ip_gre.c:725 __netdev_start_xmit include/linux/netdevice.h:4033 [inline] netdev_start_xmit include/linux/netdevice.h:4042 [inline] packet_direct_xmit+0x438/0x640 net/packet/af_packet.c:269 packet_snd net/packet/af_packet.c:2969 [inline] packet_sendmsg+0x31e1/0x5990 net/packet/af_packet.c:2994 sock_sendmsg_nosec net/socket.c:646 [inline] sock_sendmsg+0xd0/0x110 net/socket.c:656 SYSC_sendto+0x206/0x310 net/socket.c:1763 SyS_sendto+0x40/0x50 net/socket.c:1731 do_syscall_64+0x1eb/0x630 arch/x86/entry/common.c:289 entry_SYSCALL_64_after_hwframe+0x42/0xb7 RIP: 0033:0x4582f9 RSP: 002b:00007fa1f5464c78 EFLAGS: 00000246 ORIG_RAX: 000000000000002c RAX: ffffffffffffffda RBX: 0000000000000006 RCX: 00000000004582f9 RDX: 000000000000000e RSI: 0000000020000180 RDI: 0000000000000004 RBP: 000000000073bf00 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007fa1f54656d4 R13: 00000000004c59f6 R14: 00000000004d9d50 R15: 00000000ffffffff Allocated by task 1: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:59 save_stack+0x45/0xd0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_kmalloc mm/kasan/kasan.c:551 [inline] kasan_kmalloc+0xce/0xf0 mm/kasan/kasan.c:529 kmem_cache_alloc_trace+0x152/0x790 mm/slab.c:3618 kmalloc include/linux/slab.h:488 [inline] kzalloc include/linux/slab.h:661 [inline] usb_create_ep_devs+0x4e/0x270 drivers/usb/core/endpoint.c:183 usb_new_device+0xc1d/0x1890 drivers/usb/core/hub.c:2504 register_root_hub drivers/usb/core/hcd.c:1114 [inline] usb_add_hcd+0x805/0x19e0 drivers/usb/core/hcd.c:2901 vhci_hcd_probe+0x16a/0x230 drivers/usb/usbip/vhci_hcd.c:1371 platform_drv_probe+0x8c/0x180 drivers/base/platform.c:578 really_probe drivers/base/dd.c:405 [inline] driver_probe_device+0x4c9/0x680 drivers/base/dd.c:549 __device_attach_driver+0x205/0x270 drivers/base/dd.c:645 bus_for_each_drv+0x147/0x1b0 drivers/base/bus.c:466 __device_attach+0x1e6/0x2d0 drivers/base/dd.c:702 device_initial_probe+0x1b/0x20 drivers/base/dd.c:749 bus_probe_device+0x1e7/0x290 drivers/base/bus.c:526 device_add+0xa48/0x1490 drivers/base/core.c:1857 platform_device_add+0x30d/0x660 drivers/base/platform.c:418 vhci_hcd_init+0x2c7/0x3dd drivers/usb/usbip/vhci_hcd.c:1541 do_one_initcall+0xa0/0x220 init/main.c:825 do_initcall_level init/main.c:891 [inline] do_initcalls init/main.c:899 [inline] do_basic_setup init/main.c:917 [inline] kernel_init_freeable+0x474/0x538 init/main.c:1074 kernel_init+0x12/0x162 init/main.c:999 ret_from_fork+0x3a/0x50 arch/x86/entry/entry_64.S:402 Freed by task 0: (stack is not available) The buggy address belongs to the object at ffff8880a01dd4c0 which belongs to the cache kmalloc-2048 of size 2048 The buggy address is located 1611 bytes inside of 2048-byte region [ffff8880a01dd4c0, ffff8880a01ddcc0) The buggy address belongs to the page: page:ffffea0002807700 count:1 mapcount:0 mapping:ffff8880a01dc3c0 index:0x0 compound_mapcount: 0 flags: 0x1fffc0000008100(slab|head) raw: 01fffc0000008100 ffff8880a01dc3c0 0000000000000000 0000000100000003 raw: ffffea000280d820 ffffea000280c1a0 ffff8880aa800c40 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a01dda00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880a01dda80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff8880a01ddb00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff8880a01ddb80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880a01ddc00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================