Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

net: dns crashes on bad responses #1350

Closed
rsc opened this issue Dec 15, 2010 · 2 comments

Comments

Projects
None yet
3 participants
@rsc
Copy link
Contributor

commented Dec 15, 2010

make[2]: Entering directory `/home/fst/go/src/pkg/net'
6g -o _gotest_.6 dial.go dnsmsg.go fd_linux.go hosts.go ip.go
ipsock.go iprawsock.go net.go parse.go pipe.go sock.go tcpsock.go
udpsock.go unixsock.go newpollserver.go fd.go dnsconfig.go
dnsclient.go port.go dialgoogle_test.go dnsname_test.go hosts_test.go
ip_test.go ipraw_test.go net_test.go parse_test.go pipe_test.go
port_test.go server_test.go srv_test.go timeout_test.go
rm -f _test/net.a
gopack grc _test/net.a _gotest_.6
make[2]: Leaving directory `/home/fst/go/src/pkg/net'
panic: interface conversion: net.dnsRR is *net.dnsRR_Header, not *net.dnsRR_SRV

panic PC=0x2b827996f268
runtime.panic+0xb2 /home/fst/go/src/pkg/runtime/proc.c:1028
runtime.panic(0x4996bc, 0x2b8279a2aa80)
runtime.assertI2T+0x104 /home/fst/go/src/pkg/runtime/iface.c:233
runtime.assertI2T(0x49837c, 0x2b8279a5f690, 0x2b8279a613c0, 0x2b8279a5f9c0)
net.LookupSRV+0x267 /home/fst/go/src/pkg/net/dnsclient.go:342
net.LookupSRV(0x4721fc, 0xb, 0x46f66c, 0x3, 0x471ba8, ...)
net.TestGoogleSRV+0x56 /home/fst/go/src/pkg/net/srv_test.go:15
net.TestGoogleSRV(0x2b8279a5e2c0, 0x2b8279a5e600)
testing.tRunner+0x2b /home/fst/go/src/pkg/testing/testing.go:132
testing.tRunner(0x2b8279a5e2c0, 0x2b82799a0690, 0x0, 0x0)
runtime.goexit /home/fst/go/src/pkg/runtime/proc.c:146
runtime.goexit()

goroutine 4 [4]:
runtime.gosched+0x77 /home/fst/go/src/pkg/runtime/proc.c:548
runtime.gosched()
runfinq+0x50 /home/fst/go/src/pkg/runtime/mgc0.c:429
runfinq()
runtime.goexit /home/fst/go/src/pkg/runtime/proc.c:146
runtime.goexit()

goroutine 3 [3]:
runtime.entersyscall+0x28 /home/fst/go/src/pkg/runtime/proc.c:567
runtime.entersyscall()
syscall.Syscall6+0x5 /home/fst/go/src/pkg/syscall/asm_linux_amd64.s:40
syscall.Syscall6()
syscall.EpollWait+0x8d /home/fst/go/src/pkg/syscall/zsyscall_linux_amd64.go:188
syscall.EpollWait(0x2b8200000006, 0x2b8279a599d0, 0x100000001,
0x1387, 0x10, ...)
net.*pollster·WaitFD+0xfe /home/fst/go/src/pkg/net/fd_linux.go:116
net.*pollster·WaitFD(0x2b82799b8230, 0x129f5c948, 0x2b8200000072,
0x0, 0x0, ...)
net.*pollServer·Run+0xa3 /home/fst/go/src/pkg/net/fd.go:207
net.*pollServer·Run(0x2b82799a1680, 0x0)
runtime.goexit /home/fst/go/src/pkg/runtime/proc.c:146
runtime.goexit()

goroutine 1 [4]:
runtime.gosched+0x77 /home/fst/go/src/pkg/runtime/proc.c:548
runtime.gosched()
runtime.chanrecv+0x41e /home/fst/go/src/pkg/runtime/chan.c:336
runtime.chanrecv(0x2b8279f4f6c0, 0x2b827996b038, 0x0, 0x10, 0x499d14, ...)
runtime.chanrecv1+0x41 /home/fst/go/src/pkg/runtime/chan.c:444
runtime.chanrecv1(0x2b8279f4f6c0, 0x2b82799a0690)
testing.Main+0x251 /home/fst/go/src/pkg/testing/testing.go:159
testing.Main(0x43a58b, 0x2b82799a0540, 0x1100000011, 0x401943)
main.main+0x49 /home/fst/go/src/pkg/net/_testmain.go:30
main.main()
runtime.mainstart+0xf /home/fst/go/src/pkg/runtime/amd64/asm.s:77
runtime.mainstart()
runtime.goexit /home/fst/go/src/pkg/runtime/proc.c:146
runtime.goexit()
make[1]: *** [test] Error 2
make[1]: Leaving directory `/home/fst/go/src/pkg/net'
make: *** [net.test] Error 2
@bradfitz

This comment has been minimized.

Copy link
Member

commented May 3, 2011

Comment 1:

Pending CL:
http://golang.org/cl/4432089/

Owner changed to @bradfitz.

@bradfitz

This comment has been minimized.

Copy link
Member

commented May 3, 2011

Comment 2:

This issue was closed by revision 8ef56f7.

Status changed to Fixed.

@rsc rsc added fixed labels May 3, 2011

@golang golang locked and limited conversation to collaborators Jun 24, 2016

This issue was closed.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.