Repository navigation
Tags
Tags
Stabilize ICE-lite priorities like libwebrtc History: PR #959 let ICE-lite agents pick the best pair locally without sending checks. All lite host candidates had the same priority, so with several candidates the two sides could pick different pairs and fail to connect. #968 fixed that by stepping each new lite candidate down from the default until its priority was unique. That made priorities depend on gather order: the same address could get a different priority on another node, or depending on whether the node was single- or dual-stack. The main problem is that Pion doesn't have local preference like libwebrtc, instead of doing other hacks this adds: `(counter << 8) | address precedence`. The low byte is the RFC 6724 precedence of the address (IPv6 40, IPv4 30, and so on), so address families never collide. The counter drops only to separate candidates of the same family. A candidate's priority no longer depends on gather order or on whether the agent is single- or dual-stack. Unlike libwebrtc, the high byte is not a network adapter preference, since Pion has no adapter types.
Stabilize ICE-lite priorities like libwebrtc History: PR #959 let ICE-lite agents pick the best pair locally without sending checks. All lite host candidates had the same priority, so with several candidates the two sides could pick different pairs and fail to connect. #968 fixed that by stepping each new lite candidate down from the default until its priority was unique. That made priorities depend on gather order: the same address could get a different priority on another node, or depending on whether the node was single- or dual-stack. The main problem is that Pion doesn't have local preference like libwebrtc, instead of doing other hacks this adds: `(counter << 8) | address precedence`. The low byte is the RFC 6724 precedence of the address (IPv6 40, IPv4 30, and so on), so address families never collide. The counter drops only to separate candidates of the same family. A candidate's priority no longer depends on gather order or on whether the agent is single- or dual-stack. Unlike libwebrtc, the high byte is not a network adapter preference, since Pion has no adapter types.
Use 64 bit candidate pair packet counters packetsSent and packetsReceived are unsigned long long in the specification since w3c/webrtc-stats#494
Request relayed address in the candidate family When only a single candidate family is configured, request the relayed address in that family, even if the TURN server is reached over the other family. Previously, the TURN server allocated the relay in the transport's family, and ice then discarded it.
sped: keep the DTLS 1.3 server's packets on handshake completion (#1024) The DTLS 1.3 server completes when it receives the client's Finished but still has to ACK it. That ACK may be queued before completion is signaled and dropping the outgoing packets loses it, so the client retransmits its last flight a second later. Only the DTLS 1.2 client has nothing more to send and drops its packets, while it keeps sending ACK attributes until it receives the server's last flight. (comment now matches what I wrote in libwebrtc)
PreviousNext