syzbot


DATA RACE in unix.(*queueReceiver).RecvQueuedSize

Status: fixed on 2018/06/27 08:03
Fix commit: 5f7f78c1d7ee Fix data races in Unix sockets
First crash: 2347d, last: 2344d

Sample crash report:
WARNING: DATA RACE
Read at 0x00c4204a45c0 by goroutine 128:
  gvisor.googlesource.com/gvisor/pkg/tcpip/transport/unix.(*queueReceiver).RecvQueuedSize()
      pkg/tcpip/transport/queue/queue.go:160 +0x52
  gvisor.googlesource.com/gvisor/pkg/tcpip/transport/unix.(*baseEndpoint).GetSockOpt()
      pkg/tcpip/transport/unix/unix.go:808 +0x6b6
  gvisor.googlesource.com/gvisor/pkg/tcpip/transport/unix.(*connectionedEndpoint).GetSockOpt()
      <autogenerated>:1 +0x57
  gvisor.googlesource.com/gvisor/pkg/sentry/socket/epsocket.Ioctl()
      pkg/sentry/socket/epsocket/epsocket.go:1100 +0x3e1
  gvisor.googlesource.com/gvisor/pkg/sentry/socket/unix.(*SocketOperations).Ioctl()
      pkg/sentry/socket/unix/unix.go:136 +0xea
  gvisor.googlesource.com/gvisor/pkg/sentry/syscalls/linux.Ioctl()
      pkg/sentry/syscalls/linux/sys_file.go:560 +0x1e4
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).executeSyscall()
      pkg/sentry/kernel/task_syscall.go:162 +0x14e
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).doSyscallInvoke()
      pkg/sentry/kernel/task_syscall.go:278 +0x7d
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).doSyscallEnter()
      pkg/sentry/kernel/task_syscall.go:241 +0xc3
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).doSyscall()
      pkg/sentry/kernel/task_syscall.go:216 +0x19c
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*runApp).execute()
      pkg/sentry/kernel/task_run.go:217 +0x157c
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).run()
      pkg/sentry/kernel/task_run.go:95 +0x264

Previous write at 0x00c4204a45c0 by goroutine 126:
  gvisor.googlesource.com/gvisor/pkg/tcpip/transport/queue.(*Queue).Enqueue()
      pkg/tcpip/transport/queue/queue.go:103 +0x164
  gvisor.googlesource.com/gvisor/pkg/tcpip/transport/unix.(*connectedEndpoint).Send()
      pkg/tcpip/transport/unix/unix.go:611 +0x402
  gvisor.googlesource.com/gvisor/pkg/tcpip/transport/unix.(*baseEndpoint).SendMsg()
      pkg/tcpip/transport/unix/unix.go:761 +0x183
  gvisor.googlesource.com/gvisor/pkg/tcpip/transport/unix.(*connectionedEndpoint).SendMsg()
      pkg/tcpip/transport/unix/connectioned.go:405 +0xe6
  gvisor.googlesource.com/gvisor/pkg/sentry/socket/unix.(*SocketOperations).Write()
      pkg/sentry/socket/unix/unix.go:349 +0x3da
  gvisor.googlesource.com/gvisor/pkg/sentry/fs.(*File).Writev()
      pkg/sentry/fs/file.go:271 +0x1ba
  gvisor.googlesource.com/gvisor/pkg/sentry/syscalls/linux.writev()
      pkg/sentry/syscalls/linux/sys_write.go:191 +0xa1
  gvisor.googlesource.com/gvisor/pkg/sentry/syscalls/linux.Write()
      pkg/sentry/syscalls/linux/sys_write.go:67 +0x295
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).executeSyscall()
      pkg/sentry/kernel/task_syscall.go:162 +0x14e
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).doSyscallInvoke()
      pkg/sentry/kernel/task_syscall.go:278 +0x7d
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).doSyscallEnter()
      pkg/sentry/kernel/task_syscall.go:241 +0xc3
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).doSyscall()
      pkg/sentry/kernel/task_syscall.go:216 +0x19c
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*runApp).execute()
      pkg/sentry/kernel/task_run.go:217 +0x157c
  gvisor.googlesource.com/gvisor/pkg/sentry/kernel.(*Task).run()
      pkg/sentry/kernel/task_run.go:95 +0x264

Crashes (5):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2018/06/24 01:11 https://github.com/dvyukov/gvisor.git race 60dbbdc2d54b 2064fc5c .config console log report syz C ci-gvisor-ptrace-proxy-sandbox-race
2018/06/27 01:29 https://github.com/dvyukov/gvisor.git race fb36f579ec12 b0294c53 .config console log report ci-gvisor-ptrace-proxy-sandbox-race
2018/06/26 20:26 https://github.com/dvyukov/gvisor.git race fb36f579ec12 089f1181 .config console log report ci-gvisor-ptrace-proxy-sandbox-race
2018/06/26 19:05 https://github.com/dvyukov/gvisor.git race fb36f579ec12 089f1181 .config console log report ci-gvisor-ptrace-proxy-sandbox-race
2018/06/25 10:52 https://github.com/dvyukov/gvisor.git race 60dbbdc2d54b 2064fc5c .config console log report ci-gvisor-ptrace-proxy-sandbox-race
* Struck through repros no longer work on HEAD.