Custom Private Servers

muaz-khan edited this page Sep 29, 2014 · 1 revision

This wiki page explains how to integrate/use your custom "private" signaling & NAT-traversing servers within your RTCMultiConnection applications.

RTCMultiConnection is using two kinds of 3rd-party (external) servers:

  1. ICE-servers
  2. Signaling servers

The concept of these servers is explained here:

NAT-traversing Servers

BTW, RTCMultiConnection is exposing an array object named as "iceServers":

This array object allows you override/overwrite default ice servers so you'll be using your own custom but "private" ice servers:

// don't forget to set it "false"
// to force RTCMultiConnection NEVER get any external ice server
connection.getExternalIceServers = false;

var iceServers = [];

iceServers.push({
    url: 'turn:domain.com:443?transport=tcp',
    credential: 'password',
    username: 'username'
});

connection.iceServers = iceServers;

getExternalIceServers is a boolean property that allows you force RTCMltiConnection to NEVER get ice servers from XirSys.

Here is how to install your own custom/private TURN server:

Now, RTCMultiConnection is using ice servers from your own installation paths. RTCMultiConnection will NEVER be getting any external ice server.

Signaling Servers

Now, regarding using your custom signaling servers, there are two options:

  1. Either use your own "existing" signaling implementations
  2. Or, use signaling implementations that I already included in my github repositories

Regarding 1st option; you should check this:

Regarding 2nd option, here are some existing signaling implmentations:

  1. Socket.io over Node.js
  2. WebSocket over Node.js
  3. WebSync for Signaling — useful only for .NET developers
  4. XHR/XMLHttpRequest Signaling — useful for both .NET and PHP developers!

openSignalingChannel is a method declaration that you can overwrite/override in your applications to easily force to use your own custom/private signaling servers. Above all examples are overriding it:

Some relevant posts: