1. 21 Jun, 2017 1 commit
    • Fabrice Bellet's avatar
      conncheck: improve triggered check of in-progress pairs · 2fd78084
      Fabrice Bellet authored
      This patch update the way triggered checks of in-progress pairs are
      handled, according to ICE spec, section Previously the same
      connection check was retransmitted with an updated timeout. This causes
      problems when a controlling role switch occurs in this time frame.
      This is the reason why a new connection check must be generated
      reflecting the updated role. We introduce a new flag "recheck_on_timeout"
      in the pair indicating that the pair must be rechecked at the next timer
      Differential Revision: https://phabricator.freedesktop.org/D875
  2. 12 Jun, 2017 8 commits
    • Fabrice Bellet's avatar
    • Fabrice Bellet's avatar
      conncheck: improve the selection of the pairs to be checked · 15c0546f
      Fabrice Bellet authored
      This patch aims to implement more closely the algorithm described
      in RFC 5245 indicating how pairs are transitionned from state Frozen
      to Waiting. This is described in when a check succeeded, and
      correspond to modifications in function priv_conn_check_unfreeze_related().
      This is also described in 5.7.4 when defining the initial state of the
      pairs in a conncheck, and correspond to modifications in function
      This patch introduces the notion of active and frozen check list. It
      allows us to define the timer restranmission delay as described in 16.1.
      Another modification in priv_conn_check_tick_unlocked() is that every
      stream in handled consecutively, and in an independant way. The pacing
      was previously of a single STUN request emitted per callback, it is now
      of a triggered check per callback OR a single STUN per callback AND per
      stream per callback.
      The description of ordinary checks per stream in 5.8 is detailled in
      function priv_conn_check_tick_stream(), and a remaining of the code
      used to nominate a pair by the controlling agent is put in a dedicated
      function priv_conn_check_tick_stream_nominate()
      Differential Revision: https://phabricator.freedesktop.org/D813
    • Fabrice Bellet's avatar
      conncheck: update pair valid property selectively · 58d061df
      Fabrice Bellet authored
      With this patch, we fix a corner case when the succeeded pair is a
      peer-reflexive candidate pair, that already has been discovered
      previously, In this case, the current pair -p- should not be marked
      valid, because the valid flag is already set on the discovered pair.
      Differential Revision: https://phabricator.freedesktop.org/D1124
    • Fabrice Bellet's avatar
      conncheck: implement ice regular nomination method · 0636f9ad
      Fabrice Bellet authored
      This patch implements Regular Nomation as described in RFC5245 The controlling agent lets valid pairs accumulate, and
      decides which pair to recheck with the use-candidate attribute set.
      priv_mark_pair_nominated() follows, to update the nominated
      pair when acting as a STUN server, and
      priv_map_reply_to_conn_check_request() implements to
      update the nominated pair when acting as a STUN client. A new
      property is also added to the agent to control the nomination
      mode, which can be regular of aggressive, with default value
      set to aggressive.
      Two new flags are introduced in the CandidateCheckPair structure:
      - use_candidate_on_next_check indicates the STUN client to add the
        use-candidate attribute when the pair will be checked. At this
        time, the nominated flag has not been set on this pair yet.
      - mark_nominated_on_response_arrival indicates the STUN server
        to nominate the pair when its succesfull response to a
        previous triggered check will arrive (, item #2)
      Differential Revision: https://phabricator.freedesktop.org/D811
    • Fabrice Bellet's avatar
      conncheck: fix pair state transition when successful response is received · a602ff57
      Fabrice Bellet authored
      According the ICE RFC 5245,, the pair that *generated* a
      successful check should go to state succeeded, not only the valid
      pair built in section
      Differential Revision: https://phabricator.freedesktop.org/D810
    • Fabrice Bellet's avatar
      conncheck: peer reflexive candidates are not paired · 3a58ba61
      Fabrice Bellet authored
      This patch makes the code compliant with ICE RFC, "Learning
      Peer Reflexive Candidates" and "Discovering Peer Reflexive
      Candidates", where discovered candidates do not cause the creation
      of new pairs to be checked.
      Differential Revision: https://phabricator.freedesktop.org/D805
    • Fabrice Bellet's avatar
      conncheck: update selected pair when nominated flag is set · 7a2c1edf
      Fabrice Bellet authored
      This modifies commit 8f1f615e. It is better focused to update the
      selected pair just after its nominated flag has been set. We also keep
      the code homogeneous with other places, where the call to
      priv_update_selected_pair() immediately follows the setting of
      pair->nominated. Moreover in priv_update_check_list_state_for_ready(),
      we would call priv_update_selected_pair() more times that necessary when
      iterating on all nominated pairs.
      Differential Revision: https://phabricator.freedesktop.org/D1125
    • Fabrice Bellet's avatar
      stun timer: make properties for stun timer tunables · 8bb210c5
      Fabrice Bellet authored
      Three STUN binding request properties should be customisable. RFC 5245
      describes the retransmission timer of the STUN transaction 'RTO', and
      RFC 5389 describes the number of retransmissions to send until a
      response is received 'Rc'. The third property is the 'RTO' when
      a reliable connection is used.
      RFC 5389 introduces a supplementary property 'Rm' as a multiplier used
      to compute the final timeout RTO * Rm. However, this property is not
      added in libnice, because this would require breaking the public API for
      STUN. Currently, our STUN implementation hardcodes a division by two for
      this final timeout.
      Differential Revision: https://phabricator.freedesktop.org/D1109
  3. 11 Apr, 2017 2 commits
  4. 04 Apr, 2017 3 commits
  5. 26 Oct, 2016 2 commits
    • Jakub Adam's avatar
      ms-ice: limit legacy connchecks as per [MS-ICE2] · 2803a0b4
      Jakub Adam authored
      Client should stop sending connectivity checks with legacy FINGERPRINT
      when it receives a conncheck message containing IMPLEMENTATION-VERSION
      Differential Revision: https://phabricator.freedesktop.org/D1139
    • Jakub Adam's avatar
      ms-ice: legacy FINGERPRINT mode · 7e5ab23c
      Jakub Adam authored
      In order to preserve compatibility with clients which use custom CRC
      lookup table from [MS-ICE2], whenever a connectivity check request or
      reply is sent, an additional message is sent along. These two messages
      differ only in FINGERPRINT attribute - one uses regular CRC lookup table
      for calculation, the other uses the modified table.
      When a message is received and FINGERPRINT doesn't pass validation using
      regular CRC table, the receiver also tries to verify using the modified
      [MS-ICE2] describes this procedure.
      The commit fixes compatibility with older MSOC and Lync clients.
      Differential Revision: https://phabricator.freedesktop.org/D1138
  6. 23 Jun, 2016 3 commits
  7. 20 Jun, 2016 3 commits
  8. 06 Jun, 2016 1 commit
  9. 01 Jun, 2016 1 commit
  10. 31 May, 2016 1 commit
  11. 30 May, 2016 2 commits
  12. 27 May, 2016 6 commits
  13. 26 May, 2016 7 commits