==================================================================
BUG: KASAN: use-after-free in read_pnet include/net/net_namespace.h:361 [inline]
BUG: KASAN: use-after-free in ib2_net include/net/inet_hashtables.h:116 [inline]
BUG: KASAN: use-after-free in check_bind2_bucket_match net/ipv4/inet_hashtables.c:765 [inline]
BUG: KASAN: use-after-free in inet_bind2_bucket_find+0x562/0x620 net/ipv4/inet_hashtables.c:819
Read of size 8 at addr ffff88807d812100 by task syz-executor.1/26550

CPU: 0 PID: 26550 Comm: syz-executor.1 Not tainted 5.18.0-syzkaller-11972-gd1dc87763f40 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
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+0xeb/0x467 mm/kasan/report.c:313
 print_report mm/kasan/report.c:429 [inline]
 kasan_report.cold+0xf4/0x1c6 mm/kasan/report.c:491
 read_pnet include/net/net_namespace.h:361 [inline]
 ib2_net include/net/inet_hashtables.h:116 [inline]
 check_bind2_bucket_match net/ipv4/inet_hashtables.c:765 [inline]
 inet_bind2_bucket_find+0x562/0x620 net/ipv4/inet_hashtables.c:819
 __inet_hash_connect+0xaaa/0x1450 net/ipv4/inet_hashtables.c:949
 dccp_v4_connect+0xc5c/0x16f0 net/dccp/ipv4.c:108
 __inet_stream_connect+0x8cf/0xed0 net/ipv4/af_inet.c:660
 inet_stream_connect+0x53/0xa0 net/ipv4/af_inet.c:724
 __sys_connect_file+0x14f/0x190 net/socket.c:1979
 io_connect+0x15f/0x690 fs/io_uring.c:6724
 io_issue_sqe+0x40c6/0xa9c0 fs/io_uring.c:8351
 io_queue_sqe fs/io_uring.c:8706 [inline]
 io_submit_sqe fs/io_uring.c:8968 [inline]
 io_submit_sqes+0x16b0/0x8020 fs/io_uring.c:9079
 __do_sys_io_uring_enter+0x117f/0x2360 fs/io_uring.c:12008
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x46/0xb0
RIP: 0033:0x7f7607a89109
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f7608be8168 EFLAGS: 00000246 ORIG_RAX: 00000000000001aa
RAX: ffffffffffffffda RBX: 00007f7607b9bf60 RCX: 00007f7607a89109
RDX: 0000000000000000 RSI: 00000000000074e8 RDI: 0000000000000003
RBP: 00007f7607ae308d R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fff20b3e6ff R14: 00007f7608be8300 R15: 0000000000022000
 </TASK>

Allocated by task 26550:
 kasan_save_stack+0x1e/0x40 mm/kasan/common.c:38
 kasan_set_track mm/kasan/common.c:45 [inline]
 set_alloc_info mm/kasan/common.c:436 [inline]
 __kasan_slab_alloc+0x85/0xb0 mm/kasan/common.c:469
 kasan_slab_alloc include/linux/kasan.h:224 [inline]
 slab_post_alloc_hook mm/slab.h:750 [inline]
 slab_alloc mm/slab.c:3302 [inline]
 __kmem_cache_alloc_lru mm/slab.c:3479 [inline]
 kmem_cache_alloc+0x265/0x560 mm/slab.c:3499
 inet_bind2_bucket_create+0x37/0x360 net/ipv4/inet_hashtables.c:91
 __inet_hash_connect+0xef5/0x1450 net/ipv4/inet_hashtables.c:951
 dccp_v4_connect+0xc5c/0x16f0 net/dccp/ipv4.c:108
 __inet_stream_connect+0x8cf/0xed0 net/ipv4/af_inet.c:660
 inet_stream_connect+0x53/0xa0 net/ipv4/af_inet.c:724
 __sys_connect_file+0x14f/0x190 net/socket.c:1979
 io_connect+0x15f/0x690 fs/io_uring.c:6724
 io_issue_sqe+0x40c6/0xa9c0 fs/io_uring.c:8351
 io_queue_sqe fs/io_uring.c:8706 [inline]
 io_submit_sqe fs/io_uring.c:8968 [inline]
 io_submit_sqes+0x16b0/0x8020 fs/io_uring.c:9079
 __do_sys_io_uring_enter+0x117f/0x2360 fs/io_uring.c:12008
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x46/0xb0

Freed by task 26550:
 kasan_save_stack+0x1e/0x40 mm/kasan/common.c:38
 kasan_set_track+0x21/0x30 mm/kasan/common.c:45
 kasan_set_free_info+0x20/0x30 mm/kasan/generic.c:370
 ____kasan_slab_free mm/kasan/common.c:366 [inline]
 ____kasan_slab_free+0x13d/0x180 mm/kasan/common.c:328
 kasan_slab_free include/linux/kasan.h:200 [inline]
 __cache_free mm/slab.c:3425 [inline]
 kmem_cache_free.part.0+0xa9/0x240 mm/slab.c:3735
 inet_bind2_bucket_destroy net/ipv4/inet_hashtables.c:137 [inline]
 inet_bind2_bucket_destroy net/ipv4/inet_hashtables.c:133 [inline]
 __inet_put_port net/ipv4/inet_hashtables.c:174 [inline]
 inet_put_port+0x4a0/0x6f0 net/ipv4/inet_hashtables.c:182
 dccp_set_state+0x1be/0x3a0 net/dccp/proto.c:103
 dccp_done+0x19/0x100 net/dccp/proto.c:138
 dccp_rcv_state_process+0xc31/0x1820 net/dccp/input.c:662
 dccp_v4_do_rcv+0xf9/0x1a0 net/dccp/ipv4.c:695
 sk_backlog_rcv include/net/sock.h:1061 [inline]
 __release_sock+0x134/0x3b0 net/core/sock.c:2849
 release_sock+0x54/0x1b0 net/core/sock.c:3404
 inet_stream_connect+0x76/0xa0 net/ipv4/af_inet.c:725
 __sys_connect_file+0x14f/0x190 net/socket.c:1979
 io_connect+0x15f/0x690 fs/io_uring.c:6724
 io_issue_sqe+0x40c6/0xa9c0 fs/io_uring.c:8351
 io_queue_sqe fs/io_uring.c:8706 [inline]
 io_submit_sqe fs/io_uring.c:8968 [inline]
 io_submit_sqes+0x16b0/0x8020 fs/io_uring.c:9079
 __do_sys_io_uring_enter+0x117f/0x2360 fs/io_uring.c:12008
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x46/0xb0

The buggy address belongs to the object at ffff88807d812100
 which belongs to the cache dccp_bind2_bucket of size 56
The buggy address is located 0 bytes inside of
 56-byte region [ffff88807d812100, ffff88807d812138)

The buggy address belongs to the physical page:
page:ffffea0001f60480 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x7d812
memcg:ffff888079375401
flags: 0xfff00000000200(slab|node=0|zone=1|lastcpupid=0x7ff)
raw: 00fff00000000200 ffffea000128d488 ffffea0000d01dc8 ffff888025a16300
raw: 0000000000000000 ffff88807d812000 0000000100000020 ffff888079375401
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 0, migratetype Unmovable, gfp_mask 0x342220(__GFP_HIGH|__GFP_ATOMIC|__GFP_NOWARN|__GFP_COMP|__GFP_HARDWALL|__GFP_THISNODE), pid 23724, tgid 23723 (syz-executor.5), ts 806079738512, free_ts 801305078069
 prep_new_page mm/page_alloc.c:2456 [inline]
 get_page_from_freelist+0x1290/0x3b70 mm/page_alloc.c:4198
 __alloc_pages+0x1c7/0x510 mm/page_alloc.c:5426
 __alloc_pages_node include/linux/gfp.h:587 [inline]
 kmem_getpages mm/slab.c:1363 [inline]
 cache_grow_begin+0x75/0x350 mm/slab.c:2569
 cache_alloc_refill+0x27f/0x380 mm/slab.c:2942
 ____cache_alloc mm/slab.c:3024 [inline]
 ____cache_alloc mm/slab.c:3007 [inline]
 __do_cache_alloc mm/slab.c:3253 [inline]
 slab_alloc mm/slab.c:3295 [inline]
 __kmem_cache_alloc_lru mm/slab.c:3479 [inline]
 kmem_cache_alloc+0x450/0x560 mm/slab.c:3499
 inet_bind2_bucket_create+0x37/0x360 net/ipv4/inet_hashtables.c:91
 __inet_hash_connect+0xef5/0x1450 net/ipv4/inet_hashtables.c:951
 dccp_v4_connect+0xc5c/0x16f0 net/dccp/ipv4.c:108
 __inet_stream_connect+0x8cf/0xed0 net/ipv4/af_inet.c:660
 inet_stream_connect+0x53/0xa0 net/ipv4/af_inet.c:724
 __sys_connect_file+0x14f/0x190 net/socket.c:1979
 io_connect+0x15f/0x690 fs/io_uring.c:6724
 io_issue_sqe+0x40c6/0xa9c0 fs/io_uring.c:8351
 io_queue_sqe fs/io_uring.c:8706 [inline]
 io_submit_sqe fs/io_uring.c:8968 [inline]
 io_submit_sqes+0x16b0/0x8020 fs/io_uring.c:9079
 __do_sys_io_uring_enter+0x117f/0x2360 fs/io_uring.c:12008
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
page last free stack trace:
 reset_page_owner include/linux/page_owner.h:24 [inline]
 free_pages_prepare mm/page_alloc.c:1371 [inline]
 free_pcp_prepare+0x549/0xd20 mm/page_alloc.c:1421
 free_unref_page_prepare mm/page_alloc.c:3343 [inline]
 free_unref_page+0x19/0x6a0 mm/page_alloc.c:3438
 slab_destroy mm/slab.c:1615 [inline]
 slabs_destroy+0x89/0xc0 mm/slab.c:1635
 cache_flusharray mm/slab.c:3397 [inline]
 ___cache_free+0x34e/0x670 mm/slab.c:3460
 qlink_free mm/kasan/quarantine.c:168 [inline]
 qlist_free_all+0x4f/0x1b0 mm/kasan/quarantine.c:187
 kasan_quarantine_reduce+0x180/0x200 mm/kasan/quarantine.c:294
 __kasan_slab_alloc+0x97/0xb0 mm/kasan/common.c:446
 kasan_slab_alloc include/linux/kasan.h:224 [inline]
 slab_post_alloc_hook mm/slab.h:750 [inline]
 slab_alloc_node mm/slab.c:3239 [inline]
 kmem_cache_alloc_node+0x2ea/0x590 mm/slab.c:3593
 alloc_vmap_area+0x16f/0x1f00 mm/vmalloc.c:1560
 __get_vm_area_node+0x142/0x3f0 mm/vmalloc.c:2453
 __vmalloc_node_range+0x250/0x13e0 mm/vmalloc.c:3125
 __vmalloc_node mm/vmalloc.c:3230 [inline]
 vzalloc+0x67/0x80 mm/vmalloc.c:3303
 do_ipt_get_ctl+0x60d/0x9d0 net/ipv4/netfilter/ip_tables.c:801
 nf_getsockopt+0x72/0xd0 net/netfilter/nf_sockopt.c:116
 ip_getsockopt net/ipv4/ip_sockglue.c:1786 [inline]
 ip_getsockopt+0x164/0x1c0 net/ipv4/ip_sockglue.c:1765
 tcp_getsockopt+0x86/0xd0 net/ipv4/tcp.c:4273

Memory state around the buggy address:
 ffff88807d812000: fa fb fb fb fb fb fb fc fc fc fc fc fc fc fc fc
 ffff88807d812080: fa fb fb fb fb fb fb fc fc fc fc fc fc fc fc fc
>ffff88807d812100: fa fb fb fb fb fb fb fc fc fc fc fc fc fc fc fc
                   ^
 ffff88807d812180: fa fb fb fb fb fb fb fc fc fc fc fc fc fc fc fc
 ffff88807d812200: fa fb fb fb fb fb fb fc fc fc fc fc fc fc fc fc
==================================================================