[libnice] keepalive connchecks for TCP candidates

Olivier CrĂȘte olivier.crete at collabora.com
Tue Jan 23 16:25:22 UTC 2018


If you use TCP candidates and the connection to the remote endpoint
dies, I think the TCP connection to the turn server should get closed
too. On the first leg, you can enable TCP keepalives. But it indeed
doesn't help with the second leg. 

I'm not sure why we disabled the binding requests if TCP candidates are
utilized. I believe in standard compliant mode (ie, not MSN), it should
be fine.

Maybe Youness has another idea,


On Mon, 2018-01-22 at 16:13 +0000, Harald Glanzer wrote:
> hi,
> for my appliation (farstream + libnice) i need some way to detect
> network failures, i.e. i need
> a way to get signalled whenever the _remote_ side disappears.
> it turned out that using binding requests as keepalive mechnism works
> fine for UDP candidates. whenever the remote
> side has network issues and disappears, the local side does some
> retries and sends a signal which i am using to close the
> session from the application side.
> nevertheless, if TURN with TCP candidates is utilized, no binding
> requests are created (agent/conncheck.c, line ~850),
> and therefore, i do not get notified that the transport channel is
> not active any more. i guess this happens because the local
> connection to 
> the TURN server itself is still active, but the _remote_ endpoint has
> gone away (which, it seems, is not recognized by the TURN 
> server, who does not close the connection to the local TURN client).
> i am now struggling with the question if it makes sense to use
> keepalive binding requests as connection-checks for TCP too?
> i wonder if the TURN LIFETIME attribute ( https://tools.ietf.org/html
> /rfc5766#section-14.2 ) would be suitable, and if libnice is able
> to use this feature (some basic tests regarding LIFETIME were not
> sucessfull..)
> thx in advance
> hari
> _______________________________________________
> nice mailing list
> nice at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/nice
Olivier CrĂȘte
olivier.crete at collabora.com

More information about the nice mailing list