syzbot


panic: header.ScopeForIPv6Address(172.20.20.170): bad address

Status: fixed on 2020/12/30 01:06
Fix commit: b15acae9a6e2 Fix error code for connect in raw sockets.
First crash: 1455d, last: 1448d

Sample crash report:
panic: header.ScopeForIPv6Address(172.20.20.170): bad address

goroutine 1086 [running]:
panic(0xfc2f40, 0xc0002bc060)
	GOROOT/src/runtime/panic.go:1064 +0x470 fp=0xc000b0af30 sp=0xc000b0ae78 pc=0x437030
gvisor.dev/gvisor/pkg/tcpip/network/ipv6.(*endpoint).acquireOutgoingPrimaryAddressRLocked(0xc000159180, 0xc000601db4, 0x4, 0xc000b0b000, 0x40b80a, 0x106c3a0)
	pkg/tcpip/network/ipv6/ipv6.go:1339 +0x387 fp=0xc000b0b028 sp=0xc000b0af30 pc=0xb052e7
gvisor.dev/gvisor/pkg/tcpip/network/ipv6.(*endpoint).AcquireOutgoingPrimaryAddress(0xc000159180, 0xc000601db4, 0x4, 0x3f657be6d800, 0x0, 0x0)
	pkg/tcpip/network/ipv6/ipv6.go:1293 +0x8b fp=0xc000b0b080 sp=0xc000b0b028 pc=0xb04eeb
gvisor.dev/gvisor/pkg/tcpip/stack.(*NIC).primaryEndpoint(0xc0001960c0, 0x86dd, 0xc000601db4, 0x4, 0xc0001c4000, 0x3f657be80658)
	pkg/tcpip/stack/nic.go:340 +0x116 fp=0xc000b0b0d8 sp=0xc000b0b080 pc=0x929556
gvisor.dev/gvisor/pkg/tcpip/stack.(*Stack).getAddressEP(0xc000459600, 0xc0001960c0, 0x0, 0x0, 0xc000601db4, 0x4, 0x86dd, 0x0, 0x0)
	pkg/tcpip/stack/stack.go:1212 +0x58 fp=0xc000b0b128 sp=0xc000b0b0d8 pc=0x935098
gvisor.dev/gvisor/pkg/tcpip/stack.(*Stack).FindRoute(0xc000459600, 0x0, 0x0, 0x0, 0xc000601db4, 0x4, 0x86dd, 0x0, 0x0)
	pkg/tcpip/stack/stack.go:1362 +0xd32 fp=0xc000b0b3d0 sp=0xc000b0b128 pc=0x9363d2
gvisor.dev/gvisor/pkg/tcpip/transport/raw.(*endpoint).write(0xc0001596c0, 0x12ec280, 0xc00011bd10, 0xc000495be0, 0x0, 0x105c500, 0xc000159601, 0xc00011bd10)
	pkg/tcpip/transport/raw/endpoint.go:336 +0x14b fp=0xc000b0b4d8 sp=0xc000b0b3d0 pc=0xaa554b
gvisor.dev/gvisor/pkg/tcpip/transport/raw.(*endpoint).Write(0xc0001596c0, 0x12ec280, 0xc00011bd10, 0xc000495be0, 0xc000000000, 0x4, 0x0, 0x2)
	pkg/tcpip/transport/raw/endpoint.go:230 +0x72 fp=0xc000b0b528 sp=0xc000b0b4d8 pc=0xaa5272
gvisor.dev/gvisor/pkg/sentry/socket/netstack.(*socketOpsCommon).SendMsg(0xc000b013f0, 0xc000461500, 0x1307140, 0xc000716000, 0x0, 0x0, 0x0, 0x0, 0x100, 0xc000768100, ...)
	pkg/sentry/socket/netstack/netstack.go:2848 +0x19d fp=0xc000b0b818 sp=0xc000b0b528 pc=0xb23cbd
gvisor.dev/gvisor/pkg/sentry/syscalls/linux/vfs2.sendSingleMsg(0xc000461500, 0x3f657be804c0, 0xc000b01380, 0xc000b01380, 0x20000480, 0xc000000000, 0xfff, 0x10001ff0000, 0xb0ba78)
	pkg/sentry/syscalls/linux/vfs2/socket.go:1056 +0x3c2 fp=0xc000b0ba58 sp=0xc000b0b818 pc=0xd983c2
gvisor.dev/gvisor/pkg/sentry/syscalls/linux/vfs2.SendMsg(0xc000461500, 0x3, 0x20000480, 0x0, 0x4, 0x1, 0x1, 0x0, 0x0, 0x0, ...)
	pkg/sentry/syscalls/linux/vfs2/socket.go:934 +0x225 fp=0xc000b0baf8 sp=0xc000b0ba58 pc=0xd977c5
gvisor.dev/gvisor/pkg/sentry/kernel.(*Task).executeSyscall(0xc000461500, 0x2e, 0x3, 0x20000480, 0x0, 0x4, 0x1, 0x1, 0xdd1257, 0x1196a00, ...)
	pkg/sentry/kernel/task_syscall.go:104 +0x13c fp=0xc000b0bc58 sp=0xc000b0baf8 pc=0x9cc13c
gvisor.dev/gvisor/pkg/sentry/kernel.(*Task).doSyscallInvoke(0xc000461500, 0x2e, 0x3, 0x20000480, 0x0, 0x4, 0x1, 0x1, 0x1, 0x1)
	pkg/sentry/kernel/task_syscall.go:239 +0x66 fp=0xc000b0bce0 sp=0xc000b0bc58 pc=0x9cd306
gvisor.dev/gvisor/pkg/sentry/kernel.(*Task).doSyscallEnter(0xc000461500, 0x2e, 0x3, 0x20000480, 0x0, 0x4, 0x1, 0x1, 0x0, 0x0)
	pkg/sentry/kernel/task_syscall.go:199 +0x98 fp=0xc000b0bd40 sp=0xc000b0bce0 pc=0x9cceb8
gvisor.dev/gvisor/pkg/sentry/kernel.(*Task).doSyscall(0xc000461500, 0x2, 0xc000461500)
	pkg/sentry/kernel/task_syscall.go:174 +0x15c fp=0xc000b0be10 sp=0xc000b0bd40 pc=0x9cc85c
gvisor.dev/gvisor/pkg/sentry/kernel.(*runApp).execute(0x0, 0xc000461500, 0x12de600, 0x0)
	pkg/sentry/kernel/task_run.go:282 +0xc45 fp=0xc000b0bf60 sp=0xc000b0be10 pc=0x9c0ca5
gvisor.dev/gvisor/pkg/sentry/kernel.(*Task).run(0xc000461500, 0x17)
	pkg/sentry/kernel/task_run.go:97 +0x1af fp=0xc000b0bfd0 sp=0xc000b0bf60 pc=0x9bf96f
runtime.goexit()
	src/runtime/asm_amd64.s:1374 +0x1 fp=0xc000b0bfd8 sp=0xc000b0bfd0 pc=0x4705a1
created by gvisor.dev/gvisor/pkg/sentry/kernel.(*Task).Start
	pkg/sentry/kernel/task_start.go:323 +0xfe

Crashes (48):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2020/12/03 17:08 gvisor 80552b936d06 e6b0d314 .config console log report syz C ci-gvisor-kvm
2020/12/03 16:46 gvisor 80552b936d06 e6b0d314 .config console log report syz C ci-gvisor-kvm
2020/12/03 13:59 gvisor 80552b936d06 e6b0d314 .config console log report syz C ci-gvisor-kvm
2020/12/03 13:38 gvisor 80552b936d06 e6b0d314 .config console log report syz C ci-gvisor-kvm
2020/12/02 23:13 gvisor 7ccb0b6a7cd7 8c9190ef .config console log report syz C ci-gvisor-ptrace-2-cover
2020/12/02 23:03 gvisor 7ccb0b6a7cd7 8c9190ef .config console log report syz C ci-gvisor-ptrace-2-cover
2020/12/02 22:37 gvisor 7ccb0b6a7cd7 8c9190ef .config console log report syz C ci-gvisor-ptrace-2-cover
2020/12/02 22:27 gvisor 7ccb0b6a7cd7 8c9190ef .config console log report syz C ci-gvisor-ptrace-2-cover
2020/12/02 20:37 gvisor 7ccb0b6a7cd7 8c9190ef .config console log report syz C ci-gvisor-ptrace-1
2020/12/02 20:36 gvisor 7ccb0b6a7cd7 8c9190ef .config console log report syz C ci-gvisor-ptrace-2-race
2020/12/02 18:51 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-1-race
2020/12/02 18:40 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-1-race
2020/12/02 18:04 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-2
2020/12/02 17:44 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-1
2020/12/02 17:34 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-1
2020/12/02 17:34 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-2-race
2020/12/02 17:24 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-2-race
2020/12/02 16:23 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-1
2020/12/02 16:22 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-1-race
2020/12/02 16:15 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-2-race
2020/12/02 15:37 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-2
2020/12/02 15:16 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-1-race
2020/12/02 14:24 gvisor 41675ebc6308 c42a35e9 .config console log report syz C ci-gvisor-ptrace-2
2020/12/08 18:58 gvisor 9c198e5df421 9af51e31 .config console log report info ci-gvisor-ptrace-2-race
2020/12/08 17:44 gvisor 9c198e5df421 9af51e31 .config console log report info ci-gvisor-ptrace-2-race
2020/12/08 16:01 gvisor 9c198e5df421 9af51e31 .config console log report info ci-gvisor-ptrace-2-race
2020/12/08 15:00 gvisor 9c198e5df421 9af51e31 .config console log report info ci-gvisor-ptrace-2
2020/12/08 13:38 gvisor 9c198e5df421 9af51e31 .config console log report info ci-gvisor-ptrace-2
2020/12/08 11:54 gvisor 9c198e5df421 9af51e31 .config console log report info ci-gvisor-ptrace-1
2020/12/08 10:30 gvisor 9c198e5df421 9af51e31 .config console log report info ci-gvisor-ptrace-1
2020/12/08 06:49 gvisor eeb23531ebef 51a9082e .config console log report info ci-gvisor-ptrace-2-race
2020/12/08 06:01 gvisor eeb23531ebef 51a9082e .config console log report info ci-gvisor-ptrace-2
2020/12/08 04:34 gvisor eeb23531ebef 51a9082e .config console log report info ci-gvisor-ptrace-1
2020/12/08 00:11 gvisor eeb23531ebef 51a9082e .config console log report info ci-gvisor-ptrace-1
2020/12/07 20:48 gvisor eeb23531ebef 51a9082e .config console log report info ci-gvisor-ptrace-2
2020/12/07 18:11 gvisor eeb23531ebef 57072f7b .config console log report info ci-gvisor-ptrace-1
2020/12/07 16:14 gvisor a97ceec01bc4 57072f7b .config console log report info ci-gvisor-ptrace-2-race
2020/12/07 13:22 gvisor a97ceec01bc4 57072f7b .config console log report info ci-gvisor-ptrace-1
2020/12/06 23:53 gvisor a97ceec01bc4 c521566d .config console log report info ci-gvisor-ptrace-2-race
2020/12/05 04:49 gvisor 7a1de8583d7c 20366b87 .config console log report info ci-gvisor-ptrace-2
2020/12/04 19:27 gvisor a78cef0ed7ce 20366b87 .config console log report info ci-gvisor-ptrace-2-race
2020/12/02 14:23 gvisor 41675ebc6308 c42a35e9 .config console log report info ci-gvisor-ptrace-2-cover
2020/12/02 14:20 gvisor 41675ebc6308 eff43e99 .config console log report info ci-gvisor-kvm
2020/12/02 14:19 gvisor 41675ebc6308 c42a35e9 .config console log report info ci-gvisor-ptrace-1-race
2020/12/02 14:17 gvisor 41675ebc6308 c42a35e9 .config console log report info ci-gvisor-ptrace-2-race
2020/12/02 14:17 gvisor 41675ebc6308 c42a35e9 .config console log report info ci-gvisor-ptrace-2
2020/12/02 14:17 gvisor 41675ebc6308 c42a35e9 .config console log report info ci-gvisor-ptrace-1
* Struck through repros no longer work on HEAD.