paullouisageneau / libjuice

JUICE is a UDP Interactive Connectivity Establishment library
Mozilla Public License 2.0
403 stars 75 forks source link

Add support for setting ICE ufrag and pwd #243

Closed xicilion closed 3 months ago

xicilion commented 3 months ago

In order to support Peer A and Peer B in WebRTC Direct, we need to be able to specify the ufrag and pwd of the localDescription. WebRTC Direct's documentation suggests replacing the ufrag and pwd with setLocalDescription. This is not compliant with the standard.

Therefore, I propose another solution, we can set ufrag and pwd in juice_create, which can satisfy both Peer A and Peer B's needs, and will not modify the existing logic in any way.

paullouisageneau commented 3 months ago

Adding fields to the config struct breaks compatibility and would mean releasing a new major version of libjuice. You should instead introduce a function juice_set_local_ice_attributes(const char *ufrag, const char *pwd).

xicilion commented 3 months ago

shure.