javascriptnetwork-programmingwebrtcrelayjsturn

Is Numb Turn server not working or are my configurations wrong?


I am using the free TURN server provided by https://numb.viagenie.ca/. The STUN servers are also public.

I am using the following configuration:

const iceConfiguration = {
    iceServers: [
        {
            url: 'stun:stunserver.stunprotocol.org'
        },
        {
            url: 'stun:stun.sipgate.net:10000'
        },
        {
            url: 'turn:numb.viagenie.ca',
            credential: 'mypassword',
            username: 'myemail'
        }
    ]
}

I create an offer, send it to the other peer (different NAT) and then attempt to set the remote description with the answer. Upon calling myConnection.setRemoteDescription(answer), it keeps pending indefinitely and does not get resolved. Also, the remote peer can set its remote description without any issues. It all works fine for devices in the same network. So, I guess the problem lies in the relay server.

If so, should I ditch the public Numb server and opt towards using Coturn with DigitalOcean hosting or am I doing something totally wrong here?


Solution

  • It seems as though the Numb TURN servers do not actually work. No idea why. But they do show up in the WebRTC trickle ICE sample application.