syzbot


protection_fault: sys_msgrcv

Status: auto-closed as invalid on 2022/05/19 20:14
Reported-by: syzbot+fefe9a923d4a03b8735a@syzkaller.appspotmail.com
First crash: 881d, last: 881d
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
openbsd protection_fault: sys_msgrcv (2) C 31 74d 645d 0/3 upstream: reported C repro on 2022/10/13 01:20

Sample crash report:
login: kernel: protection fault trap, code=0
Stopped at      sys_msgrcv+0x2df:       movq    0x10(%r13),%rdi
ddb{1}> 
ddb{1}> set $lines = 0
ddb{1}> set $maxwidth = 0
ddb{1}> show panic
the kernel did not panic
ddb{1}> trace
sys_msgrcv(ffff8000fffefa48,ffff80002af38448,ffff80002af384a0) at sys_msgrcv+0x2df msg_copyout sys/kern/sysv_msg.c:649 [inline]
sys_msgrcv(ffff8000fffefa48,ffff80002af38448,ffff80002af384a0) at sys_msgrcv+0x2df sys/kern/sysv_msg.c:359
syscall(ffff80002af38510) at syscall+0x489 mi_syscall sys/sys/syscall_mi.h:102 [inline]
syscall(ffff80002af38510) at syscall+0x489 sys/arch/amd64/amd64/trap.c:585
Xsyscall() at Xsyscall+0x128
end of kernel
end trace frame: 0xa8290d8120, count: -3
ddb{1}> show registers
rdi                           0x106e    __ALIGN_SIZE+0x6e
rsi                       0x200013c8
rbp               0xffff80002af38430
rbx                           0x106e    __ALIGN_SIZE+0x6e
rdx                                0
rcx                                0
rax               0xffff8000fffefa48
r8                    0x7f7fffffc000
r9                               0x1
r10                0xe800e94b9b4a95c
r11               0xb6f473f1d535dac3
r12               0xfffffd8062f10bb8
r13               0xdeadbeefdeadbeef
r14               0xffff800000c35700
r15                            0x1c0
rip               0xffffffff823d1ecf    sys_msgrcv+0x2df
cs                               0x8
rflags                       0x10202    __ALIGN_SIZE+0xf202
rsp               0xffff80002af383a0
ss                                 0
sys_msgrcv+0x2df:       movq    0x10(%r13),%rdi
ddb{1}> show proc
PROC (syz-executor.6) pid=318481 stat=onproc
    flags process=10<SUGID> proc=4000000<THREAD>
    pri=36, usrpri=86, nice=20
    forw=0xffffffffffffffff, list=0xffff8000fffeea88,0xffff8000fffeed38
    process=0xffff8000fffea588 user=0xffff80002af33000, vmspace=0xfffffd8065c012f8
    estcpu=36, cpticks=1, pctcpu=0.0
    user=0, sys=1, intr=0
ddb{1}> ps
   PID     TID   PPID    UID  S       FLAGS  WAIT          COMMAND
 77150  251624  52135  32767  3        0x90  nanoslp       syz-executor.4
 77150  354080  52135  32767  3   0x4000090  netcon2       syz-executor.4
 77150   36099  52135  32767  3   0x4000090  fsleep        syz-executor.4
 77150  111988  52135  32767  3   0x4000090  fsleep        syz-executor.4
 67744   27739  81197  32767  3        0x90  nanoslp       syz-executor.6
 67744  226256  81197  32767  3   0x4000090  fsleep        syz-executor.6
*67744  318481  81197  32767  7   0x4000010                syz-executor.6
 67744  229891  81197  32767  2   0x4000010                syz-executor.6
 67744  156721  81197  32767  2   0x4000010                syz-executor.6
 67744  340311  81197  32767  2   0x4000010                syz-executor.6
 67744  145878  81197  32767  7   0x4000010                syz-executor.6
 32746  301353  34414  32767  3        0x90  nanoslp       syz-executor.3
 32746  318190  34414  32767  3   0x4000090  fsleep        syz-executor.3
 32746   63017  34414  32767  3   0x4000090  netcon        syz-executor.3
 32746   59079  34414  32767  3   0x4000090  fsleep        syz-executor.3
 91227  169024      0      0  3     0x14200  bored         sosplice
 20393  246787  31248  32767  3        0x90  piperd        syz-executor.5
 61600  298340  46164  32767  3        0x90  piperd        syz-executor.7
 52135  126670  34200  32767  3        0x90  nanoslp       syz-executor.4
 81197  485120  99521  32767  3        0x90  nanoslp       syz-executor.6
 46164  219706  49208      0  3        0x82  wait          syz-executor.7
 34414  289064  79088  32767  3        0x90  nanoslp       syz-executor.3
 31248  318419  49208      0  3        0x82  wait          syz-executor.5
 99521  464125  49208      0  3        0x82  wait          syz-executor.6
 34200  350776  49208      0  3        0x82  wait          syz-executor.4
 39927  424935  91674  32767  3        0x90  piperd        syz-executor.2
 79088  285688  49208      0  3        0x82  wait          syz-executor.3
 91674   75427  49208      0  3        0x82  wait          syz-executor.2
 56055  156510  25330  32767  3        0x90  piperd        syz-executor.1
 25330   34305  49208      0  3        0x82  wait          syz-executor.1
 86027  347740  88670  32767  3        0x90  piperd        syz-executor.0
 88670  163746  49208      0  3        0x82  wait          syz-executor.0
 49208  432708  88715      0  3        0x82  thrsleep      syz-fuzzer
 49208  263866  88715      0  3   0x4000082  thrsleep      syz-fuzzer
 49208  519988  88715      0  3   0x4000082  thrsleep      syz-fuzzer
 49208  195931  88715      0  3   0x4000082  thrsleep      syz-fuzzer
 49208  419563  88715      0  3   0x4000082  thrsleep      syz-fuzzer
 49208  348019  88715      0  3   0x4000082  thrsleep      syz-fuzzer
 49208  356436  88715      0  3   0x4000082  kqread        syz-fuzzer
 49208  350009  88715      0  3   0x4000082  thrsleep      syz-fuzzer
 49208  151753  88715      0  3   0x4000082  thrsleep      syz-fuzzer
 88715  406851  57555      0  3    0x10008a  sigsusp       ksh
 57555  365154  55777      0  3        0x9a  kqread        sshd
 20145  351324      1      0  3    0x100083  ttyin         getty
 55777  204928      1      0  3        0x88  kqread        sshd
 36379  141916  79529     73  3   0x1100090  kqread        syslogd
 79529  147105      1      0  3    0x100082  netio         syslogd
 91740  148106      1      0  3    0x100080  kqread        resolvd
 32521  138398  71122     77  3    0x100092  kqread        dhcpleased
  1041  269724  71122     77  3    0x100092  kqread        dhcpleased
 71122  145881      1      0  3        0x80  kqread        dhcpleased
 24271  355231      0      0  3     0x14200  bored         smr
 78222  262134      0      0  2     0x14200                zerothread
 78147   69709      0      0  3     0x14200  aiodoned      aiodoned
 60615   23865      0      0  3     0x14200  syncer        update
 36773  145163      0      0  3     0x14200  cleaner       cleaner
 37335  295202      0      0  3     0x14200  reaper        reaper
 16912   51370      0      0  3     0x14200  pgdaemon      pagedaemon
 45148  392762      0      0  3     0x14200  bored         viomb
 87912  175213      0      0  3  0x40014200  acpi0         acpi0
 32745  245051      0      0  3  0x40014200                idle1
 94780  357121      0      0  3     0x14200  bored         softnet
 36978  195657      0      0  3     0x14200  bored         systqmp
 64256  511179      0      0  3     0x14200  bored         systq
 79119   34673      0      0  3  0x40014200  bored         softclock
 66637  168674      0      0  3  0x40014200                idle0
     1  121421      0      0  3        0x82  wait          init
     0       0     -1      0  3     0x10200  scheduler     swapper
ddb{1}> show all locks
Process 67744 (syz-executor.6) thread 0xffff8000fffefa48 (318481)
exclusive kernel_lock &kernel_lock r = 0 (0xffffffff82ad20f0)
#0  witness_lock+0x44d
#1  __mp_acquire_count+0x48 sys/kern/kern_lock.c:227
#2  mi_switch+0x3d3 sys/kern/sched_bsd.c:416
#3  sleep_finish+0x198 sys/kern/kern_synch.c:433
#4  rw_enter+0x35a sys/kern/kern_rwlock.c:286
#5  uvmfault_lookup+0xd9 sys/uvm/uvm_fault.c:1758
#6  uvm_fault_check+0x3a sys/uvm/uvm_fault.c:674
#7  uvm_fault+0x102 sys/uvm/uvm_fault.c:602
#8  kpageflttrap+0x209
#9  kerntrap+0xef sys/arch/amd64/amd64/trap.c:318
#10 alltraps_kern_meltdown+0x7b
#11 copyout+0x53
#12 syscall+0x489 mi_syscall sys/sys/syscall_mi.h:102 [inline]
#12 syscall+0x489 sys/arch/amd64/amd64/trap.c:585
#13 Xsyscall+0x128
ddb{1}> show malloc
           Type InUse  MemUse  HighUse   Limit  Requests Type Lim
         devbuf 10174   6407K    6419K  78643K     11264        0
            pcb    13     10K      12K  78643K        15        0
         rtable   246      7K       7K  78643K       432        0
         ifaddr    81     16K      16K  78643K        82        0
       counters    56     35K      35K  78643K        56        0
       ioctlops     0      0K       2K  78643K       107        0
            iov     0      0K      16K  78643K       184        0
          mount     1      1K       1K  78643K         1        0
            log     0      0K       0K  78643K         5        0
         vnodes  1270     79K      79K  78643K      1308        0
      UFS quota     1     32K      32K  78643K         1        0
      UFS mount     5     36K      36K  78643K         5        0
            shm     2      1K       5K  78643K        11        0
         VM map     2      1K       1K  78643K         2        0
            sem    12      0K       0K  78643K       191        0
        dirhash    12      2K       2K  78643K        12        0
           ACPI  1697    195K     286K  78643K     12548        0
      file desc    21     77K     117K  78643K       891        0
          sigio     0      0K       0K  78643K        10        0
           proc    56     74K     111K  78643K       499        0
        subproc   104      6K       6K  78643K       104        0
    NFS srvsock     1      0K       0K  78643K         1        0
     NFS daemon     1     16K      16K  78643K         1        0
    ip_moptions     0      0K       0K  78643K        52        0
       in_multi    99      6K       6K  78643K       126        0
    ether_multi     1      0K       0K  78643K        10        0
            mrt     1      0K       0K  78643K         1        0
    ISOFS mount     1     32K      32K  78643K         1        0
  MSDOSFS mount     1     16K      16K  78643K         1        0
           ttys    61    281K     281K  78643K        61        0
           exec     0      0K       2K  78643K       697        0
            tdb     3      0K       0K  78643K         3        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   299     82K      91K  78643K     12923        0
       UVM aobj    25      2K       2K  78643K        28        0
        memdesc     1      4K       4K  78643K         1        0
    crypto data     1      1K       1K  78643K         1        0
    ip6_options     0      0K       0K  78643K        26        0
            NDP    11      0K       2K  78643K        27        0
           temp   121   4702K    4765K  78643K      5881        0
         kqueue    12     18K      26K  78643K        98        0
      SYN cache     2     16K      16K  78643K         2        0
ddb{1}> show all pools
Name      Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle
plcache    128       22    0        0     1     0     1     1     0     8    0
rtpcb      120       48    0       45     1     0     1     1     0     8    0
rtentry    112      115    0        1     4     0     4     4     0     8    0
unpcb      136      528    0      515     5     4     1     5     0     8    0
syncache   296       15    0       15     3     2     1     1     0     8    1
tcpqe       32        1    0        1     1     0     1     1     0     8    1
tcpcb      736      308    0      293    10     6     4     8     0     8    2
arp        120       18    0        0     1     0     1     1     0     8    0
ipq         40        5    0        4     2     1     1     1     0     8    0
ipqe        40      180    0      179     2     1     1     1     0     8    0
inpcb      304     1418    0     1405    22    10    12    12     0     8   10
ip6q        72        2    0        2     1     1     0     1     0     8    0
ip6af       40        4    0        4     1     1     0     1     0     8    0
nd6         48       28    0        0     1     0     1     1     0     8    0
kcovpl      48        8    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      492    0        0    31     0    31    31     0     8    0
art_table   32      493    0        0     4     0     4     4     0     8    0
art_node    16      114    0       10     1     0     1     1     0     8    0
sysvmsgpl   40       27    0       17     1     0     1     1     0     8    0
semupl     112        1    0        1     1     1     0     1     0     8    0
semapl     112      188    0      178     1     0     1     1     0     8    0
shmpl      112       25    0        3     1     0     1     1     0     8    0
dirhash    1024      17    0        0     3     0     3     3     0     8    0
dino2pl    256     2368    0      938    90     0    90    90     0     8    0
ffsino     272     2368    0      938    96     0    96    96     0     8    0
nchpl      144     3770    0     2111    62     0    62    62     0     8    0
uvmvnodes   80     2481    0        0    51     0    51    51     0     8    0
vnodes     224     2481    0        0   146     0   146   146     0     8    0
namei      1024   11759    0    11759     2     1     1     2     0     8    1
percpumem   16       40    0        0     1     0     1     1     0     8    0
scxspl     216    10901    0    10901     9     8     1     8     0     8    1
plimitpl   152       92    0       70     1     0     1     1     0     8    0
sigapl     424     1167    0     1120     7     1     6     7     0     8    0
futexpl     64     7803    0     7798     1     0     1     1     0     8    0
knotepl    120      210    0        0     6     0     6     6     0     8    0
kqueuepl   216      123    0      115     1     0     1     1     0     8    0
pipepl     336      284    0      256     6     0     6     6     0     8    3
fdescpl    496     1152    0     1120     7     2     5     6     0     8    0
filepl     152     6627    0     6386    19     4    15    15     0     8    5
lockfpl    104       87    0       85     1     0     1     1     0     8    0
lockfspl    48       40    0       38     1     0     1     1     0     8    0
sessionpl  144       23    0        7     1     0     1     1     0     8    0
pgrppl      48      113    0       96     1     0     1     1     0     8    0
ucredpl     96      550    0      532     1     0     1     1     0     8    0
zombiepl   144     1120    0     1120     1     0     1     1     0     8    1
processpl  1064    1167    0     1120     5     1     4     4     0     8    0
procpl     672     2827    0     2760     8     1     7     8     0     8    0
sosppl     168        8    0        8     2     1     1     1     0     8    1
sockpl     480     2002    0     1973    54    33    21    21     0     8   16
mcl64k     65536     15    0        0     2     0     2     2     0     8    0
mcl16k     16384      6    0        0     1     0     1     1     0     8    0
mcl12k     12288      7    0        0     1     0     1     1     0     8    0
mcl9k      9216       8    0        0     1     0     1     1     0     8    0
mcl8k      8192       8    0        0     1     0     1     1     0     8    0
mcl4k      4096      17    0        0     3     0     3     3     0     8    1
mcl2k2     2112       5    0        0     1     0     1     1     0     8    0
mcl2k      2048     146    0        0    18     0    18    18     0     8    0
mtagpl      96        2    0        0     1     0     1     1     0     8    0
mbufpl     256      419    0        0    26     0    26    26     0     8    0
bufpl      288     4804    0      141   334     0   334   334     0     8    0
anonpl      24   278763    0   265115   106     6   100   100     0   186    9
amapchunkpl 152   30599    0    29870    40     3    37    37     0   158    4
amappl16   200     2139    0     1771    21     1    20    20     0     8    0
amappl15   192       86    0       82     1     0     1     1     0     8    0
amappl14   184      122    0      114     1     0     1     1     0     8    0
amappl13   176       80    0       78     1     0     1     1     0     8    0
amappl12   168      319    0      312     1     0     1     1     0     8    0
amappl11   160       48    0       36     1     0     1     1     0     8    0
amappl10   152      121    0      116     1     0     1     1     0     8    0
amappl9    144      469    0      464     1     0     1     1     0     8    0
amappl8    136      876    0      813     3     0     3     3     0     8    0
amappl7    128      409    0      391     1     0     1     1     0     8    0
amappl6    120      193    0      173     2     1     1     2     0     8    0
amappl5    112     1008    0      986     1     0     1     1     0     8    0
amappl4    104      794    0      768     1     0     1     1     0     8    0
amappl3     96      530    0      513     1     0     1     1     0     8    0
amappl2     88      642    0      597     3     1     2     3     0     8    0
amappl1     80    23783    0    23187    18     3    15    18     0     8    0
amappl      88    12465    0    12236     7     0     7     7     0    92    0
dma4096    4096       1    0        1     1     1     0     1     0     8    0
dma1024    1024       1    0        0     1     0     1     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      72       27    0        3     1     0     1     1     0     8    0
uaddrrnd    24     1152    0     1120     1     0     1     1     0     8    0
uaddrbest   32        2    0        0     1     0     1     1     0     8    0
uaddr       24     1152    0     1120     1     0     1     1     0     8    0
vmmpekpl   168    13912    0    13866     3     0     3     3     0     8    0
vmmpepl    168   107791    0   105389   124     1   123   123     0   357    4
vmsppl     368     1151    0     1120     4     0     4     4     0     8    0
rwobjpl     56    29275    0    25478    55     0    55    55     0     8    0
pdppl      4096    2311    0     2240   115    34    81    91     0     8   10
pvpl        32   586018    0   567499   242    27   215   242     0   265   52
pmappl     248     1151    0     1120     4     1     3     3     0     8    0
extentpl    40       58    0       38     1     0     1     1     0     8    0
phpool     112      746    0       43    21     0    21    21     0     8    0
ddb{1}> machine ddbcpu 0
Stopped at      x86_ipi_db+0x1a:        addq    $0x8,%rsp
ddb{0}> trace
x86_ipi_db(ffffffff828f4ff0) at x86_ipi_db+0x1a sys/arch/amd64/amd64/db_interface.c:393
x86_ipi_handler() at x86_ipi_handler+0xb7 sys/arch/amd64/amd64/ipi.c:106
Xresume_lapic_ipi() at Xresume_lapic_ipi+0x23
__mp_lock(ffffffff82ad1ee8) at __mp_lock+0x122 __mp_lock_spin sys/kern/kern_lock.c:116 [inline]
__mp_lock(ffffffff82ad1ee8) at __mp_lock+0x122 sys/kern/kern_lock.c:147
syscall(ffff80002e38abd0) at syscall+0x3ef mi_syscall sys/sys/syscall_mi.h:93 [inline]
syscall(ffff80002e38abd0) at syscall+0x3ef sys/arch/amd64/amd64/trap.c:585
Xsyscall() at Xsyscall+0x128
end of kernel
end trace frame: 0xa7a301c380, count: -6
ddb{0}> machine ddbcpu 1
Stopped at      sys_msgrcv+0x2df:       movq    0x10(%r13),%rdi
ddb{1}> trace
sys_msgrcv(ffff8000fffefa48,ffff80002af38448,ffff80002af384a0) at sys_msgrcv+0x2df msg_copyout sys/kern/sysv_msg.c:649 [inline]
sys_msgrcv(ffff8000fffefa48,ffff80002af38448,ffff80002af384a0) at sys_msgrcv+0x2df sys/kern/sysv_msg.c:359
syscall(ffff80002af38510) at syscall+0x489 mi_syscall sys/sys/syscall_mi.h:102 [inline]
syscall(ffff80002af38510) at syscall+0x489 sys/arch/amd64/amd64/trap.c:585
Xsyscall() at Xsyscall+0x128
end of kernel
end trace frame: 0xa8290d8120, count: -3

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/02/18 20:13 openbsd d69fd9e71db5 3cd800e4 .config console log report ci-openbsd-setuid protection_fault: sys_msgrcv
* Struck through repros no longer work on HEAD.