login: panic: kernel diagnostic assertion "ps->ps_uvncount == 0" failed: file "/syzkaller/managers/setuid/kernel/sys/kern/kern_unveil.c", line 196 Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 272999 91247 0 0x14000 0x200 1 reaper db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x15c sys/kern/subr_prf.c:212 __assert(ffffffff81f9834f,ffffffff81f4feb7,c4,ffffffff81f5a832) at __assert+0x2e sys/kern/subr_prf.c:159 unveil_destroy(ffff800020b3b3c0) at unveil_destroy+0x19f sys/kern/kern_unveil.c:196 exit1(ffff800020b39c38,0,1) at exit1+0x354 sys/kern/kern_exit.c:216 sys_exit(ffff800020b39c38,ffff800020c15580,ffff800020c155f0) at sys_exit+0x17 sys/kern/kern_exit.c:94 syscall(ffff800020c15660) at syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff800020c15660) at syscall+0x552 sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,1,0,1,431bde82d7b634db,7f7ffffd8cd8) at Xsyscall+0x128 end trace frame: 0x0, 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 kernel diagnostic assertion "ps->ps_uvncount == 0" failed: file "/syzkaller/managers/setuid/kernel/sys/kern/kern_unveil.c", line 196 ddb{0}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x15c sys/kern/subr_prf.c:212 __assert(ffffffff81f9834f,ffffffff81f4feb7,c4,ffffffff81f5a832) at __assert+0x2e sys/kern/subr_prf.c:159 unveil_destroy(ffff800020b3b3c0) at unveil_destroy+0x19f sys/kern/kern_unveil.c:196 exit1(ffff800020b39c38,0,1) at exit1+0x354 sys/kern/kern_exit.c:216 sys_exit(ffff800020b39c38,ffff800020c15580,ffff800020c155f0) at sys_exit+0x17 sys/kern/kern_exit.c:94 syscall(ffff800020c15660) at syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff800020c15660) at syscall+0x552 sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,1,0,1,431bde82d7b634db,7f7ffffd8cd8) at Xsyscall+0x128 end trace frame: 0x0, count: -8 ddb{0}> show registers rdi 0 rsi 0x1 rbp 0xffff800020c15380 rbx 0xffff800020c15430 rdx 0xffff800020b39c38 rcx 0 rax 0 r8 0xffffffff8177e313 kprintf+0x173 r9 0x1 r10 0x25 r11 0x45cc96ee98b3e7ac r12 0x3000000008 r13 0xffff800020c15390 r14 0x100 r15 0x1 rip 0xffffffff81967bf8 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020c15370 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{0}> show proc PROC (syz-executor.0) pid=439521 stat=onproc flags process=1018 proc=2000 pri=50, usrpri=86, nice=20 forw=0xffffffffffffffff, list=0xffff800020b38720,0xffffffff8235aaa8 process=0xffff800020b3b3c0 user=0xffff800020c10000, vmspace=0xfffffd807effeb40 estcpu=36, cpticks=6, pctcpu=0.0 user=0, sys=1, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 54653 313979 42118 32767 2 0x10 syz-executor.1 42118 159251 89190 0 3 0x82 wait syz-executor.1 82985 184936 77269 32767 2 0x490 syz-executor.0 77269 448274 89190 0 3 0x82 wait syz-executor.0 44811 379559 0 0 3 0x14200 bored sosplice 89190 314076 94397 0 3 0x82 thrsleep syz-fuzzer 89190 127275 94397 0 3 0x4000082 thrsleep syz-fuzzer 89190 86812 94397 0 3 0x4000082 thrsleep syz-fuzzer 89190 69424 94397 0 3 0x4000082 thrsleep syz-fuzzer 89190 465243 94397 0 3 0x4000082 thrsleep syz-fuzzer 89190 340823 94397 0 3 0x4000082 kqread syz-fuzzer 89190 203383 94397 0 3 0x4000082 thrsleep syz-fuzzer 89190 204201 94397 0 3 0x4000082 thrsleep syz-fuzzer 89190 245282 94397 0 3 0x4000082 thrsleep syz-fuzzer 89190 337780 94397 0 3 0x4000082 thrsleep syz-fuzzer 94397 61107 60194 0 3 0x10008a pause ksh 60194 439352 25662 0 3 0x92 select sshd 52626 514787 1 0 3 0x100083 ttyin getty 25662 446479 1 0 3 0x80 select sshd 16362 188341 20060 73 3 0x100090 kqread syslogd 20060 440961 1 0 3 0x100082 netio syslogd 87186 488631 1 77 3 0x100090 poll dhclient 61129 277784 1 0 3 0x80 poll dhclient 33153 354699 0 0 3 0x14200 pgzero zerothread 52707 313429 0 0 3 0x14200 aiodoned aiodoned 75242 345484 0 0 3 0x14200 syncer update 62649 172060 0 0 3 0x14200 cleaner cleaner 91247 272999 0 0 7 0x14200 reaper 89534 477049 0 0 3 0x14200 pgdaemon pagedaemon 3604 64967 0 0 3 0x14200 bored crynlk 67975 291363 0 0 3 0x14200 bored crypto 46884 440923 0 0 3 0x40014200 acpi0 acpi0 85763 100123 0 0 3 0x40014200 idle1 65800 342809 0 0 3 0x14200 bored softnet 10589 499306 0 0 3 0x14200 bored systqmp 63649 490293 0 0 3 0x14200 bored systq 42247 359977 0 0 3 0x40014200 bored softclock 21858 207864 0 0 3 0x40014200 idle0 78513 194347 0 0 3 0x14200 bored smr 1 286433 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{0}> show all locks Process 54653 (syz-executor.1) thread 0xffff800020b38720 (313979) exclusive rrwlock inode r = 0 (0xfffffd8075a98918) #0 witness_lock+0x52e sys/kern/subr_witness.c:1161 #1 rw_enter+0x414 sys/kern/kern_rwlock.c:278 #2 rrw_enter+0x4f sys/kern/kern_rwlock.c:407 #3 ufs_ihashins+0x45 sys/ufs/ufs/ufs_ihash.c:140 #4 ffs_vget+0x133 sys/ufs/ffs/ffs_vfsops.c:1352 #5 ffs_inode_alloc+0x1cf sys/ufs/ffs/ffs_alloc.c:392 #6 ufs_mkdir+0xf4 sys/ufs/ufs/ufs_vnops.c:1164 #7 VOP_MKDIR+0x6a sys/kern/vfs_vops.c:449 #8 domkdirat+0x121 sys/kern/vfs_syscalls.c:2881 #9 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] #9 syscall+0x552 sys/arch/amd64/amd64/trap.c:574 #10 Xsyscall+0x128 exclusive rrwlock inode r = 0 (0xfffffd8075a98a28) #0 witness_lock+0x52e sys/kern/subr_witness.c:1161 #1 rw_enter+0x414 sys/kern/kern_rwlock.c:278 #2 rrw_enter+0x4f sys/kern/kern_rwlock.c:407 #3 VOP_LOCK+0x4b sys/kern/vfs_vops.c:602 #4 vn_lock+0x6e sys/kern/vfs_vnops.c:549 #5 vfs_lookup+0xec sys/kern/vfs_lookup.c:387 #6 namei+0x45f sys/kern/vfs_lookup.c:224 #7 domkdirat+0x75 sys/kern/vfs_syscalls.c:2866 #8 syscall+0x552 mi_syscall sys/sys/syscall_mi.h:99 [inline] #8 syscall+0x552 sys/arch/amd64/amd64/trap.c:574 #9 Xsyscall+0x128 ddb{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9460 6321K 6321K 78643K 10612 0 0 pcb 23 9K 11K 78643K 445 0 0 rtable 105 3K 3K 78643K 775 0 0 ifaddr 35 10K 10K 78643K 116 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 51 0 0 iov 0 0K 24K 78643K 87 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1201 75K 75K 78643K 1524 0 0 UFS quota 1 32K 32K 78643K 1 0 0 UFS mount 5 36K 36K 78643K 5 0 0 shm 2 1K 5K 78643K 14 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 1K 78643K 137 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1808 196K 290K 78643K 12628 0 0 file desc 6 17K 33K 78643K 756 0 0 sigio 0 0K 0K 78643K 12 0 0 proc 44 50K 78K 78643K 920 0 0 subproc 68 69634K 69634K 78643K 510 0 0 NFS srvsock 1 0K 0K 78643K 1 0 0 NFS daemon 1 16K 16K 78643K 1 0 0 ip_moptions 0 0K 0K 78643K 100 0 0 in_multi 33 2K 2K 78643K 193 0 0 ether_multi 1 0K 0K 78643K 4 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 60 265K 265K 78643K 60 0 0 exec 0 0K 1K 78643K 383 0 0 pagedep 1 8K 8K 78643K 1 0 0 inodedep 1 32K 32K 78643K 1 0 0 newblk 1 0K 0K 78643K 1 0 0 VM swap 7 26K 26K 78643K 7 0 0 UVM amap 78 20K 29K 78643K 3227 0 0 UVM aobj 70 3K 3K 78643K 70 0 0 memdesc 1 4K 4K 78643K 1 0 0 crypto data 1 1K 1K 78643K 1 0 0 ip6_options 0 0K 0K 78643K 50 0 0 NDP 7 0K 0K 78643K 48 0 0 temp 121 2730K 2858K 78643K 8576 0 0 kqueue 0 0K 0K 78643K 3 0 0 SYN cache 2 16K 16K 78643K 2 0 0 ddb{0}> show all pools Name Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle arp 64 32 0 26 1 0 1 1 0 8 0 inpcbpl 280 400 0 393 1 0 1 1 0 8 0 plimitpl 152 82 0 73 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtentry 112 188 0 144 2 0 2 2 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpcb 544 158 0 154 1 0 1 1 0 8 0 nd6 48 45 0 39 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 767 0 576 12 0 12 12 0 8 0 art_table 32 768 0 576 2 0 2 2 0 8 0 art_node 16 187 0 147 1 0 1 1 0 8 0 sysvmsgpl 40 4 0 4 2 2 0 1 0 8 0 semupl 112 1 0 1 1 1 0 1 0 8 0 semapl 112 135 0 125 1 0 1 1 0 8 0 shmpl 112 68 0 0 2 0 2 2 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 2177 0 738 47 0 47 47 0 8 0 ffsino 272 2177 0 738 97 0 97 97 0 8 0 nchpl 144 3289 0 1665 61 0 61 61 0 8 0 uvmvnodes 72 2441 0 0 45 0 45 45 0 8 0 vnodes 200 2441 0 0 129 0 129 129 0 8 0 namei 1024 10551 0 10550 2 1 1 1 0 8 0 percpumem 16 30 0 0 1 0 1 1 0 8 0 scxspl 192 19623 0 19623 11 10 1 6 0 8 1 sigapl 432 887 0 872 4 2 2 3 0 8 0 futexpl 56 7196 0 7196 1 0 1 1 0 8 1 knotepl 112 423 0 404 1 0 1 1 0 8 0 kqueuepl 104 146 0 144 1 0 1 1 0 8 0 pipepl 112 680 0 661 4 3 1 2 0 8 0 fdescpl 488 888 0 873 3 0 3 3 0 8 1 filepl 152 5215 0 5119 8 3 5 6 0 8 1 lockfpl 104 127 0 127 2 1 1 1 0 8 1 lockfspl 48 43 0 43 2 1 1 1 0 8 1 sessionpl 112 30 0 20 1 0 1 1 0 8 0 pgrppl 48 42 0 32 1 0 1 1 0 8 0 ucredpl 96 1171 0 1162 1 0 1 1 0 8 0 zombiepl 144 873 0 872 2 1 1 1 0 8 0 processpl 840 904 0 872 4 0 4 4 0 8 0 procpl 600 2087 0 2045 4 0 4 4 0 8 0 srpgc 64 78 0 78 5 4 1 1 0 8 1 sosppl 128 17 0 17 4 3 1 1 0 8 1 sockpl 384 852 0 835 6 3 3 4 0 8 1 mcl64k 65536 3 0 0 1 0 1 1 0 8 0 mcl12k 12288 5 0 0 1 0 1 1 0 8 0 mcl9k 9216 5 0 0 1 0 1 1 0 8 0 mcl8k 8192 8 0 0 1 0 1 1 0 8 0 mcl4k 4096 9 0 0 2 0 2 2 0 8 0 mcl2k2 2112 2 0 0 1 0 1 1 0 8 0 mcl2k 2048 119 0 0 14 0 14 14 0 8 0 mtagpl 80 1 0 0 1 0 1 1 0 8 0 mbufpl 256 203 0 0 11 0 11 11 0 8 0 bufpl 256 24027 0 17816 390 1 389 390 0 8 0 anonpl 16 95590 0 89556 63 17 46 46 0 125 17 amapchunkpl 152 6361 0 6275 15 10 5 9 0 158 1 amappl16 192 3436 0 3076 41 12 29 31 0 8 8 amappl15 184 68 0 68 1 1 0 1 0 8 0 amappl14 176 337 0 332 2 1 1 1 0 8 0 amappl13 168 24 0 23 1 0 1 1 0 8 0 amappl12 160 117 0 111 1 0 1 1 0 8 0 amappl11 152 214 0 196 1 0 1 1 0 8 0 amappl10 144 113 0 111 1 0 1 1 0 8 0 amappl9 136 769 0 766 1 0 1 1 0 8 0 amappl8 128 293 0 275 1 0 1 1 0 8 0 amappl7 120 92 0 86 1 0 1 1 0 8 0 amappl6 112 166 0 158 1 0 1 1 0 8 0 amappl5 104 281 0 269 1 0 1 1 0 8 0 amappl4 96 869 0 841 2 1 1 2 0 8 0 amappl3 88 488 0 482 1 0 1 1 0 8 0 amappl2 80 5452 0 5401 2 0 2 2 0 8 0 amappl1 72 31767 0 31313 24 14 10 19 0 8 0 amappl 72 2516 0 2481 1 0 1 1 0 75 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 dma64 64 259 0 259 1 1 0 1 0 8 0 dma32 32 7 0 7 1 1 0 1 0 8 0 dma16 16 17 0 17 1 1 0 1 0 8 0 aobjpl 64 69 0 0 2 0 2 2 0 8 0 uaddrrnd 24 888 0 872 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 888 0 872 1 0 1 1 0 8 0 vmmpekpl 168 11255 0 11232 2 0 2 2 0 8 0 vmmpepl 168 104023 0 102619 111 34 77 78 0 357 12 vmsppl 360 887 0 872 2 0 2 2 0 8 0 pdppl 4096 1784 0 1744 6 0 6 6 0 8 0 pvpl 32 296651 0 287426 175 53 122 122 0 265 37 pmappl 232 887 0 872 3 2 1 2 0 8 0 extentpl 40 39 0 25 1 0 1 1 0 8 0 phpool 112 543 0 4 16 0 16 16 0 8 0