[libnice] Selecting server reflexive candidates
philip at tecnocode.co.uk
Fri Jun 5 06:03:34 PDT 2015
On Tue, 2015-06-02 at 11:32 +0200, Jakub Adam wrote:
> I would like to ask you for a review of the following libnice patch that tries to
> solve an issue with candidate selection that I've encountered when a server-reflexive
> IP address appeared in XOR-MAPPED-ADDRESS of an incoming connectivity check response.
As Ilya says, please do open a bug report about this:
Anyway, some review comments. Firstly, a description of a simple network
configuration which triggers this would be appreciated, and would make
the review a lot easier to reason about.
I _think_ the patch is correct with reference to the specification, but
I would want to see an example network configuration before accepting
Effectively, it allows priv_add_peer_reflexive_pair() to be called with
the (mapped address of the) local candidate if local_cand_matches, which
wasn’t allowed before.
It limits priv_conn_check_unfreeze_related() to now only be called if a
new_pair is found, which seems to be more correct wrt §22.214.171.124.2 of the
specification than the current implementation, which considers
‘adding to VALID LIST’ if only a local candidate matches, rather than
the whole pair.
However, since this patch changes
priv_process_response_check_for_peer_reflexive() to also check for
server reflexive candidates, I suggest renaming it to
priv_process_response_check_for_reflexive(). Its documentation and call
sites also need to be updated to indicate that it can no longer return
NULL in any case.
Finally, I would like some review from someone else who knows the ICE
specification better than me (Olivier or Youness).
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 213 bytes
Desc: This is a digitally signed message part
More information about the nice