adapter icon indicating copy to clipboard operation
adapter copied to clipboard

Error c0044003 in Edge when using multiple valid turn servers

Open kapetan opened this issue 9 years ago • 4 comments

Browsers and versions affected Edge 14.14393

Description When using multiple valid turn servers var iceGatherer = new RTCIceGatherer(self.iceOptions); throws Error: Could not complete the operation due to error c0044003 exception.

According to this issue Edge does not support multiple turn servers. Maybe an easy solution would be just to filter out additional turn servers.

Steps to reproduce Initialize a new RTCPeerConnection with multiple turn servers.

var pc = new RTCPeerConnection({
  iceServers: [{
    "username": "...",
    "credential": "...",
    "urls": ["turn:example.com:80?transport=udp"]
  },
  {
    "username": "...",
    "credential": "...",
    "urls": ["turn:example.com:3478?transport=udp"]
  }]
});

Expected results It creates a RTCPeerConnection.

Actual results Throws a c0044003 error.

kapetan avatar Feb 20 '17 15:02 kapetan

As per my opinion, need to report this issue to Microsoft Edge Team! Please check.. #446 However your error code is different, in my case I am getting c004e001

N.B:

  1. I would like to confirm you that Edge can support multiple TURN servers!! I had tested without any error.
  2. Sometime it can fails for valid TURN server also. In my case, stun:stun.iptel.org is not working!!

santanubrahma avatar Feb 20 '17 22:02 santanubrahma

@kapetan this is fairly complex to filter afaics since the turn servers could be either in .url, multiple turn servers in .urls and spanning multiple ice server entries. I've added a test for the filtering in #454, if you want to make a PR this test would need to pass at minimum:

    it('removes all but the first server of a type', () => {
      pc = new RTCPeerConnection({
        iceServers: [
          {urls: 'stun:stun.l.google.com'},
          {urls: 'turn:stun.l.google.com:19301?transport=udp'},
          {urls: 'turn:stun.l.google.com:19302?transport=udp'},
        ]
      });
      expect(pc.iceOptions.iceServers).to.deep.equal([
        {urls: 'stun:stun.l.google.com'},
        {urls: 'turn:stun.l.google.com:19301?transport=udp'},
      ]);
    });

fippo avatar Feb 22 '17 08:02 fippo

@KaptenJansson we're done here. Less issues (-:

fippo avatar Mar 14 '17 12:03 fippo

@fippo is it fixed, because i have same bug now on version 5.0.3

fix2015 avatar Sep 06 '17 09:09 fix2015