Commit Graph

29 Commits

Author SHA1 Message Date
e58fe8ef0e Do not delete the turn port entry right away when the respective connection is deleted.
BUG=webrtc:5120

Review URL: https://codereview.webrtc.org/1426673007

Cr-Commit-Position: refs/heads/master@{#10641}
2015-11-14 01:54:47 +00:00
8597543ae8 Schedule a CreatePermissionRequest after the success of a previous request
unless a channel binding request is already scheduled.

BUG=5178
R=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1434603002 .

Cr-Commit-Position: refs/heads/master@{#10625}
2015-11-12 19:07:25 +00:00
04ac81f2fd Replace readable with receiving where receiving means receiving anything (stun ping, response or data packet).
BUG=4937
R=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1345913004 .

Cr-Commit-Position: refs/heads/master@{#10004}
2015-09-21 18:48:37 +00:00
275a2f16fd Revert of Replace readable with receiving where receiving means receiving anything (stun ping, response or da… (patchset #7 id:340001 of https://codereview.webrtc.org/1351673003/ )
Reason for revert:
Broke the Windows build:

[226/365] LINK_EMBED cc_perftests.exe
FAILED: ninja -t msvc -e environment.x86 -- E:\b\build\goma/gomacc "E:\b\depot_tools\win_toolchain\vs2013_files\VC\bin\amd64_x86\cl.exe" /nologo /showIncludes /FC @obj\remoting\protocol\remoting_unittests.channel_socket_adapter_unittest.obj.rsp /c ..\..\remoting\protocol\channel_socket_adapter_unittest.cc /Foobj\remoting\protocol\remoting_unittests.channel_socket_adapter_unittest.obj /Fdobj\remoting\remoting_unittests.cc.pdb
e:\b\build\slave\win\build\src\remoting\protocol\channel_socket_adapter_unittest.cc(36) : error C3861: 'set_readable': identifier not found
ninja: build stopped: subcommand failed.

Original issue's description:
> Replace readable with receiving where receiving means receiving anything (stun ping, response or data packet).
> If a connection does not receive for 30 seconds, it will be deleted.
> BUG=
>
> Committed: https://crrev.com/ae16f8547d3b447f62f6660f13688585c6c3de15
> Cr-Commit-Position: refs/heads/master@{#10001}

TBR=pthatcher@webrtc.org,honghaiz@webrtc.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

Review URL: https://codereview.webrtc.org/1356103002

Cr-Commit-Position: refs/heads/master@{#10002}
2015-09-21 14:20:43 +00:00
ae16f8547d Replace readable with receiving where receiving means receiving anything (stun ping, response or data packet).
If a connection does not receive for 30 seconds, it will be deleted.
BUG=

Review URL: https://codereview.webrtc.org/1351673003

Cr-Commit-Position: refs/heads/master@{#10001}
2015-09-21 13:54:19 +00:00
7cbd188c5e Remove GICE (again).
R=guoweis@webrtc.org

Review URL: https://codereview.webrtc.org/1353713002 .

Cr-Commit-Position: refs/heads/master@{#9979}
2015-09-18 01:55:03 +00:00
d12140a68e Revert change which removes GICE.
There are still dependencies on this functionality.

TBR=pthatcher@webrtc.org

BUG=526399

Review URL: https://codereview.webrtc.org/1336553003

Cr-Commit-Position: refs/heads/master@{#9920}
2015-09-10 20:32:21 +00:00
71cfe690b7 For TestResolverShutdown, use address that can't be resolved.
This test only currently works because stun.l.google.com has an IPv4
address and the TURN port is created with an IPv6 address. But the test
would start failing if/when it starts providing an IPv6 address. Which
may already be happening, as indicated by a recent test failure.

Review URL: https://codereview.webrtc.org/1290233003

Cr-Commit-Position: refs/heads/master@{#9841}
2015-09-02 02:01:40 +00:00
2159b89fa2 Reland "Remove GICE (gone forever!) and PORTALLOCATOR_ENABLE_SHARED_UFRAG (enabled forever)." becauese remoting code is using dead constants and breaks the FYI bots.
This reverts commit 5bdafd44c86ee46bd7e040f19828324583418b33.

Original CL: https://codereview.webrtc.org/1263663002/

R=guoweis@webrtc.org

Review URL: https://codereview.webrtc.org/1303393002 .

Cr-Commit-Position: refs/heads/master@{#9761}
2015-08-22 03:46:18 +00:00
ea1012b2a4 address comments from https://codereview.webrtc.org/1277263002/
TBR=juberti@webrtc.org,pthather@webrtc.org

Review URL: https://codereview.webrtc.org/1305113002

Cr-Commit-Position: refs/heads/master@{#9757}
2015-08-21 16:06:37 +00:00
5bdafd44c8 Revert "Reland "Remove GICE (gone forever!) and PORTALLOCATOR_ENABLE_SHARED_UFRAG (enabled forever)." becauese remoting code is using dead constants and breaks the FYI bots.""
This reverts commit 081f34b564e1a26ffbbe9515eba1fef7c736fdde.

Original code review see
https://codereview.webrtc.org/1291363005

The revert is due to a suspicion of "Reland "Remove GICE..." being the cause of failure on Linux memcheck, see
https://build.chromium.org/p/client.webrtc/builders/Linux%20Memcheck/builds/4137

TBR=pthatcher@webrtc.org,

BUG=

Review URL: https://codereview.webrtc.org/1308753003 .

Cr-Commit-Position: refs/heads/master@{#9756}
2015-08-21 13:52:58 +00:00
fe3bc9d5ae Relanding "Generate localhost candidate when no STUN/TURN and portallocator has the right flag spefied."
Migrated from https://codereview.webrtc.org/1275703006/ which causes test failures for android. On android, loopback interface was used as local interface to generate candidates. Add a test case to make sure this won't be broken in the future.

Also observed some failures under content_browsertests in chromium.fyi bot but can't repro locally. Might just be temporary test issue.

BUG=webrtc:4517
TBR=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1299333003 .

Cr-Commit-Position: refs/heads/master@{#9746}
2015-08-20 15:48:27 +00:00
081f34b564 Reland "Remove GICE (gone forever!) and PORTALLOCATOR_ENABLE_SHARED_UFRAG (enabled forever)." becauese remoting code is using dead constants and breaks the FYI bots."
This reverts commit 475243a134be003aab30bb17294ca6c664d0ef81.

R=guoweis@webrtc.org

Review URL: https://codereview.webrtc.org/1291363005 .

Cr-Commit-Position: refs/heads/master@{#9738}
2015-08-20 03:37:59 +00:00
3d564c1015 Add instrumentation to track the IceEndpointType.
The IceEndpointType has the format of <local_endpoint>_<remote_endpoint>. It is recorded on the BestConnection when we have the first OnTransportCompleted signaled.

BUG=webrtc:4918
R=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1277263002 .

Cr-Commit-Position: refs/heads/master@{#9737}
2015-08-19 23:51:22 +00:00
370c8848ad Revert "Generate localhost candidate when no STUN/TURN and portallocator has the right flag spefied."
This reverts commit 0a2955f227666efd87b2a303a69c083ef801c528.

Revert "In the past, P2PPortAllocator.enable_multiple_routes is the indicator whether we should bind to the any address. It's easy to translate that into a port allocator flag in P2PPortAllocator's ctor. Going forward, we have to depend on an asynchronous permission check to determine whether gathering local address is allowed or not, hence the current way of passing it through constructor approach won't work any more. The asynchronous check will trigger SignalNetowrksChanged so we could only check that inside DoAllocate."

This reverts commit ba9ab4cd8d2e8fbc068dc36b5e6f6331d7deeccf.

TBR=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1288843003 .

Cr-Commit-Position: refs/heads/master@{#9729}
2015-08-19 00:00:21 +00:00
0a2955f227 Generate localhost candidate when no STUN/TURN and portallocator has the right flag spefied.
BUG=webrtc:4517
R=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1275703006 .

Cr-Commit-Position: refs/heads/master@{#9726}
2015-08-18 20:05:29 +00:00
fa301809b6 Revert "Remove GICE (gone forever!) and PORTALLOCATOR_ENABLE_SHARED_UFRAG (enabled forever)." becauese remoting code is using dead constants and breaks the FYI bots.
This reverts commit 3449faa553ec94c52ef2d0949867befb60992c88.

TBR=deadbeef@webrtc.org, juberti@webrtc.org
NOPRESUBMIT=true

Review URL: https://codereview.webrtc.org/1274273005

Cr-Commit-Position: refs/heads/master@{#9698}
2015-08-11 11:13:00 +00:00
3449faa553 Remove GICE (gone forever!) and PORTALLOCATOR_ENABLE_SHARED_UFRAG (enabled forever).
R=deadbeef@webrtc.org, juberti@webrtc.org

Review URL: https://codereview.webrtc.org/1263663002 .

Cr-Commit-Position: refs/heads/master@{#9692}
2015-08-10 19:22:59 +00:00
b19eba3d4b Fix Turn TCP port issue.
Sometimes the port still try to send stun packet when the connection is disconnected,
causing an assertion error.

BUG=4859

Review URL: https://codereview.webrtc.org/1247573002

Cr-Commit-Position: refs/heads/master@{#9671}
2015-08-03 17:23:40 +00:00
eebcab5ce9 rtc::Buffer: Rename length to size, for conformance with the STL
And add a constructor for creating an uninitialized Buffer of a
specified size.

(I intend to follow up with more Buffer changes, but since it's rather
widely used, the rename is quite noisy and works better as a separate
CL.)

R=tommi@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/48579004

Cr-Commit-Position: refs/heads/master@{#8841}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8841 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-03-24 09:20:19 +00:00
95a32ec098 Revert 8271 "VirtualSocketServer out-of-order issue with closing..."
Failed on Linux_Memcheck bot.
http://chromegw/i/client.webrtc/builders/Linux%20Memcheck/builds/3182

> VirtualSocketServer out-of-order issue with closing TCP sockets
> 
> https://webrtc-codereview.appspot.com/41449004 added a TURN TCP
> allocation release test which was disabled as it triggered an assert
> in the turnserver.
> 
> This was caused by VirtualSockerServer delivering the last TCP packet
> after closing the connection. Calling
>     VirtualSocketServer::SendTcp
> and
>     VirtualSocket::Close
> from TestTurnTCPReleaseAllocation led to the following order of
> messages in VirtualSocket::OnMessage:
>     MSG_ID_DISCONNECT
>     MSG_ID_PACKET
> 
> This is out of order and triggers an assert in turnserver.cc since the
> socket from which the message arrives has already been discarded,
> subsequently breaking the test.
> 
> In VirtualSocketServer::Disconnect the MSG_ID_DISCONNECT is posted to the
> msg_queue immediately, thus getting ahead of any (slightly delayed)
> actual packets.
> 
> Maybe PostAt(network_delay_ + 1, ...) would be better?
> 
> Re-enables TestTurnTCPReleaseAllocation.
> 
> BUG=
> R=juberti@webrtc.org
> 
> Review URL: https://webrtc-codereview.appspot.com/34759004

TBR=pthatcher@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/38979004

Cr-Commit-Position: refs/heads/master@{#8280}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8280 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-02-07 06:47:21 +00:00
4770437da9 VirtualSocketServer out-of-order issue with closing TCP sockets
https://webrtc-codereview.appspot.com/41449004 added a TURN TCP
allocation release test which was disabled as it triggered an assert
in the turnserver.

This was caused by VirtualSockerServer delivering the last TCP packet
after closing the connection. Calling
    VirtualSocketServer::SendTcp
and
    VirtualSocket::Close
from TestTurnTCPReleaseAllocation led to the following order of
messages in VirtualSocket::OnMessage:
    MSG_ID_DISCONNECT
    MSG_ID_PACKET

This is out of order and triggers an assert in turnserver.cc since the
socket from which the message arrives has already been discarded,
subsequently breaking the test.

In VirtualSocketServer::Disconnect the MSG_ID_DISCONNECT is posted to the
msg_queue immediately, thus getting ahead of any (slightly delayed)
actual packets.

Maybe PostAt(network_delay_ + 1, ...) would be better?

Re-enables TestTurnTCPReleaseAllocation.

BUG=
R=juberti@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/34759004

Cr-Commit-Position: refs/heads/master@{#8271}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8271 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-02-06 16:33:47 +00:00
fe672e3839 release the turn allocation by sending a refresh request with lifetime 0
BUG=406578

Patch originally from philipp.hancke@googlemail.com

R=juberti@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/41449004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@8087 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-01-17 00:58:15 +00:00
19e4e8d751 Add support for trying alternate server (STUN 300 error message) on TCP
BUG=3774
R=juberti@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/32979004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@8036 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-01-10 02:41:32 +00:00
0ba1533fdb Added support for an Origin header in STUN messages.
For WebRTC there are instances where it may be desirable to provide
information to the STUN/TURN server about the website that initiated
a peer connection. This modification allows an origin string to be
included in the MediaConstraints object provided by the browser, which
is then passed as a STUN header in communications with the server.
A separate change will be submitted to the Chromium project that
uses and is dependent on this change, implementing IETF draft
http://tools.ietf.org/html/draft-johnston-tram-stun-origin-02

Originally a patch from skobalt@gmail.com.

(https://webrtc-codereview.appspot.com/12839005/edit)

R=juberti@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/41409004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@8035 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-01-10 00:47:02 +00:00
4fba293c87 Workaround for issue 3927 to allow localhost IP even if it doesn't match the local turn port
BUG=3927
R=pthatcher@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/28329004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@7941 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-12-18 04:45:05 +00:00
269fb4bc90 move xmpp and p2p to webrtc
Create a copy of talk/xmpp and talk/p2p under webrtc/libjingle/xmpp and
webrtc/p2p. Also makes libjingle use those version instead of the one in the talk folder.

BUG=3379

Review URL: https://webrtc-codereview.appspot.com/26999004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@7549 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-10-28 22:20:11 +00:00
28100cb388 Reverts r7459 "Create a copy of talk/xmpp and talk/p2p under webrtc/libjingle/xmpp and webrtc/p2p."
BUG=N/A
TBR=niklas.enbom@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/29829004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@7472 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-10-17 22:03:39 +00:00
d1ba6d9cbf Create a copy of talk/xmpp and talk/p2p under webrtc/libjingle/xmpp and webrtc/p2p.
BUG=3379
R=niklas.enbom@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/27709005

git-svn-id: http://webrtc.googlecode.com/svn/trunk@7459 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-10-15 17:30:28 +00:00