================================================================== BUG: KASAN: slab-out-of-bounds in skb_headlen include/linux/skbuff.h:1898 [inline] BUG: KASAN: slab-out-of-bounds in pskb_may_pull include/linux/skbuff.h:2112 [inline] BUG: KASAN: slab-out-of-bounds in skb_ensure_writable+0x290/0x2e0 net/core/skbuff.c:5020 Read of size 4 at addr ffff8801c7809af8 by task syz-executor0/27957 CPU: 1 PID: 27957 Comm: syz-executor0 Not tainted 4.14.80+ #4 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0xb9/0x11b lib/dump_stack.c:53 print_address_description+0x60/0x22b mm/kasan/report.c:252 kasan_report_error mm/kasan/report.c:351 [inline] kasan_report.cold.6+0x11b/0x2dd mm/kasan/report.c:409 skb_headlen include/linux/skbuff.h:1898 [inline] pskb_may_pull include/linux/skbuff.h:2112 [inline] skb_ensure_writable+0x290/0x2e0 net/core/skbuff.c:5020 __bpf_try_make_writable net/core/filter.c:1403 [inline] bpf_try_make_writable net/core/filter.c:1409 [inline] ____bpf_l4_csum_replace net/core/filter.c:1578 [inline] bpf_l4_csum_replace+0x61/0x300 net/core/filter.c:1565 ___bpf_prog_run+0x248e/0x5c70 kernel/bpf/core.c:1012 Allocated by task 26353: save_stack mm/kasan/kasan.c:447 [inline] set_track mm/kasan/kasan.c:459 [inline] kasan_kmalloc.part.1+0x4f/0xd0 mm/kasan/kasan.c:551 slab_post_alloc_hook mm/slab.h:442 [inline] slab_alloc_node mm/slub.c:2723 [inline] slab_alloc mm/slub.c:2731 [inline] kmem_cache_alloc+0xe4/0x2b0 mm/slub.c:2736 skb_clone+0x120/0x300 net/core/skbuff.c:1278 skb_share_check include/linux/skbuff.h:1522 [inline] packet_rcv_spkt+0x3a2/0x4b0 net/packet/af_packet.c:1857 deliver_skb net/core/dev.c:1881 [inline] deliver_ptype_list_skb net/core/dev.c:1896 [inline] __netif_receive_skb_core+0xa28/0x2d10 net/core/dev.c:4460 __netif_receive_skb+0x58/0x1f0 net/core/dev.c:4515 netif_receive_skb_internal+0xfc/0x5e0 net/core/dev.c:4588 napi_skb_finish net/core/dev.c:4949 [inline] napi_gro_receive+0x20e/0x410 net/core/dev.c:4980 receive_buf+0xa55/0x42c0 drivers/net/virtio_net.c:847 virtnet_receive drivers/net/virtio_net.c:1093 [inline] virtnet_poll+0x2af/0x910 drivers/net/virtio_net.c:1174 napi_poll net/core/dev.c:5591 [inline] net_rx_action+0x371/0xce0 net/core/dev.c:5657 __do_softirq+0x20d/0x9bd kernel/softirq.c:288 Freed by task 26353: save_stack mm/kasan/kasan.c:447 [inline] set_track mm/kasan/kasan.c:459 [inline] kasan_slab_free+0xac/0x190 mm/kasan/kasan.c:524 slab_free_hook mm/slub.c:1389 [inline] slab_free_freelist_hook mm/slub.c:1410 [inline] slab_free mm/slub.c:2966 [inline] kmem_cache_free+0x12d/0x350 mm/slub.c:2988 kfree_skbmem+0x9e/0x100 net/core/skbuff.c:582 __kfree_skb net/core/skbuff.c:642 [inline] kfree_skb+0xd0/0x340 net/core/skbuff.c:659 packet_rcv_spkt+0xd5/0x4b0 net/packet/af_packet.c:1888 deliver_skb net/core/dev.c:1881 [inline] deliver_ptype_list_skb net/core/dev.c:1896 [inline] __netif_receive_skb_core+0xa28/0x2d10 net/core/dev.c:4460 __netif_receive_skb+0x58/0x1f0 net/core/dev.c:4515 netif_receive_skb_internal+0xfc/0x5e0 net/core/dev.c:4588 napi_skb_finish net/core/dev.c:4949 [inline] napi_gro_receive+0x20e/0x410 net/core/dev.c:4980 receive_buf+0xa55/0x42c0 drivers/net/virtio_net.c:847 virtnet_receive drivers/net/virtio_net.c:1093 [inline] virtnet_poll+0x2af/0x910 drivers/net/virtio_net.c:1174 napi_poll net/core/dev.c:5591 [inline] net_rx_action+0x371/0xce0 net/core/dev.c:5657 __do_softirq+0x20d/0x9bd kernel/softirq.c:288 The buggy address belongs to the object at ffff8801c7809a00 which belongs to the cache skbuff_head_cache of size 224 The buggy address is located 24 bytes to the right of 224-byte region [ffff8801c7809a00, ffff8801c7809ae0) The buggy address belongs to the page: page:ffffea00071e0240 count:1 mapcount:0 mapping: (null) index:0x0 flags: 0x4000000000000100(slab) raw: 4000000000000100 0000000000000000 0000000000000000 00000001800c000c raw: 0000000000000000 0000000100000001 ffff8801dab70200 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8801c7809980: fb fb fb fb fc fc fc fc fc fc fc fc fc fc fc fc ffff8801c7809a00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff8801c7809a80: fb fb fb fb fb fb fb fb fb fb fb fb fc fc fc fc ^ ffff8801c7809b00: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb ffff8801c7809b80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================