elixir-webrtc / ex_webrtc

An Elixir implementation of the W3C WebRTC API
Apache License 2.0
269 stars 8 forks source link

Call end_of_candidates on receiving an empty ICE candidate #68

Closed mickel8 closed 4 months ago

mickel8 commented 4 months ago

Looks like Firefox won't start sending data until there is at least one nominated pair. Even when it has succeeded pair.

I ran FF with MOZ_LOG=webrtc_trace:5 firefox and in about:firefox there is:

ICE-PEER(PC:{c24206e8-75db-4355-a73b-de9a9828c09c} 1707254636988657 (id=6442450946 url=http://127.0.0.1:8829/index.html):default)/CAND-PAIR(kWR0): setting pair to state SUCCEEDED: ...

In our ICE implementation, we only nominate after the remote side has indicated that there won't be any new remote candidates - we follow RFC 8445.

IIRC, most of implementations rely on aggressive nomination described in RFC 5245.

Our implementation should be compatible both with 8445 and 5245 but apparently I might have missed something.

Calling end_of_candidates solves the problem but this needs further investigation - see elixir-webrtc/ex_ice#19