panic: kernel diagnostic assertion "tname->un_flags & UNVEIL_USERSET" failed: file "/syzkaller/managers/setuid/kernel/sys/kern/kern_unveil.c", line 879 Stopped at db_enter+0x18: addq $0x8,%rsp TID PID UID PRFLAGS PFLAGS CPU COMMAND 145067 11695 32767 0x10 0 1 syz-executor.1 *271030 11695 32767 0x10 0x4000000 0K syz-executor.1 db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x174 sys/kern/subr_prf.c:208 __assert(ffffffff81f7dcd5,ffffffff81f30eae,36f,ffffffff81f8a767) at __assert+0x2e sys/kern/subr_prf.c:155 unveil_check_final(ffff800020b284c8,ffff800020c32c80) at unveil_check_final+0x81d sys/kern/kern_unveil.c:879 namei(ffff800020c32c80) at namei+0x88b sys/kern/vfs_lookup.c:232 vn_open(ffff800020c32c80,1,0) at vn_open+0xc7 sys/kern/vfs_vnops.c:137 doopenat(ffff800020b284c8,ffffff9c,20000080,0,0,ffff800020c32ec0) at doopenat+0x2ca sys/kern/vfs_syscalls.c:1045 syscall(ffff800020c32f70) at syscall+0x5b8 mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff800020c32f70) at syscall+0x5b8 sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,0,ffffffffffffffad,0,4,e7f62798010) at Xsyscall+0x128 end of kernel end trace frame: 0xe8229bbbeb0, count: 6 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 "tname->un_flags & UNVEIL_USERSET" failed: file "/syzkaller/managers/setuid/kernel/sys/kern/kern_unveil.c", line 879 ddb{0}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398 panic() at panic+0x174 sys/kern/subr_prf.c:208 __assert(ffffffff81f7dcd5,ffffffff81f30eae,36f,ffffffff81f8a767) at __assert+0x2e sys/kern/subr_prf.c:155 unveil_check_final(ffff800020b284c8,ffff800020c32c80) at unveil_check_final+0x81d sys/kern/kern_unveil.c:879 namei(ffff800020c32c80) at namei+0x88b sys/kern/vfs_lookup.c:232 vn_open(ffff800020c32c80,1,0) at vn_open+0xc7 sys/kern/vfs_vnops.c:137 doopenat(ffff800020b284c8,ffffff9c,20000080,0,0,ffff800020c32ec0) at doopenat+0x2ca sys/kern/vfs_syscalls.c:1045 syscall(ffff800020c32f70) at syscall+0x5b8 mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(ffff800020c32f70) at syscall+0x5b8 sys/arch/amd64/amd64/trap.c:574 Xsyscall(6,0,ffffffffffffffad,0,4,e7f62798010) at Xsyscall+0x128 end of kernel end trace frame: 0xe8229bbbeb0, count: -9 ddb{0}> show registers rdi 0xffffffff81c97597 db_enter+0x17 rsi 0x383e __ALIGN_SIZE+0x283e rbp 0xffff800020c328c0 rbx 0xffff800020c32970 rdx 0x383f __ALIGN_SIZE+0x283f rcx 0xffff800002b4f000 rax 0xffff800002b4f000 r8 0xffffffff814ea2c3 kprintf+0x183 r9 0x1 r10 0x25 r11 0x3651a7b6c6b3857 r12 0x3000000008 r13 0xffff800020c328d0 r14 0x100 r15 0x1 rip 0xffffffff81c97598 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020c328b0 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{0}> show proc PROC (syz-executor.1) pid=271030 stat=onproc flags process=10 proc=4000000 pri=86, usrpri=86, nice=20 forw=0xffffffffffffffff, list=0xffff800020b29c38,0xffffffff82349db8 process=0xffff800020b7c018 user=0xffff800020c2e000, vmspace=0xfffffd807effe5a0 estcpu=36, cpticks=1, pctcpu=0.0 user=0, sys=1, intr=0 ddb{0}> ps PID TID PPID UID S FLAGS WAIT COMMAND 11695 145067 32680 32767 7 0x10 syz-executor.1 *11695 271030 32680 32767 7 0x4000010 syz-executor.1 32680 203486 14905 32767 2 0x490 syz-executor.1 80828 180199 92545 32767 2 0x490 syz-executor.0 14905 290104 22596 0 3 0x82 wait syz-executor.1 92545 342880 22596 0 3 0x82 wait syz-executor.0 22596 447724 845 0 3 0x82 thrsleep syz-fuzzer 22596 182907 845 0 3 0x4000082 thrsleep syz-fuzzer 22596 371009 845 0 3 0x4000082 thrsleep syz-fuzzer 22596 306535 845 0 3 0x4000082 thrsleep syz-fuzzer 22596 433186 845 0 3 0x4000082 thrsleep syz-fuzzer 22596 205414 845 0 3 0x4000082 thrsleep syz-fuzzer 22596 370966 845 0 3 0x4000082 kqread syz-fuzzer 22596 202372 845 0 3 0x4000082 thrsleep syz-fuzzer 22596 249154 845 0 3 0x4000082 thrsleep syz-fuzzer 22596 47598 845 0 3 0x4000082 thrsleep syz-fuzzer 845 32672 80774 0 3 0x10008a pause ksh 80774 440760 79334 0 3 0x92 select sshd 10757 319491 1 0 3 0x100083 ttyin getty 79334 220585 1 0 3 0x80 select sshd 34294 499577 6171 73 3 0x100090 kqread syslogd 6171 56694 1 0 3 0x100082 netio syslogd 47110 142816 1 77 3 0x100090 poll dhclient 98797 235495 1 0 3 0x80 poll dhclient 73306 492559 0 0 3 0x14200 pgzero zerothread 17910 442374 0 0 3 0x14200 aiodoned aiodoned 9558 162498 0 0 3 0x14200 syncer update 57691 484330 0 0 3 0x14200 cleaner cleaner 63184 221752 0 0 3 0x14200 reaper reaper 27415 287369 0 0 3 0x14200 pgdaemon pagedaemon 87503 298508 0 0 3 0x14200 bored crynlk 53774 386519 0 0 3 0x14200 bored crypto 2849 329279 0 0 3 0x40014200 acpi0 acpi0 36594 319880 0 0 3 0x40014200 idle1 65374 301766 0 0 3 0x14200 bored softnet 24165 267931 0 0 3 0x14200 bored systqmp 13988 110956 0 0 3 0x14200 bored systq 59883 255940 0 0 3 0x40014200 bored softclock 20955 348526 0 0 3 0x40014200 idle0 15747 114823 0 0 3 0x14200 bored smr 1 276208 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper ddb{0}> show all locks Process 11695 (syz-executor.1) thread 0xffff800020b284c8 (271030) exclusive rrwlock inode r = 0 (0xfffffd806e664918) locked @ /syzkaller/managers/setuid/kernel/sys/ufs/ufs/ufs_vnops.c:1547 #0 witness_lock+0x594 sys/kern/subr_witness.c:1201 #1 _rw_enter+0x45d sys/kern/kern_rwlock.c:280 #2 _rrw_enter+0x60 sys/kern/kern_rwlock.c:410 #3 VOP_LOCK+0x57 sys/kern/vfs_vops.c:602 #4 vn_lock+0x6e sys/kern/vfs_vnops.c:549 #5 vget+0x1c3 sys/kern/vfs_subr.c:672 #6 cache_lookup+0x300 sys/kern/vfs_cache.c:224 #7 ufs_lookup+0x1d7 sys/ufs/ufs/ufs_lookup.c:162 #8 VOP_LOOKUP+0x67 sys/kern/vfs_vops.c:90 #9 vfs_lookup+0x556 sys/kern/vfs_lookup.c:523 #10 namei+0x4b2 sys/kern/vfs_lookup.c:224 #11 vn_open+0xc7 sys/kern/vfs_vnops.c:137 #12 doopenat+0x2ca sys/kern/vfs_syscalls.c:1045 #13 syscall+0x5b8 mi_syscall sys/sys/syscall_mi.h:99 [inline] #13 syscall+0x5b8 sys/arch/amd64/amd64/trap.c:574 #14 Xsyscall+0x128 exclusive kernel_lock &kernel_lock r = 0 (0xffffffff82350b68) locked @ /syzkaller/managers/setuid/kernel/sys/sys/syscall_mi.h:90 #0 witness_lock+0x594 sys/kern/subr_witness.c:1201 #1 syscall+0x48b mi_syscall sys/sys/syscall_mi.h:91 [inline] #1 syscall+0x48b sys/arch/amd64/amd64/trap.c:574 #2 Xsyscall+0x128 ddb{0}> show malloc Type InUse MemUse HighUse Limit Requests Type Lim Kern Lim devbuf 9457 6320K 6320K 78643K 10544 0 0 pcb 23 9K 9K 78643K 119 0 0 rtable 97 3K 3K 78643K 167 0 0 ifaddr 34 9K 9K 78643K 34 0 0 counters 39 33K 33K 78643K 39 0 0 ioctlops 0 0K 2K 78643K 15 0 0 mount 1 1K 1K 78643K 1 0 0 vnodes 1200 75K 75K 78643K 1289 0 0 UFS quota 1 32K 32K 78643K 1 0 0 UFS mount 5 36K 36K 78643K 5 0 0 shm 2 1K 1K 78643K 2 0 0 VM map 2 1K 1K 78643K 2 0 0 sem 12 0K 0K 78643K 128 0 0 dirhash 12 2K 2K 78643K 12 0 0 ACPI 1808 196K 290K 78643K 12628 0 0 file desc 7 21K 29K 78643K 382 0 0 sigio 0 0K 0K 78643K 28 0 0 proc 46 50K 58K 78643K 281 0 0 subproc 68 69634K 69634K 78643K 68 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 10 0 0 in_multi 33 2K 2K 78643K 33 0 0 ether_multi 1 0K 0K 78643K 1 0 0 ISOFS mount 1 32K 32K 78643K 1 0 0 MSDOSFS mount 1 16K 16K 78643K 1 0 0 ttys 48 212K 212K 78643K 48 0 0 exec 0 0K 1K 78643K 172 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 80 20K 20K 78643K 1618 0 0 UVM aobj 2 2K 2K 78643K 2 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 34 0 0 NDP 5 0K 0K 78643K 9 0 0 temp 120 2374K 2440K 78643K 3689 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 4 0 0 1 0 1 1 0 8 0 inpcbpl 280 144 0 137 1 0 1 1 0 8 0 plimitpl 152 96 0 87 1 0 1 1 0 8 0 plcache 128 20 0 0 1 0 1 1 0 8 0 rtentry 112 41 0 1 2 0 2 2 0 8 0 syncache 264 4 0 4 1 1 0 1 0 8 0 tcpcb 544 68 0 64 1 0 1 1 0 8 0 nd6 48 4 0 0 1 0 1 1 0 8 0 art_heap8 4096 1 0 0 1 0 1 1 0 8 0 art_heap4 256 185 0 0 12 0 12 12 0 8 0 art_table 32 186 0 0 2 0 2 2 0 8 0 art_node 16 40 0 6 1 0 1 1 0 8 0 semupl 112 9 0 9 1 1 0 1 0 8 0 semapl 112 126 0 116 1 0 1 1 0 8 0 dirhash 1024 17 0 0 3 0 3 3 0 8 0 dino1pl 128 1873 0 459 46 0 46 46 0 8 0 ffsino 272 1873 0 459 95 0 95 95 0 8 0 nchpl 144 2566 0 942 61 0 61 61 0 8 0 uvmvnodes 72 1916 0 0 35 0 35 35 0 8 0 vnodes 200 1916 0 0 101 0 101 101 0 8 0 namei 1024 7294 0 7293 2 1 1 1 0 8 0 percpumem 16 30 0 0 1 0 1 1 0 8 0 scxspl 192 6226 0 6226 8 7 1 7 0 8 1 sigapl 432 552 0 537 2 0 2 2 0 8 0 futexpl 56 3697 0 3697 1 0 1 1 0 8 1 knotepl 112 105 0 86 1 0 1 1 0 8 0 kqueuepl 104 50 0 48 1 0 1 1 0 8 0 pipepl 112 278 0 259 2 1 1 1 0 8 0 fdescpl 488 553 0 537 3 0 3 3 0 8 0 filepl 152 3032 0 2935 5 0 5 5 0 8 1 lockfpl 104 6 0 6 1 1 0 1 0 8 0 lockfspl 32 3 0 3 1 1 0 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 1285 0 1276 1 0 1 1 0 8 0 zombiepl 144 537 0 536 2 1 1 1 0 8 0 processpl 840 568 0 536 4 0 4 4 0 8 0 procpl 600 1054 0 1012 4 0 4 4 0 8 0 sockpl 384 250 0 233 4 1 3 3 0 8 1 mcl4k 4096 18 0 0 3 0 3 3 0 8 0 mcl2k 2048 92 0 0 11 0 11 11 0 8 0 mtagpl 80 1 0 0 1 0 1 1 0 8 0 mbufpl 256 190 0 0 12 0 12 12 0 8 0 bufpl 256 5913 0 1122 300 0 300 300 0 8 0 anonpl 16 49664 0 47083 18 3 15 15 0 125 2 amapchunkpl 152 2024 0 1942 5 1 4 5 0 158 0 amappl16 192 1826 0 1740 8 0 8 8 0 8 3 amappl15 184 48 0 44 1 0 1 1 0 8 0 amappl14 176 27 0 22 2 1 1 1 0 8 0 amappl13 168 26 0 23 1 0 1 1 0 8 0 amappl12 160 8 0 5 2 1 1 1 0 8 0 amappl11 152 17 0 6 1 0 1 1 0 8 0 amappl10 144 244 0 241 2 1 1 1 0 8 0 amappl9 136 610 0 605 1 0 1 1 0 8 0 amappl8 128 306 0 284 1 0 1 1 0 8 0 amappl7 120 208 0 204 1 0 1 1 0 8 0 amappl6 112 56 0 47 1 0 1 1 0 8 0 amappl5 104 330 0 321 1 0 1 1 0 8 0 amappl4 96 737 0 713 2 1 1 2 0 8 0 amappl3 88 117 0 110 1 0 1 1 0 8 0 amappl2 80 3905 0 3850 2 0 2 2 0 8 0 amappl1 72 19838 0 19401 25 15 10 19 0 8 0 amappl 72 1253 0 1220 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 1 0 0 1 0 1 1 0 8 0 uaddrrnd 24 553 0 537 1 0 1 1 0 8 0 uaddrbest 32 2 0 0 1 0 1 1 0 8 0 uaddr 24 553 0 537 1 0 1 1 0 8 0 vmmpekpl 168 7675 0 7653 2 0 2 2 0 8 0 vmmpepl 168 64062 0 62947 86 27 59 72 0 357 6 vmsppl 360 552 0 537 2 0 2 2 0 8 0 pdppl 4096 1114 0 1074 6 0 6 6 0 8 0 pvpl 32 195195 0 189458 105 16 89 102 0 265 36 pmappl 224 552 0 537 2 1 1 2 0 8 0 extentpl 40 39 0 25 1 0 1 1 0 8 0 phpool 112 448 0 3 13 0 13 13 0 8 0