panic: Data modified on freelist: word 4 of object 0xffff800000a52000 size 0x78c previous type free (0x0 != 0xdead4110) Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 71225 72877 0 0 0x4000080 1 syz-executor.1 *426194 58819 0 0x12 0x1 0 sshd db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic(ffffffff821e5be6) at panic+0x15c sys/kern/subr_prf.c:207 malloc(78c,7f,1) at malloc+0xa23 sys/kern/kern_malloc.c:331 ktrgenio(ffff800020aee280,4,1,ffff8000000633a0,784) at ktrgenio+0x166 sys/kern/kern_ktrace.c:243 dofilewritev(ffff800020aee280,4,ffff800020aa9818,0,ffff800020aa9900) at dofilewritev+0x393 sys/kern/sys_generic.c:386 sys_write(ffff800020aee280,ffff800020aa98b0,ffff800020aa9900) at sys_write+0x83 sys/kern/sys_generic.c:285 syscall(ffff800020aa9980) at syscall+0x4a4 mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff800020aa9980) at syscall+0x4a4 sys/arch/amd64/amd64/trap.c:570 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x7f7fffff3e70, count: 7 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{0}> ddb{0}> set $lines = 0 ddb{0}> set $maxwidth = 0 ddb{0}> show panic Data modified on freelist: word 4 of object 0xffff800000a52000 size 0x78c previous type free (0x0 != 0xdead4110) ddb{0}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic(ffffffff821e5be6) at panic+0x15c sys/kern/subr_prf.c:207 malloc(78c,7f,1) at malloc+0xa23 sys/kern/kern_malloc.c:331 ktrgenio(ffff800020aee280,4,1,ffff8000000633a0,784) at ktrgenio+0x166 sys/kern/kern_ktrace.c:243 dofilewritev(ffff800020aee280,4,ffff800020aa9818,0,ffff800020aa9900) at dofilewritev+0x393 sys/kern/sys_generic.c:386 sys_write(ffff800020aee280,ffff800020aa98b0,ffff800020aa9900) at sys_write+0x83 sys/kern/sys_generic.c:285 syscall(ffff800020aa9980) at syscall+0x4a4 mi_syscall sys/sys/syscall_mi.h:102 [inline] syscall(ffff800020aa9980) at syscall+0x4a4 sys/arch/amd64/amd64/trap.c:570 Xsyscall() at Xsyscall+0x128 end of kernel end trace frame: 0x7f7fffff3e70, count: -8 ddb{0}> show registers rdi 0 rsi 0x1 rbp 0xffff800020aa94c0 rbx 0xffff800020aa9570 rdx 0xffff800020aee280 rcx 0 rax 0 r8 0xffffffff81bd1d7f kprintf+0x16f r9 0x1 r10 0x25 r11 0x5f5015ebf851661b r12 0x3000000008 r13 0xffff800020aa94d0 r14 0x100 r15 0x1 rip 0xffffffff818188e8 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020aa94b0 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{0}> show proc PROC (sshd) pid=426194 stat=onproc flags process=12 proc=1 pri=50, usrpri=51, nice=20 forw=0xffffffffffffffff, list=0xffff800020aee010,0xffff800020aef130 process=0xffff800020ad8798 user=0xffff800020aa4000, vmspace=0xfffffd806e9b08a8 estcpu=1, cpticks=3, pctcpu=0.0 user=0, sys=3, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 72877 185380 52855 0 2 0 syz-executor.1 72877 71225 52855 0 7 0x4000080 syz-executor.1 43893 494262 0 0 3 0x14200 bored sosplice 52855 397825 84048 0 3 0x82 nanosleep syz-executor.1 22088 383294 84048 0 2 0x2 syz-executor.0 84048 371013 52127 0 3 0x82 thrsleep syz-fuzzer 84048 202040 52127 0 3 0x4000082 nanosleep syz-fuzzer 84048 393758 52127 0 3 0x4000082 thrsleep syz-fuzzer 84048 407836 52127 0 3 0x4000082 thrsleep syz-fuzzer 84048 26917 52127 0 3 0x4000082 nanosleep syz-fuzzer 84048 255685 52127 0 3 0x4000082 kqread syz-fuzzer 84048 79894 52127 0 3 0x4000082 thrsleep syz-fuzzer 84048 495144 52127 0 3 0x4000082 thrsleep syz-fuzzer 84048 154097 52127 0 3 0x4000082 thrsleep syz-fuzzer 84048 116702 52127 0 3 0x4000082 thrsleep syz-fuzzer 52127 210189 58819 0 3 0x10008a pause ksh *58819 426194 29608 0 7 0x13 sshd 63560 156949 1 0 3 0x100083 ttyin getty 29608 262479 1 0 3 0x80 select sshd 23273 195562 76883 74 3 0x100092 bpf pflogd 76883 57807 1 0 3 0x80 netio pflogd 64764 408141 37256 73 3 0x100090 kqread syslogd 37256 340687 1 0 3 0x100082 netio syslogd 64404 91647 1 77 3 0x100090 poll dhclient 7417 489368 1 0 3 0x80 poll dhclient 74038 239374 0 0 3 0x14200 pgzero zerothread 98983 159711 0 0 3 0x14200 aiodoned aiodoned 21484 201584 0 0 3 0x14200 syncer update 75422 87606 0 0 3 0x14200 cleaner cleaner 19319 66340 0 0 3 0x14200 reaper reaper 27584 434652 0 0 3 0x14200 pgdaemon pagedaemon 38561 446208 0 0 3 0x14200 bored crynlk 62485 11648 0 0 3 0x14200 bored crypto 17308 89027 0 0 3 0x40014200 acpi0 acpi0 80451 188820 0 0 3 0x40014200 idle1 65664 4827 0 0 3 0x14200 bored softnet 98061 239533 0 0 3 0x14200 bored systqmp 7897 2113 0 0 3 0x14200 bored systq 87066 431957 0 0 3 0x40014200 bored softclock 23453 54824 0 0 3 0x40014200 idle0 50219 474060 0 0 3 0x14200 bored smr 1 520284 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{0}> show all locks CPU 0: exclusive mutex /syzkaller/managers/multicore/kernel/sys/kern/kern_malloc.c:104 r = 0 (0xffffffff824f4850) #0 witness_lock+0x52e sys/kern/subr_witness.c:1164 #1 mtx_enter_try+0x102 #2 mtx_enter+0x4b sys/kern/kern_lock.c:266 #3 malloc+0x23b sys/kern/kern_malloc.c:209 #4 ktrgenio+0x166 sys/kern/kern_ktrace.c:243 #5 dofilewritev+0x393 sys/kern/sys_generic.c:386 #6 sys_write+0x83 sys/kern/sys_generic.c:285 #7 syscall+0x4a4 mi_syscall sys/sys/syscall_mi.h:102 [inline] #7 syscall+0x4a4 sys/arch/amd64/amd64/trap.c:570 #8 Xsyscall+0x128 Process 72877 (syz-executor.1) thread 0xffff800020ae7d58 (71225) exclusive kernel_lock &kernel_lock r = 0 (0xffffffff8267c0b0) #0 witness_lock+0x52e sys/kern/subr_witness.c:1164 #1 __mp_acquire_count+0x51 sys/kern/kern_lock.c:227 #2 mi_switch+0x392 sys/kern/sched_bsd.c:435 #3 sleep_finish+0x113 sys/kern/kern_synch.c:415 #4 sleep_finish_all+0x32 sleep_finish_timeout sys/kern/kern_synch.c:444 [inline] #4 sleep_finish_all+0x32 sys/kern/kern_synch.c:206 #5 tsleep+0x1cc sys/kern/kern_synch.c:155 #6 single_thread_set+0x396 single_thread_wait sys/kern/kern_sig.c:2031 [inline] #6 single_thread_set+0x396 sys/kern/kern_sig.c:2022 #7 sys_execve+0x55 sys/kern/kern_exec.c:265 #8 syscall+0x4a4 mi_syscall sys/sys/syscall_mi.h:102 [inline] #8 syscall+0x4a4 sys/arch/amd64/amd64/trap.c:570 #9 Xsyscall+0x128 ddb{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim devbuf 9535 6548K 7245K 78643K 11208 0 pcb 13 8K 8K 78643K 102 0 rtable 79 2K 3K 78643K 279 0 ifaddr 84 16K 17K 78643K 119 0 counters 43 33K 34K 78643K 51 0 ioctlops 0 0K 4K 78643K 1489 0 iov 0 0K 16K 78643K 65 0 mount 1 1K 1K 78643K 1 0 vnodes 1226 77K 77K 78643K 1415 0 UFS quota 1 32K 32K 78643K 1 0 UFS mount 5 36K 36K 78643K 5 0 shm 2 1K 5K 78643K 6 0 VM map 2 1K 1K 78643K 2 0 sem 12 0K 1K 78643K 50 0 dirhash 12 2K 2K 78643K 12 0 ACPI 1809 196K 290K 78643K 12766 0 file desc 5 13K 25K 78643K 327 0 sigio 0 0K 0K 78643K 6 0 proc 62 63K 95K 78643K 478 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 0 0K 0K 78643K 43 0 in_multi 61 2K 3K 78643K 118 0 ether_multi 1 0K 0K 78643K 10 0 mrt 0 0K 0K 78643K 5 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 236 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 114 54K 54K 78643K 2094 0 UVM aobj 32 2K 2K 78643K 34 0 memdesc 1 4K 4K 78643K 1 0 crypto data 1 1K 1K 78643K 1 0 ip6_options 0 0K 0K 78643K 76 0 NDP 13 0K 0K 78643K 23 0 temp 142 3037K 3102K 78643K 15097 0 kqueue 3 4K 32K 78643K 46 0 SYN cache 2 16K 16K 78643K 2 0 ddb{0}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle arp 64 7 0 1 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtpcb 80 201 0 199 1 0 1 1 0 8 0 rtentry 112 58 0 27 2 0 2 2 0 8 0 unpcb 120 316 0 306 1 0 1 1 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpqe 32 269 0 269 2 2 0 1 0 8 0 tcpcb 544 301 0 297 1 0 1 1 0 8 0 inpcb 280 823 0 814 2 0 2 2 0 8 1 rttmr 72 1 0 1 1 1 0 1 0 8 0 nd6 48 8 0 8 1 0 1 1 0 8 1 pkpcb 40 2 0 2 1 1 0 1 0 8 0 pffrag 232 2 0 2 1 0 1 1 0 482 1 pffrnode 88 2 0 2 1 0 1 1 0 8 1 pffrent 40 50 0 50 1 0 1 1 0 8 1 pfosfp 40 846 0 423 5 0 5 5 0 8 0 pfosfpen 112 1428 0 714 21 0 21 21 0 8 0 pfstitem 24 43 0 5 1 0 1 1 0 8 0 pfstkey 112 43 0 5 2 0 2 2 0 8 0 pfstate 328 43 0 5 4 0 4 4 0 8 0 pfrule 1360 21 0 16 2 1 1 2 0 8 0 art_heap8 4096 2 0 0 2 0 2 2 0 8 0 art_heap4 256 248 0 130 12 0 12 12 0 8 3 art_table 32 250 0 130 2 0 2 2 0 8 0 art_node 16 57 0 28 1 0 1 1 0 8 0 sysvmsgpl 40 46 0 23 1 0 1 1 0 8 0 semupl 112 3 0 3 1 1 0 1 0 8 0 semapl 112 44 0 34 1 0 1 1 0 8 0 shmpl 112 32 0 2 1 0 1 1 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 1883 0 480 46 0 46 46 0 8 0 ffsino 272 1883 0 480 95 0 95 95 0 8 0 nchpl 144 2620 0 1005 61 0 61 61 0 8 0 uvmvnodes 72 2061 0 0 38 0 38 38 0 8 0 vnodes 208 2061 0 0 109 0 109 109 0 8 0 namei 1024 7392 0 7392 1 0 1 1 0 8 1 percpumem 16 36 0 4 1 0 1 1 0 8 0 vcpupl 1984 4 0 0 1 0 1 1 0 8 0 vmpool 560 4 0 0 1 0 1 1 0 8 0 scxspl 192 8033 0 8033 8 7 1 7 0 8 1 plimitpl 152 37 0 29 1 0 1 1 0 8 0 sigapl 432 526 0 511 3 1 2 3 0 8 0 futexpl 56 6860 0 6860 1 0 1 1 0 8 1 knotepl 112 172 0 153 3 2 1 3 0 8 0 kqueuepl 144 120 0 118 1 0 1 1 0 8 0 pipelkpl 48 139 0 129 1 0 1 1 0 8 0 pipepl 120 278 0 259 1 0 1 1 0 8 0 fdescpl 496 527 0 511 3 0 3 3 0 8 0 filepl 152 4119 0 4018 7 1 6 6 0 8 2 lockfpl 104 140 0 139 1 0 1 1 0 8 0 lockfspl 48 43 0 42 1 0 1 1 0 8 0 sessionpl 112 18 0 7 1 0 1 1 0 8 0 pgrppl 48 18 0 7 1 0 1 1 0 8 0 ucredpl 96 364 0 355 1 0 1 1 0 8 0 zombiepl 144 513 0 513 1 0 1 1 0 8 1 processpl 960 545 0 513 5 0 5 5 0 8 0 procpl 624 1303 0 1261 5 1 4 5 0 8 0 sosppl 128 3 0 3 1 0 1 1 0 8 1 sockpl 400 1358 0 1339 6 2 4 6 0 8 2 mcl64k 65536 7 0 0 1 0 1 1 0 8 0 mcl16k 16384 2 0 0 1 0 1 1 0 8 0 mcl12k 12288 4 0 0 1 0 1 1 0 8 0 mcl9k 9216 2 0 0 1 0 1 1 0 8 0 mcl8k 8192 4 0 0 1 0 1 1 0 8 0 mcl4k 4096 7 0 0 1 0 1 1 0 8 0 mcl2k2 2112 2 0 0 1 0 1 1 0 8 0 mcl2k 2048 169 0 0 21 0 21 21 0 8 0 mtagpl 80 29 0 0 1 0 1 1 0 8 0 mbufpl 256 348 0 0 20 0 20 20 0 8 0 bufpl 280 6138 0 179 426 0 426 426 0 8 0 anonpl 16 66484 0 49664 85 12 73 84 0 124 5 amapchunkpl 152 3600 0 3463 15 6 9 13 0 158 2 amappl16 192 2613 0 1700 60 11 49 58 0 8 3 amappl15 184 1 0 1 1 1 0 1 0 8 0 amappl14 176 4 0 2 3 2 1 1 0 8 0 amappl13 168 34 0 32 1 0 1 1 0 8 0 amappl12 160 18 0 15 1 0 1 1 0 8 0 amappl11 152 201 0 182 1 0 1 1 0 8 0 amappl10 144 184 0 173 1 0 1 1 0 8 0 amappl9 136 390 0 387 1 0 1 1 0 8 0 amappl8 128 328 0 302 1 0 1 1 0 8 0 amappl7 120 282 0 269 1 0 1 1 0 8 0 amappl6 112 154 0 152 2 1 1 1 0 8 0 amappl5 104 430 0 413 1 0 1 1 0 8 0 amappl4 96 502 0 471 2 1 1 2 0 8 0 amappl3 88 113 0 108 1 0 1 1 0 8 0 amappl2 80 3307 0 3236 3 1 2 3 0 8 0 amappl1 72 21442 0 20998 26 16 10 21 0 8 0 amappl 80 1566 0 1520 2 0 2 2 0 84 0 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 33 0 2 1 0 1 1 0 8 0 uaddrrnd 24 531 0 511 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 531 0 511 1 0 1 1 0 8 0 vmmpekpl 168 7882 0 7844 2 0 2 2 0 8 0 vmmpepl 168 71839 0 69771 121 23 98 113 0 357 4 vmsppl 368 530 0 511 2 0 2 2 0 8 0 pdppl 4096 1069 0 1026 6 0 6 6 0 8 0 pvpl 32 212163 0 191703 202 12 190 202 0 265 25 pmappl 232 530 0 511 2 0 2 2 0 8 0 extentpl 40 46 0 29 1 0 1 1 0 8 0 phpool 112 182 0 6 6 0 6 6 0 8 0