Smart SIP and Media Gateway to connect WebRTC endpoints to any SIP-legacy network
C C++ Other
Permalink
Failed to load latest commit information.
db Update code for OSX Dec 1, 2015
documentation Update code for OSX Dec 1, 2015
doubango Update code for OSX Dec 1, 2015
jsoncpp Update code for OSX Dec 1, 2015
tinywrap Update code for OSX Dec 1, 2015
website Update website Dec 9, 2015
xcode Add xcode project Mar 7, 2016
Building_Source_v2_0.md Update Building_Source_v2_0.md Jun 2, 2016
FAQ.md Update code for OSX Dec 1, 2015
Makefile.am Update code for OSX Dec 1, 2015
README.md Update code for OSX Dec 1, 2015
ReleaseNotes.md Update code for OSX Dec 1, 2015
SSL_CA.der Update code for OSX Dec 1, 2015
SSL_CA.pem Update code for OSX Dec 1, 2015
SSL_Priv.pem Update code for OSX Dec 1, 2015
SSL_Pub.der Update code for OSX Dec 1, 2015
SSL_Pub.pem Update code for OSX Dec 1, 2015
autogen.sh Align with Doubango 801 Jan 7, 2013
config.xml Update code for OSX Dec 1, 2015
configure.ac Update code for OSX Dec 1, 2015
mediaproxy.sln Update code for OSX Dec 1, 2015
mediaproxy.vcproj Update code for OSX Dec 1, 2015
mp_c2c.cc Update code for OSX Dec 1, 2015
mp_c2c.h Update code for OSX Dec 1, 2015
mp_common.h Update code for OSX Dec 1, 2015
mp_config.h Update code for OSX Dec 1, 2015
mp_engine.cc Update code for OSX Dec 1, 2015
mp_engine.h Update code for OSX Dec 1, 2015
mp_mail.cc Update code for OSX Dec 1, 2015
mp_mail.h Update code for OSX Dec 1, 2015
mp_mediaproxy.cc Update code for OSX Dec 1, 2015
mp_mutex.cc Update code for OSX Dec 1, 2015
mp_mutex.h Update code for OSX Dec 1, 2015
mp_net_transport.cc Update code for OSX Dec 1, 2015
mp_net_transport.h Update code for OSX Dec 1, 2015
mp_object.cc Update code for OSX Dec 1, 2015
mp_object.h Update code for OSX Dec 1, 2015
mp_peer.cc Update code for OSX Dec 1, 2015
mp_peer.h Update code for OSX Dec 1, 2015
mp_proxyplugin.cc Update code for OSX Dec 1, 2015
mp_proxyplugin.h Update code for OSX Dec 1, 2015
mp_proxyplugin_consumer_audio.cc Update code for OSX Dec 1, 2015
mp_proxyplugin_consumer_audio.h Update code for OSX Dec 1, 2015
mp_proxyplugin_consumer_video.cc Update code for OSX Dec 1, 2015
mp_proxyplugin_consumer_video.h Update code for OSX Dec 1, 2015
mp_proxyplugin_mgr.cc Update code for OSX Dec 1, 2015
mp_proxyplugin_mgr.h Update code for OSX Dec 1, 2015
mp_proxyplugin_producer_audio.cc Update code for OSX Dec 1, 2015
mp_proxyplugin_producer_audio.h Update code for OSX Dec 1, 2015
mp_proxyplugin_producer_video.cc Update code for OSX Dec 1, 2015
mp_proxyplugin_producer_video.h Update code for OSX Dec 1, 2015
mp_recaptcha.cc Update code for OSX Dec 1, 2015
mp_recaptcha.h Update code for OSX Dec 1, 2015
mp_session.cc Update code for OSX Dec 1, 2015
mp_session.h Update code for OSX Dec 1, 2015
mp_session_av.cc Update code for OSX Dec 1, 2015
mp_session_av.h Update code for OSX Dec 1, 2015
mp_wrap.cc Update code for OSX Dec 1, 2015
mp_wrap.h Update code for OSX Dec 1, 2015
resiprocate-deprecated.patch Update code for OSX Dec 1, 2015
self-signed-certs.sh Update code for OSX Dec 1, 2015

README.md

Source code freely provided to you by Doubango Telecom ®.
This is part of sipML5 solution and don't hesitate to test our live demo.

webrtc2sip is a smart and powerful gateway using RTCWeb and SIP to turn your browser into a phone with audio, video and SMS capabilities. The gateway allows your web browser to make and receive calls from/to any SIP-legacy network or PSTN.
As an example, you will be able to make a call from your preferred web browser to a SIP-legacy softphone (e.g. xlite) or mobile/fixed phone.
The gateway contains four modules: SIP Proxy | RTCWeb Breaker | Media Coder | Click-to-Call service..

documentation/images/architecture.png
Global architecture

SIP Proxy

The role of the SIP Proxy module is to convert the SIP transport from WebSocket protocol to UDP, TCP or TLS which are supported by all legacy networks. If your provider or hosted server supports SIP over WebSocket (e.g. Asterisk or Kamailio) then, you can bypass the module and connect the client directly to the endpoint. Bypassing the SIP Proxy is not recommended if you’re planning to use the RTCWeb Breaker or Media Coder modules as this will requires maintaining two different connections.
There are no special requirements for the end server to be able to talk to the Proxy module.

documentation/images/module_sipproxy.png
SIP Proxy architecture

RTCWeb Breaker

The RTCWeb specifications make support for ICE and DTLS/SRTP mandatory. The problem is that many SIP-legacy endpoints (e.g. PSTN network) do not support these features. It’s up to the RTCWeb Breaker to negotiate and convert the media stream to allow these two worlds to interop.
We highly recommend checking the Technical Guide to understand how to avoid security issues when using this module. For example, FreeSWITCH do not support ICE which means it requires the RTCWeb Breaker in order to be able to connect the browser to a SIP-legacy endpoint.

http://webrtc2sip.googlecode.com/svn/trunk/documentation/images/module_rtcwebbreaker.png
RTCWeb Breaker architecture

Media Coder

The RTCWeb standard defined two MTI (Mandatory To Implement) audio codecs: opus and g.711.
For now there are intense discussions about the MTI video codecs. The choice is between VP8 and H.264. VP8 is royalty-free but not widely deployed while H.264 AVC is not free but widely deployed. Google has decided to use VP8 in Chrome while Ericsson uses H.264 AVC in Bowser. Mozilla and Opera Software will probably use VP8 and Microsoft H.264 AVC. As an example, the Media Coder will allow to make video calls between Chrome and Bowser. Another example is calling a Telepresence system (e.g. Cisco) which most likely uses H.264 SVC from Chrome.

documentation/images/module_mediacoder.png
Media Coder architecture

Click-to-Call service

This is a complete SIP click-to-call solution based on the three other components. The goal is to allow any person receiving your mails, visiting your website, reading your twitts, watching your Facebook/Google+ profile to call you on your mobile phone with a single click. As an example, click here to call me on my mobile phone.
For more information: http://click2dial.org

documentation/images/module_click-to-call.png
Click-to-Call Components

Testing the gateway

Let's say the webrtc2sip gateway and SIP server are running on two different PCs with IP addresses equal to 192.168.0.1 and 192.168.0.2 respectively.

  1. Open http://sipml5.org/expert.htm in your browser
  2. Fill “WebSocket Server URL” field with the IP address and port where your webrtc2sip gateway is listening for incoming Websocket connections (e.g ws://192.168.0.1:10060 or wss://192.168.0.1:10062). IMPORTANT: Do not forget the url scheme (ws:// or wss://).
  3. The “SIP outbound Proxy URL” is used to set the destination IP address and Port to use for all outgoing requests regardless the domain name (a.k.a realm). This is a good option for developers using a SIP domain name without valid DNS A/NAPTR/SRV records. E.g. udp://192.168.0.2:5060.
  4. Check “Enable RTCWeb Breaker” if you want to call a SIP-legacy endpoint.

Security Issues

We highly recommend checking the Technical Guide to understand how to avoid security issues when using our gateway.

Technical help

Please check our issue tracker, developer group and technical guide if you have any problem.

© 2012-2015 Doubango Telecom
Inspiring the future