panic: m_copydata: null mbuf Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND *334925 55546 0 0 0x4000000 0 syz-executor.1 db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic(ffffffff8222435d) at panic+0x15c sys/kern/subr_prf.c:207 m_copydata(fffffd805139ad00,30,8,fffffd8050b6ec20) at m_copydata+0x17e m_getptr sys/kern/uipc_mbuf.c:1031 [inline] m_copydata(fffffd805139ad00,30,8,fffffd8050b6ec20) at m_copydata+0x17e sys/kern/uipc_mbuf.c:722 ip6_pullexthdr(fffffd805139ad00,30,0) at ip6_pullexthdr+0x16f sys/netinet6/ip6_input.c:1175 ip6_savecontrol(fffffd805e4dc9d8,fffffd805139ad00,ffff80001e453a70) at ip6_savecontrol+0x373 sys/netinet6/ip6_input.c:1062 rip6_input(ffff80001e453cc8,ffff80001e453cd4,0,18) at rip6_input+0x4eb sys/netinet6/raw_ip6.c:206 ip_deliver(ffff80001e453cc8,ffff80001e453cd4,0,18) at ip_deliver+0x2e3 sys/netinet/ip_input.c:668 ip6_input_if(ffff80001e453cc8,ffff80001e453cd4,29,0,ffff800000677800) at ip6_input_if+0x1055 ipv6_input(ffff800000677800,fffffd8050b6c400) at ipv6_input+0x48 sys/netinet6/ip6_input.c:171 if_input_local(ffff800000677800,fffffd8050b6c400,18) at if_input_local+0x121 sys/net/if.c:781 ip6_output(fffffd8050b6c200,ffff800000a00300,fffffd805012b3c8,0,0,fffffd805012b358) at ip6_output+0xd02 rip6_output(fffffd8050b6c200,fffffd805012a030,ffff80001e454030,0) at rip6_output+0x4d7 sys/netinet6/raw_ip6.c:481 rip6_usrreq(fffffd805012a030,9,fffffd8050b6c200,0,0,ffff80001d414780) at rip6_usrreq+0x5e1 sys/netinet6/raw_ip6.c:670 sosend(fffffd805012a030,0,ffff80001e454278,0,0,0) at sosend+0x669 sys/kern/uipc_socket.c:524 end trace frame: 0xffff80001e454260, count: 0 https://www.openbsd.org/ddb.html describes the minimum info required in bug reports. Insufficient info makes it difficult to find and fix bugs. ddb> ddb> set $lines = 0 ddb> set $maxwidth = 0 ddb> show panic m_copydata: null mbuf ddb> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic(ffffffff8222435d) at panic+0x15c sys/kern/subr_prf.c:207 m_copydata(fffffd805139ad00,30,8,fffffd8050b6ec20) at m_copydata+0x17e m_getptr sys/kern/uipc_mbuf.c:1031 [inline] m_copydata(fffffd805139ad00,30,8,fffffd8050b6ec20) at m_copydata+0x17e sys/kern/uipc_mbuf.c:722 ip6_pullexthdr(fffffd805139ad00,30,0) at ip6_pullexthdr+0x16f sys/netinet6/ip6_input.c:1175 ip6_savecontrol(fffffd805e4dc9d8,fffffd805139ad00,ffff80001e453a70) at ip6_savecontrol+0x373 sys/netinet6/ip6_input.c:1062 rip6_input(ffff80001e453cc8,ffff80001e453cd4,0,18) at rip6_input+0x4eb sys/netinet6/raw_ip6.c:206 ip_deliver(ffff80001e453cc8,ffff80001e453cd4,0,18) at ip_deliver+0x2e3 sys/netinet/ip_input.c:668 ip6_input_if(ffff80001e453cc8,ffff80001e453cd4,29,0,ffff800000677800) at ip6_input_if+0x1055 ipv6_input(ffff800000677800,fffffd8050b6c400) at ipv6_input+0x48 sys/netinet6/ip6_input.c:171 if_input_local(ffff800000677800,fffffd8050b6c400,18) at if_input_local+0x121 sys/net/if.c:781 ip6_output(fffffd8050b6c200,ffff800000a00300,fffffd805012b3c8,0,0,fffffd805012b358) at ip6_output+0xd02 rip6_output(fffffd8050b6c200,fffffd805012a030,ffff80001e454030,0) at rip6_output+0x4d7 sys/netinet6/raw_ip6.c:481 rip6_usrreq(fffffd805012a030,9,fffffd8050b6c200,0,0,ffff80001d414780) at rip6_usrreq+0x5e1 sys/netinet6/raw_ip6.c:670 sosend(fffffd805012a030,0,ffff80001e454278,0,0,0) at sosend+0x669 sys/kern/uipc_socket.c:524 dofilewritev(ffff80001d414780,3,ffff80001e454278,0,ffff80001e454360) at dofilewritev+0x1ac sys/kern/sys_generic.c:364 sys_write(ffff80001d414780,ffff80001e454318,ffff80001e454360) at sys_write+0x83 sys/kern/sys_generic.c:284 syscall(ffff80001e4543e0) at syscall+0x507 sys/arch/amd64/amd64/trap.c:555 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x7a13d04beb0, count: -18 ddb> show registers rdi 0xffffffff812a12c7 db_enter+0x17 rsi 0x1153 __ALIGN_SIZE+0x153 rbp 0xffff80001e4537e0 rbx 0xffff80001e453890 rdx 0x1154 __ALIGN_SIZE+0x154 rcx 0xffff80001f64d000 rax 0xffff80001f64d000 r8 0xffff80001e4537a0 r9 0x1 r10 0xffff8000009f96c0 r11 0x3340e63be2fe0e6c r12 0x3000000008 r13 0xffff80001e4537f0 r14 0x100 r15 0x1 rip 0xffffffff812a12c8 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff80001e4537d0 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb> show proc PROC (syz-executor.1) pid=334925 stat=onproc flags process=0 proc=4000000 pri=76, usrpri=76, nice=20 forw=0xffffffffffffffff, list=0xffff80001d414c70,0xffffffff82576698 process=0xffff8000ffff6378 user=0xffff80001e44f000, vmspace=0xfffffd806bc0a330 estcpu=36, cpticks=0, pctcpu=0.0 user=0, sys=0, intr=0 ddb> ps PID TID PPID UID S FLAGS WAIT COMMAND 55546 175206 37274 0 2 0 syz-executor.1 *55546 334925 37274 0 7 0x4000000 syz-executor.1 1012 519960 20500 0 3 0x80 nanosleep syz-executor.0 1012 262879 20500 0 3 0x4000080 piperd syz-executor.0 1012 38553 20500 0 3 0x4000080 fsleep syz-executor.0 39403 513480 0 0 3 0x14200 acct acct 73469 10097 0 0 3 0x14200 bored sosplice 37274 510339 49352 0 3 0x82 nanosleep syz-executor.1 20500 127200 49352 0 3 0x82 nanosleep syz-executor.0 49352 163289 39890 0 3 0x82 thrsleep syz-fuzzer 49352 256557 39890 0 3 0x4000082 nanosleep syz-fuzzer 49352 392401 39890 0 3 0x4000082 thrsleep syz-fuzzer 49352 239269 39890 0 3 0x4000082 thrsleep syz-fuzzer 49352 203847 39890 0 3 0x4000082 thrsleep syz-fuzzer 49352 349793 39890 0 3 0x4000082 kqread syz-fuzzer 49352 256039 39890 0 3 0x4000082 thrsleep syz-fuzzer 49352 56617 39890 0 3 0x4000082 thrsleep syz-fuzzer 39890 424295 38298 0 3 0x10008a pause ksh 38298 420880 34864 0 3 0x92 select sshd 15114 178920 1 0 3 0x100083 ttyin getty 34864 174502 1 0 3 0x80 select sshd 44226 370046 78567 73 3 0x100090 kqread syslogd 78567 101830 1 0 3 0x100082 netio syslogd 93771 493448 1 77 3 0x100090 poll dhclient 94083 244620 1 0 3 0x80 poll dhclient 97821 41804 0 0 2 0x14200 zerothread 18568 38139 0 0 3 0x14200 aiodoned aiodoned 24080 130224 0 0 3 0x14200 syncer update 25057 428719 0 0 3 0x14200 cleaner cleaner 98146 110598 0 0 3 0x14200 reaper reaper 27130 238517 0 0 3 0x14200 pgdaemon pagedaemon 45714 6297 0 0 3 0x14200 bored crynlk 56799 212412 0 0 3 0x14200 bored crypto 66011 450489 0 0 3 0x40014200 acpi0 acpi0 86852 102520 0 0 3 0x14200 bored softnet 24043 138550 0 0 3 0x14200 bored systqmp 47700 251681 0 0 3 0x14200 bored systq 38952 112928 0 0 3 0x40014200 bored softclock 79928 381672 0 0 3 0x40014200 idle0 90401 425301 0 0 3 0x14200 bored smr 1 516895 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb> show all locks No such command ddb> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 9510 6669K 7494K 78643K 11741 0 pcb 20 8K 8K 78643K 154 0 rtable 108 3K 4K 78643K 241 0 ifaddr 68 14K 14K 78643K 89 0 counters 19 16K 16K 78643K 19 0 ioctlops 0 0K 2K 78643K 21 0 iov 0 0K 12K 78643K 65 0 mount 1 1K 1K 78643K 1 0 vnodes 1234 78K 78K 78643K 1524 0 UFS quota 1 32K 32K 78643K 1 0 UFS mount 5 36K 36K 78643K 5 0 shm 2 1K 5K 78643K 5 0 VM map 2 0K 0K 78643K 2 0 sem 12 0K 1K 78643K 71 0 dirhash 12 2K 2K 78643K 12 0 ACPI 1794 195K 288K 78643K 12646 0 file desc 6 17K 25K 78643K 201 0 sigio 2 0K 0K 78643K 26 0 proc 48 38K 54K 78643K 380 0 subproc 32 2K 2K 78643K 34 0 NFS srvsock 1 0K 0K 78643K 1 0 NFS daemon 1 16K 16K 78643K 1 0 ip_moptions 2 0K 0K 78643K 27 0 in_multi 55 2K 3K 78643K 78 0 ether_multi 1 0K 0K 78643K 4 0 ISOFS mount 1 32K 32K 78643K 1 0 MSDOSFS mount 1 16K 16K 78643K 1 0 ttys 43 201K 201K 78643K 43 0 exec 0 0K 1K 78643K 205 0 pagedep 1 8K 8K 78643K 1 0 inodedep 1 32K 32K 78643K 1 0 newblk 1 0K 0K 78643K 1 0 VM swap 7 26K 26K 78643K 7 0 UVM amap 116 22K 26K 78643K 1388 0 UVM aobj 23 2K 2K 78643K 24 0 memdesc 1 4K 4K 78643K 1 0 crypto data 1 1K 1K 78643K 1 0 ip6_options 2 0K 0K 78643K 46 0 NDP 10 0K 0K 78643K 18 0 temp 125 3018K 3084K 78643K 16204 0 SYN cache 2 16K 16K 78643K 2 0 ddb> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle arp 64 7 0 0 1 0 1 1 0 8 0 rtpcb 80 32 0 30 1 0 1 1 0 8 0 rtentry 112 52 0 8 2 0 2 2 0 8 0 unpcb 120 149 0 141 1 0 1 1 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpqe 32 313 0 313 1 1 0 1 0 8 0 tcpcb 544 103 0 98 1 0 1 1 0 8 0 ipq 40 4 0 4 2 2 0 1 0 8 0 ipqe 40 180 0 180 2 2 0 1 0 8 0 inpcb 280 378 0 361 3 1 2 2 0 8 0 nd6 48 5 0 2 1 0 1 1 0 8 0 ppxss 1128 3 0 3 2 1 1 1 0 8 1 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 243 0 39 14 0 14 14 0 8 0 art_table 32 244 0 39 2 0 2 2 0 8 0 art_node 16 51 0 11 1 0 1 1 0 8 0 sysvmsgpl 40 11 0 8 1 0 1 1 0 8 0 semapl 112 69 0 59 1 0 1 1 0 8 0 shmpl 112 22 0 1 1 0 1 1 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 1710 0 312 46 0 46 46 0 8 0 ffsino 240 1710 0 312 83 0 83 83 0 8 0 nchpl 144 2199 0 587 61 1 60 61 0 8 0 uvmvnodes 72 2009 0 0 37 0 37 37 0 8 0 vnodes 208 2009 0 0 106 0 106 106 0 8 0 namei 1024 6053 0 6053 1 0 1 1 0 8 1 scxspl 192 7271 0 7271 1 0 1 1 0 8 1 plimitpl 152 45 0 38 1 0 1 1 0 8 0 sigapl 432 372 0 358 2 0 2 2 0 8 0 futexpl 56 6384 0 6383 2 1 1 1 0 8 0 knotepl 112 72 0 53 1 0 1 1 0 8 0 kqueuepl 104 101 0 94 1 0 1 1 0 8 0 pipepl 112 242 0 221 2 1 1 1 0 8 0 fdescpl 424 373 0 358 2 0 2 2 0 8 0 filepl 120 2801 0 2685 6 1 5 5 0 8 1 lockfpl 104 80 0 77 1 0 1 1 0 8 0 lockfspl 48 33 0 30 1 0 1 1 0 8 0 sessionpl 112 17 0 7 1 0 1 1 0 8 0 pgrppl 48 17 0 7 1 0 1 1 0 8 0 ucredpl 96 242 0 235 1 0 1 1 0 8 0 zombiepl 144 358 0 358 2 1 1 1 0 8 1 processpl 872 389 0 358 4 0 4 4 0 8 0 procpl 632 639 0 598 4 0 4 4 0 8 0 sosppl 128 2 0 2 1 1 0 1 0 8 0 sockpl 384 564 0 537 7 2 5 5 0 8 2 mcl64k 65536 20 0 18 2 1 1 1 0 8 0 mcl16k 16384 1 0 1 1 1 0 1 0 8 0 mcl12k 12288 5 0 5 2 1 1 1 0 8 1 mcl9k 9216 5 0 5 2 1 1 1 0 8 1 mcl8k 8192 11 0 11 2 1 1 1 0 8 1 mcl4k 4096 34 0 34 3 2 1 1 0 8 1 mcl2k 2048 69145 0 69093 21 12 9 18 0 8 2 mtagpl 80 22 0 2 2 1 1 1 0 8 0 mbufpl 256 111753 0 111380 38 14 24 24 0 8 0 bufpl 280 6740 0 1333 387 0 387 387 0 8 0 anonpl 16 71387 0 52551 104 11 93 93 0 107 14 amapchunkpl 152 1982 0 1826 9 2 7 8 0 158 0 amappl16 192 2792 0 1767 78 14 64 64 0 8 12 amappl15 184 127 0 121 1 0 1 1 0 8 0 amappl14 176 36 0 30 2 1 1 1 0 8 0 amappl13 168 2 0 0 1 0 1 1 0 8 0 amappl12 160 8 0 7 2 1 1 1 0 8 0 amappl11 152 46 0 35 1 0 1 1 0 8 0 amappl10 144 13 0 9 1 0 1 1 0 8 0 amappl9 136 655 0 650 1 0 1 1 0 8 0 amappl8 128 219 0 186 2 0 2 2 0 8 0 amappl7 120 98 0 87 1 0 1 1 0 8 0 amappl6 112 52 0 49 1 0 1 1 0 8 0 amappl5 104 133 0 123 1 0 1 1 0 8 0 amappl4 96 590 0 556 1 0 1 1 0 8 0 amappl3 88 126 0 119 1 0 1 1 0 8 0 amappl2 80 2275 0 2197 4 2 2 3 0 8 0 amappl1 72 16109 0 15668 27 18 9 20 0 8 0 amappl 80 904 0 858 3 1 2 2 0 84 1 dma4096 4096 1 0 1 1 1 0 1 0 8 0 dma256 256 6 0 6 1 1 0 1 0 8 0 dma128 128 253 0 253 1 1 0 1 0 8 0 dma64 64 6 0 6 1 1 0 1 0 8 0 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 18 0 17 1 0 1 1 0 8 0 aobjpl 64 23 0 1 1 0 1 1 0 8 0 uaddrrnd 24 373 0 358 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 373 0 358 1 0 1 1 0 8 0 vmmpekpl 168 6608 0 6583 2 0 2 2 0 8 0 vmmpepl 168 55343 0 53092 142 32 110 126 0 357 12 vmsppl 272 372 0 358 2 1 1 2 0 8 0 pdppl 4096 752 0 716 6 1 5 6 0 8 0 pvpl 32 203855 0 181935 228 13 215 215 0 265 35 pmappl 200 372 0 358 1 0 1 1 0 8 0 extentpl 40 46 0 29 1 0 1 1 0 8 0 phpool 112 180 0 35 5 0 5 5 0 8 0