Skip to content

Commit

Permalink
Remove check for ICEControlling for TCP ICE
Browse files Browse the repository at this point in the history
Closes #249
  • Loading branch information
jeremija authored and Sean-Der committed Jul 19, 2020
1 parent d40d5bf commit 1f59642
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 12 deletions.
1 change: 0 additions & 1 deletion tcp_ip_mux_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ func TestTCP_Recv(t *testing.T) {
msg := stun.New()
msg.Type = stun.MessageType{Method: stun.MethodBinding, Class: stun.ClassRequest}
msg.Add(stun.AttrUsername, []byte("myufrag:otherufrag"))
msg.Add(stun.AttrICEControlling, nil)
msg.Encode()

n, err := writeStreamingPacket(conn, msg.Raw)
Expand Down
11 changes: 0 additions & 11 deletions tcp_mux.go
Original file line number Diff line number Diff line change
Expand Up @@ -144,17 +144,6 @@ func (m *tcpMux) handleConn(conn net.Conn) {
m.params.Logger.Debugf("msg attr: %s\n", attr.String())
}

// Firefox will send ICEControlling for its Active canddiate. We
// currently support passive local TCP candidates only.
//
// TODO: not sure what will be sent for caniddate with tcptype S-O.
_, err = msg.Get(stun.AttrICEControlling)
if err != nil {
m.closeAndLogError(conn)
m.params.Logger.Warnf("No ICEControlling attribute in STUN message from %s to %s\n", conn.RemoteAddr(), conn.LocalAddr())
return
}

attr, err := msg.Get(stun.AttrUsername)
if err != nil {
m.closeAndLogError(conn)
Expand Down

0 comments on commit 1f59642

Please sign in to comment.