├── SSL_CA.der ├── SSL_Pub.der ├── xcode ├── .DS_Store └── webrtc2sip.xcodeproj │ ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcuserdata │ │ └── mamadou.xcuserdatad │ │ └── UserInterfaceState.xcuserstate │ └── xcuserdata │ └── mamadou.xcuserdatad │ └── xcschemes │ ├── xcschememanagement.plist │ └── webrtc2sip.xcscheme ├── documentation ├── architecture.dia ├── images │ ├── OSes.png │ ├── expert.png │ ├── logo_48x48.png │ ├── logo_64x64.png │ ├── logo_72x72.png │ ├── architecture.png │ ├── cloud_128x128.png │ ├── module_sipproxy.png │ ├── browsers_300x300.png │ ├── module_mediacoder.png │ ├── rectangle_256x256.png │ ├── expert_rtcwebbreaker.png │ ├── module_click-to-call.png │ └── module_rtcwebbreaker.png ├── module_sipproxy.dia ├── module_mediacoder.dia ├── module_click-to-call.dia ├── module_rtcwebbreaker.dia ├── technical-guide-1.0.doc └── technical-guide-1.0.pdf ├── website ├── assets │ ├── img │ │ ├── browsers.png │ │ ├── icon-css3.png │ │ ├── icon-html5.png │ │ ├── less-small.png │ │ ├── github-16px.png │ │ ├── icon-github.png │ │ ├── icon-twitter.png │ │ ├── less-logo-large.png │ │ ├── grid-18px-masked.png │ │ ├── glyphicons-halflings.png │ │ ├── responsive-illustrations.png │ │ ├── glyphicons-halflings-white.png │ │ └── glyphicons │ │ │ ├── glyphicons_009_magic.png │ │ │ ├── glyphicons_042_group.png │ │ │ ├── glyphicons_079_podium.png │ │ │ ├── glyphicons_163_iphone.png │ │ │ ├── glyphicons_266_book_open.png │ │ │ ├── glyphicons_082_roundabout.png │ │ │ ├── glyphicons_214_resize_small.png │ │ │ └── glyphicons_155_show_thumbnails.png │ ├── ico │ │ ├── apple-touch-icon-114-precomposed.png │ │ ├── apple-touch-icon-57-precomposed.png │ │ └── apple-touch-icon-72-precomposed.png │ └── js │ │ ├── bootstrap-transition.js │ │ ├── google-code-prettify │ │ └── prettify.css │ │ ├── bootstrap-alert.js │ │ ├── bootstrap-dropdown.js │ │ ├── bootstrap-button.js │ │ ├── bootstrap-popover.js │ │ ├── bootstrap-tab.js │ │ ├── bootstrap-scrollspy.js │ │ ├── bootstrap-collapse.js │ │ ├── bootstrap-carousel.js │ │ ├── application.js │ │ ├── bootstrap-modal.js │ │ ├── bootstrap-typeahead.js │ │ └── bootstrap-tooltip.js └── contact.htm ├── tinywrap ├── SMS.i ├── Xcap.i ├── Msrp.i ├── SipCallback.cxx ├── SafeObject.cxx ├── SafeObject.h ├── DDebug.h ├── SipUri.h ├── ActionConfig.h ├── tinyWRAP.i ├── SipCallback.h ├── AudioResampler.h ├── MediaContent.h ├── tinyWRAP_config.h ├── SipMessage.h ├── AudioResampler.cxx ├── Msrp.h ├── SipUri.cxx ├── ActionConfig.cxx ├── Common.h ├── SMSEncoder.h ├── DDebug.cxx ├── ProxyPluginMgr.h ├── SipStack.h ├── Xcap.h └── MediaContent.cxx ├── autogen.sh ├── self-signed-certs.sh ├── SSL_Priv.pem ├── SSL_Pub.pem ├── mp_proxyplugin.cc ├── mp_session.cc ├── mp_object.cc ├── mp_mutex.h ├── SSL_CA.pem ├── mp_mutex.cc ├── mp_session.h ├── mp_peer.cc ├── config.xml ├── Makefile.am ├── mp_proxyplugin_producer_audio.cc ├── mp_proxyplugin.h ├── mp_wrap.h ├── mp_config.h ├── mp_session_av.h ├── mp_session_av.cc ├── db ├── sqlite │ └── mp_db_sqlite.h ├── mp_db.h └── mp_db_model.cc ├── mp_proxyplugin_consumer_video.cc ├── mp_proxyplugin_mgr.h ├── mp_proxyplugin_producer_video.cc ├── ReleaseNotes.md ├── FAQ.md ├── mp_peer.h ├── mp_mail.h ├── mp_proxyplugin_producer_audio.h ├── mp_proxyplugin_consumer_video.h ├── mp_proxyplugin_producer_video.h ├── mp_recaptcha.h ├── mp_c2c.h ├── mp_common.h ├── mp_proxyplugin_consumer_audio.h └── mp_engine.h /SSL_CA.der: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/SSL_CA.der -------------------------------------------------------------------------------- /SSL_Pub.der: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/SSL_Pub.der -------------------------------------------------------------------------------- /xcode/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/xcode/.DS_Store -------------------------------------------------------------------------------- /documentation/architecture.dia: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/architecture.dia -------------------------------------------------------------------------------- /documentation/images/OSes.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/OSes.png -------------------------------------------------------------------------------- /documentation/images/expert.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/expert.png -------------------------------------------------------------------------------- /documentation/module_sipproxy.dia: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/module_sipproxy.dia -------------------------------------------------------------------------------- /website/assets/img/browsers.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/browsers.png -------------------------------------------------------------------------------- /website/assets/img/icon-css3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/icon-css3.png -------------------------------------------------------------------------------- /website/assets/img/icon-html5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/icon-html5.png -------------------------------------------------------------------------------- /website/assets/img/less-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/less-small.png -------------------------------------------------------------------------------- /documentation/images/logo_48x48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/logo_48x48.png -------------------------------------------------------------------------------- /documentation/images/logo_64x64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/logo_64x64.png -------------------------------------------------------------------------------- /documentation/images/logo_72x72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/logo_72x72.png -------------------------------------------------------------------------------- /documentation/module_mediacoder.dia: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/module_mediacoder.dia -------------------------------------------------------------------------------- /tinywrap/SMS.i: -------------------------------------------------------------------------------- 1 | %{ 2 | #include "SMSEncoder.h" 3 | %} 4 | 5 | %nodefaultctor; 6 | %include "SMSEncoder.h" 7 | %clearnodefaultctor; -------------------------------------------------------------------------------- /website/assets/img/github-16px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/github-16px.png -------------------------------------------------------------------------------- /website/assets/img/icon-github.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/icon-github.png -------------------------------------------------------------------------------- /website/assets/img/icon-twitter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/icon-twitter.png -------------------------------------------------------------------------------- /documentation/images/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/architecture.png -------------------------------------------------------------------------------- /documentation/images/cloud_128x128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/cloud_128x128.png -------------------------------------------------------------------------------- /documentation/module_click-to-call.dia: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/module_click-to-call.dia -------------------------------------------------------------------------------- /documentation/module_rtcwebbreaker.dia: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/module_rtcwebbreaker.dia -------------------------------------------------------------------------------- /documentation/technical-guide-1.0.doc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/technical-guide-1.0.doc -------------------------------------------------------------------------------- /documentation/technical-guide-1.0.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/technical-guide-1.0.pdf -------------------------------------------------------------------------------- /website/assets/img/less-logo-large.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/less-logo-large.png -------------------------------------------------------------------------------- /documentation/images/module_sipproxy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/module_sipproxy.png -------------------------------------------------------------------------------- /website/assets/img/grid-18px-masked.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/grid-18px-masked.png -------------------------------------------------------------------------------- /documentation/images/browsers_300x300.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/browsers_300x300.png -------------------------------------------------------------------------------- /documentation/images/module_mediacoder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/module_mediacoder.png -------------------------------------------------------------------------------- /documentation/images/rectangle_256x256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/rectangle_256x256.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons-halflings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons-halflings.png -------------------------------------------------------------------------------- /documentation/images/expert_rtcwebbreaker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/expert_rtcwebbreaker.png -------------------------------------------------------------------------------- /documentation/images/module_click-to-call.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/module_click-to-call.png -------------------------------------------------------------------------------- /documentation/images/module_rtcwebbreaker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/documentation/images/module_rtcwebbreaker.png -------------------------------------------------------------------------------- /website/assets/img/responsive-illustrations.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/responsive-illustrations.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons-halflings-white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons-halflings-white.png -------------------------------------------------------------------------------- /website/assets/ico/apple-touch-icon-114-precomposed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/ico/apple-touch-icon-114-precomposed.png -------------------------------------------------------------------------------- /website/assets/ico/apple-touch-icon-57-precomposed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/ico/apple-touch-icon-57-precomposed.png -------------------------------------------------------------------------------- /website/assets/ico/apple-touch-icon-72-precomposed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/ico/apple-touch-icon-72-precomposed.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons/glyphicons_009_magic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons/glyphicons_009_magic.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons/glyphicons_042_group.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons/glyphicons_042_group.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons/glyphicons_079_podium.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons/glyphicons_079_podium.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons/glyphicons_163_iphone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons/glyphicons_163_iphone.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons/glyphicons_266_book_open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons/glyphicons_266_book_open.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons/glyphicons_082_roundabout.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons/glyphicons_082_roundabout.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons/glyphicons_214_resize_small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons/glyphicons_214_resize_small.png -------------------------------------------------------------------------------- /website/assets/img/glyphicons/glyphicons_155_show_thumbnails.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/website/assets/img/glyphicons/glyphicons_155_show_thumbnails.png -------------------------------------------------------------------------------- /xcode/webrtc2sip.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /xcode/webrtc2sip.xcodeproj/project.xcworkspace/xcuserdata/mamadou.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DoubangoTelecom/webrtc2sip/HEAD/xcode/webrtc2sip.xcodeproj/project.xcworkspace/xcuserdata/mamadou.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /autogen.sh: -------------------------------------------------------------------------------- 1 | echo libtoolize 2 | if [ `(uname -s) 2>/dev/null` == 'Darwin' ] 3 | then 4 | glibtoolize --copy --force 5 | else 6 | libtoolize --copy --force 7 | fi 8 | 9 | echo "aclocal" 10 | aclocal 11 | 12 | echo "autoheader" 13 | autoheader 14 | 15 | echo "create NEWS, README, AUTHORS and ChangeLog" 16 | touch NEWS README AUTHORS ChangeLog 17 | 18 | echo "autoreconf" 19 | autoreconf -i 20 | 21 | echo "automake" 22 | automake -a -------------------------------------------------------------------------------- /tinywrap/Xcap.i: -------------------------------------------------------------------------------- 1 | %{ 2 | #include "Xcap.h" 3 | %} 4 | 5 | /* Callbacks */ 6 | %feature("director") XcapCallback; 7 | 8 | 9 | %nodefaultctor; 10 | %include "Xcap.h" 11 | %clearnodefaultctor; 12 | 13 | typedef enum thttp_event_type_e 14 | { 15 | thttp_event_dialog_started, 16 | thttp_event_message, 17 | thttp_event_auth_failed, 18 | thttp_event_closed, 19 | thttp_event_transport_error, 20 | thttp_event_dialog_terminated 21 | } 22 | thttp_event_type_t; -------------------------------------------------------------------------------- /website/assets/js/bootstrap-transition.js: -------------------------------------------------------------------------------- 1 | !function(a){a(function(){a.support.transition=(function(){var c=document.body||document.documentElement,d=c.style,b=d.transition!==undefined||d.WebkitTransition!==undefined||d.MozTransition!==undefined||d.MsTransition!==undefined||d.OTransition!==undefined;return b&&{end:(function(){var e="TransitionEnd";if(a.browser.webkit){e="webkitTransitionEnd"}else{if(a.browser.mozilla){e="transitionend"}else{if(a.browser.opera){e="oTransitionEnd"}}}return e}())}})()})}(window.jQuery); -------------------------------------------------------------------------------- /website/assets/js/google-code-prettify/prettify.css: -------------------------------------------------------------------------------- 1 | .com{color:#93a1a1}.lit{color:#195f91}.pun,.opn,.clo{color:#93a1a1}.fun{color:#dc322f}.str,.atv{color:#D14}.kwd,.linenums .tag{color:#1e347b}.typ,.atn,.dec,.var{color:teal}.pln{color:#48484c}.prettyprint{padding:8px;background-color:#f7f7f9;border:1px solid #e1e1e8}.prettyprint.linenums{-webkit-box-shadow:inset 40px 0 0 #fbfbfc,inset 41px 0 0 #ececf0;-moz-box-shadow:inset 40px 0 0 #fbfbfc,inset 41px 0 0 #ececf0;box-shadow:inset 40px 0 0 #fbfbfc,inset 41px 0 0 #ececf0}ol.linenums{margin:0 0 0 33px}ol.linenums li{padding-left:12px;color:#bebec5;line-height:18px;text-shadow:0 1px 0 #fff} -------------------------------------------------------------------------------- /self-signed-certs.sh: -------------------------------------------------------------------------------- 1 | # Uncomment next line to create "privkey.pem" and "SSL_CA.pem" files 2 | openssl req -days 3650 -out SSL_CA.pem -new -x509 3 | # Save privkey.pem and SSL_CA.pem 4 | 5 | # General Public and private files 6 | openssl genrsa -out SSL_Priv.pem 1024 7 | openssl req -key SSL_Priv.pem -new -out ./cert.req 8 | echo 00 > file.srl 9 | openssl x509 -req -days 3650 -in cert.req -CA SSL_CA.pem -CAkey privkey.pem -CAserial file.srl -out SSL_Pub.pem 10 | 11 | # To convert to DER 12 | #openssl x509 -outform der -in SSL_CA.pem -out SSL_CA.der 13 | #openssl x509 -outform der -in SSL_Pub.pem -out SSL_Pub.der 14 | -------------------------------------------------------------------------------- /tinywrap/Msrp.i: -------------------------------------------------------------------------------- 1 | %{ 2 | #include "Msrp.h" 3 | %} 4 | 5 | /* Callbacks */ 6 | %feature("director") MsrpCallback; 7 | 8 | 9 | %nodefaultctor; 10 | %include "Msrp.h" 11 | %clearnodefaultctor; 12 | 13 | /* From tinyMSRP/tmsrp_message.h */ 14 | typedef enum tmsrp_request_type_e 15 | { 16 | tmsrp_NONE = 0, 17 | 18 | tmsrp_SEND, 19 | tmsrp_REPORT, 20 | tmsrp_AUTH 21 | //... 22 | } 23 | tmsrp_request_type_t; 24 | 25 | 26 | /* From tinyMSRP/tmsrp_event.h */ 27 | typedef enum tmsrp_event_type_e 28 | { 29 | tmsrp_event_type_none, 30 | tmsrp_event_type_connected, 31 | tmsrp_event_type_disconnected, 32 | tmsrp_event_type_message, 33 | } 34 | tmsrp_event_type_t; -------------------------------------------------------------------------------- /xcode/webrtc2sip.xcodeproj/xcuserdata/mamadou.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | webrtc2sip.xcscheme 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | SuppressBuildableAutocreation 14 | 15 | 15D271C61C0CF4E20031CB64 16 | 17 | primary 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /website/assets/js/bootstrap-alert.js: -------------------------------------------------------------------------------- 1 | !function(c){var b='[data-dismiss="alert"]',a=function(d){c(d).on("click",b,this.close)};a.prototype={constructor:a,close:function(i){var h=c(this),f=h.attr("data-target"),g;if(!f){f=h.attr("href");f=f&&f.replace(/.*(?=#[^\s]*$)/,"")}g=c(f);g.trigger("close");i&&i.preventDefault();g.length||(g=h.hasClass("alert")?h:h.parent());g.trigger("close").removeClass("in");function d(){g.trigger("closed").remove()}c.support.transition&&g.hasClass("fade")?g.on(c.support.transition.end,d):d()}};c.fn.alert=function(d){return this.each(function(){var f=c(this),e=f.data("alert");if(!e){f.data("alert",(e=new a(this)))}if(typeof d=="string"){e[d].call(f)}})};c.fn.alert.Constructor=a;c(function(){c("body").on("click.alert.data-api",b,a.prototype.close)})}(window.jQuery); -------------------------------------------------------------------------------- /website/assets/js/bootstrap-dropdown.js: -------------------------------------------------------------------------------- 1 | !function(d){var b='[data-toggle="dropdown"]',a=function(f){var e=d(f).on("click.dropdown.data-api",this.toggle);d("html").on("click.dropdown.data-api",function(){e.parent().removeClass("open")})};a.prototype={constructor:a,toggle:function(j){var i=d(this),f=i.attr("data-target"),h,g;if(!f){f=i.attr("href");f=f&&f.replace(/.*(?=#[^\s]*$)/,"")}h=d(f);h.length||(h=i.parent());g=h.hasClass("open");c();!g&&h.toggleClass("open");return false}};function c(){d(b).parent().removeClass("open")}d.fn.dropdown=function(e){return this.each(function(){var g=d(this),f=g.data("dropdown");if(!f){g.data("dropdown",(f=new a(this)))}if(typeof e=="string"){f[e].call(g)}})};d.fn.dropdown.Constructor=a;d(function(){d("html").on("click.dropdown.data-api",c);d("body").on("click.dropdown.data-api",b,a.prototype.toggle)})}(window.jQuery); -------------------------------------------------------------------------------- /tinywrap/SipCallback.cxx: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2010-2011 Mamadou Diop. 3 | * 4 | * Contact: Mamadou Diop 5 | * 6 | * This file is part of Open Source Doubango Framework. 7 | * 8 | * DOUBANGO is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as published by 10 | * the Free Software Foundation, either version 3 of the License, or 11 | * (at your option) any later version. 12 | * 13 | * DOUBANGO is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public License 19 | * along with DOUBANGO. 20 | * 21 | */ 22 | #include "SipCallback.h" 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /SSL_Priv.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN RSA PRIVATE KEY----- 2 | MIICXQIBAAKBgQDoamwwk2XO7zmBoot4SQ8Gq6wP504lolg3hITfW7Q2Eu+NpDLe 3 | ItM+NsnbbMn89Zbul1MYD+UIMBa+w5R7bBnFPD7bGqfsLAs5czxLranIEg0ri9L1 4 | gBHWKRCSSSWjXBvESB6jE1k28DV4/j7+q7Ka9W8bNDI1/eRVAs3m7v1WYwIDAQAB 5 | AoGAEa2upw8/KjtmG2c6xp6ABxjd0KPefNxZa3eoB7lY/tf34sU/nUf223+dYRRo 6 | VNZ1cZaPGoBzAmluAXqs+6pgV0w5RYBR9pbTahD+VwM1PTOjawl68Hc45y3h3PTz 7 | qYMWeLM34JTgndzOjgUF7FymEP2Ecu26FGzw7On4XU06X/ECQQD8rvu9gY53Bs0X 8 | qBOS0VDqc5qShYINxq+oi6+Jk7HTgL573eFxVeMzflHs0XJrc4d9kYv6k154rdE0 9 | BTuZfSeZAkEA63dW4r/RDyS7At6hgbHgpGjmOg+sv9G6kRqxnKs8upLravVuJM02 10 | mQDAe/2Tg4ywyX7xQD6l3CMpbhHi3mA7WwJAAq38X3MbRqnczO5sXrc3i3T0Y69k 11 | xK6huEDa+LOHRD3uRzQAKwqFIUuqpL9H3lnYSv2bJWogq1j0if+wNR19qQJBANBW 12 | HPgvg8gEVbsqRHg+bGbLsbh5mf12kb5FghT+pZLm34kZcsT5FW+27JhIOrbQSrNd 13 | sBOJ2rK2IbgT90mOl7UCQQC3UsS2SJt6cFLBWvjS5Q8ZEcGX/Jpe/pgKqtSHWSGR 14 | t3X69kDEe9lpounth65WSq6t76GwCRRWNnuQcCbwwv39 15 | -----END RSA PRIVATE KEY----- 16 | -------------------------------------------------------------------------------- /website/assets/js/bootstrap-button.js: -------------------------------------------------------------------------------- 1 | !function(b){var a=function(d,c){this.$element=b(d);this.options=b.extend({},b.fn.button.defaults,c)};a.prototype={constructor:a,setState:function(f){var h="disabled",c=this.$element,e=c.data(),g=c.is("input")?"val":"html";f=f+"Text";e.resetText||c.data("resetText",c[g]());c[g](e[f]||this.options[f]);setTimeout(function(){f=="loadingText"?c.addClass(h).attr(h,h):c.removeClass(h).removeAttr(h)},0)},toggle:function(){var c=this.$element.parent('[data-toggle="buttons-radio"]');c&&c.find(".active").removeClass("active");this.$element.toggleClass("active")}};b.fn.button=function(c){return this.each(function(){var f=b(this),e=f.data("button"),d=typeof c=="object"&&c;if(!e){f.data("button",(e=new a(this,d)))}if(c=="toggle"){e.toggle()}else{if(c){e.setState(c)}}})};b.fn.button.defaults={loadingText:"loading..."};b.fn.button.Constructor=a;b(function(){b("body").on("click.button.data-api","[data-toggle^=button]",function(d){var c=b(d.target);if(!c.hasClass("btn")){c=c.closest(".btn")}c.button("toggle")})})}(window.jQuery); -------------------------------------------------------------------------------- /website/assets/js/bootstrap-popover.js: -------------------------------------------------------------------------------- 1 | !function(b){var a=function(d,c){this.init("popover",d,c)};a.prototype=b.extend({},b.fn.tooltip.Constructor.prototype,{constructor:a,setContent:function(){var e=this.tip(),d=this.getTitle(),c=this.getContent();e.find(".popover-title")[b.type(d)=="object"?"append":"html"](d);e.find(".popover-content > *")[b.type(c)=="object"?"append":"html"](c);e.removeClass("fade top bottom left right in")},hasContent:function(){return this.getTitle()||this.getContent()},getContent:function(){var d,c=this.$element,e=this.options;d=c.attr("data-content")||(typeof e.content=="function"?e.content.call(c[0]):e.content);d=d.toString().replace(/(^\s*|\s*$)/,"");return d},tip:function(){if(!this.$tip){this.$tip=b(this.options.template)}return this.$tip}});b.fn.popover=function(c){return this.each(function(){var f=b(this),e=f.data("popover"),d=typeof c=="object"&&c;if(!e){f.data("popover",(e=new a(this,d)))}if(typeof c=="string"){e[c]()}})};b.fn.popover.Constructor=a;b.fn.popover.defaults=b.extend({},b.fn.tooltip.defaults,{placement:"right",content:"",template:'

'})}(window.jQuery); -------------------------------------------------------------------------------- /website/assets/js/bootstrap-tab.js: -------------------------------------------------------------------------------- 1 | !function(b){var a=function(c){this.element=b(c)};a.prototype={constructor:a,show:function(){var g=this.element,e=g.closest("ul:not(.dropdown-menu)"),d=g.attr("data-target"),f,c;if(!d){d=g.attr("href");d=d&&d.replace(/.*(?=#[^\s]*$)/,"")}if(g.parent("li").hasClass("active")){return}f=e.find(".active a").last()[0];g.trigger({type:"show",relatedTarget:f});c=b(d);this.activate(g.parent("li"),e);this.activate(c,c.parent(),function(){g.trigger({type:"shown",relatedTarget:f})})},activate:function(e,d,h){var c=d.find("> .active"),g=h&&b.support.transition&&c.hasClass("fade");function f(){c.removeClass("active").find("> .dropdown-menu > .active").removeClass("active");e.addClass("active");if(g){e[0].offsetWidth;e.addClass("in")}else{e.removeClass("fade")}if(e.parent(".dropdown-menu")){e.closest("li.dropdown").addClass("active")}h&&h()}g?c.one(b.support.transition.end,f):f();c.removeClass("in")}};b.fn.tab=function(c){return this.each(function(){var e=b(this),d=e.data("tab");if(!d){e.data("tab",(d=new a(this)))}if(typeof c=="string"){d[c]()}})};b.fn.tab.Constructor=a;b(function(){b("body").on("click.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(c){c.preventDefault();b(this).tab("show")})})}(window.jQuery); -------------------------------------------------------------------------------- /tinywrap/SafeObject.cxx: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2010-2011 Mamadou Diop. 3 | * 4 | * Contact: Mamadou Diop 5 | * 6 | * This file is part of Open Source Doubango Framework. 7 | * 8 | * DOUBANGO is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as published by 10 | * the Free Software Foundation, either version 3 of the License, or 11 | * (at your option) any later version. 12 | * 13 | * DOUBANGO is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public License 19 | * along with DOUBANGO. 20 | * 21 | */ 22 | #include "SafeObject.h" 23 | 24 | SafeObject::SafeObject() 25 | { 26 | this->mutex = tsk_mutex_create(); 27 | } 28 | 29 | int SafeObject::Lock()const 30 | { 31 | return tsk_mutex_lock(this->mutex); 32 | } 33 | 34 | int SafeObject::UnLock()const 35 | { 36 | return tsk_mutex_unlock(this->mutex); 37 | } 38 | 39 | SafeObject::~SafeObject() 40 | { 41 | tsk_mutex_destroy(&this->mutex); 42 | } 43 | -------------------------------------------------------------------------------- /SSL_Pub.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIDPjCCAiYCAQEwDQYJKoZIhvcNAQEFBQAwgaYxCzAJBgNVBAYTAkZSMRYwFAYD 3 | VQQIDA1JbGUtZGUtRnJhbmNlMQ4wDAYDVQQHDAVQYXJpczEeMBwGA1UECgwVRG91 4 | YmFuZ28gVGVsZWNvbSBFVVJMMQ0wCwYDVQQLDARWb0lQMR4wHAYDVQQDDBVEb3Vi 5 | YW5nbyBUZWxlY29tIEVVUkwxIDAeBgkqhkiG9w0BCQEWEWluZm9AZG91YmFuZ28u 6 | b3JnMB4XDTE1MDMwNDAxNTUxMloXDTI1MDMwMTAxNTUxMlowgaYxCzAJBgNVBAYT 7 | AkZSMRYwFAYDVQQIDA1JbGUtZGUtRnJhbmNlMQ4wDAYDVQQHDAVQYXJpczEWMBQG 8 | A1UECgwNRG91YmFuZ28gVGVzdDEdMBsGA1UECwwURG91YmFuZ28gVGVzdCAoVm9J 9 | UCkxFjAUBgNVBAMMDURvdWJhbmdvIFRlc3QxIDAeBgkqhkiG9w0BCQEWEWluZm9A 10 | ZG91YmFuZ28ub3JnMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDoamwwk2XO 11 | 7zmBoot4SQ8Gq6wP504lolg3hITfW7Q2Eu+NpDLeItM+NsnbbMn89Zbul1MYD+UI 12 | MBa+w5R7bBnFPD7bGqfsLAs5czxLranIEg0ri9L1gBHWKRCSSSWjXBvESB6jE1k2 13 | 8DV4/j7+q7Ka9W8bNDI1/eRVAs3m7v1WYwIDAQABMA0GCSqGSIb3DQEBBQUAA4IB 14 | AQCK2ovrf0MVFnhXw+EZHFuBrBjguLGxitlnTqDswSmJnnoVhllI6TWSTANX9Yhe 15 | dxx0Z7mlYTxZ6dFW9JLvISHG/9uJghQQLGEzM1ZVb5sK8HKKoQFRW7plY8IUQqtk 16 | Zzh/OZ/nOnUR8mSi2ms9CcQZHskXCppgPgpSlUV+TJpH5MqxF8iwFzgDd1N1Buxc 17 | YDWhkiGi3vwx/7rv1yCwxcvxENcecQVfaCJNMOLzUP4wI6tHhrwj8+A5yTKZ6vRM 18 | TFu7QIdd61GRnAhleNpc7Tc1K0XjdbB6o5BneM6KGb2Aa59btb1HaBS5z2HC6ZgC 19 | GW8ZYgRxU9o+YONxhaK6mlcn 20 | -----END CERTIFICATE----- 21 | -------------------------------------------------------------------------------- /tinywrap/SafeObject.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2010-2011 Mamadou Diop. 3 | * 4 | * Contact: Mamadou Diop 5 | * 6 | * This file is part of Open Source Doubango Framework. 7 | * 8 | * DOUBANGO is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as published by 10 | * the Free Software Foundation, either version 3 of the License, or 11 | * (at your option) any later version. 12 | * 13 | * DOUBANGO is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public License 19 | * along with DOUBANGO. 20 | * 21 | */ 22 | #ifndef TINYWRAP_SAFEOBJECT_H 23 | #define TINYWRAP_SAFEOBJECT_H 24 | 25 | #include "tinyWRAP_config.h" 26 | 27 | #include "tsk_mutex.h" 28 | 29 | class TINYWRAP_API SafeObject 30 | { 31 | public: 32 | SafeObject(); 33 | virtual ~SafeObject(); 34 | 35 | /* protected: */ 36 | int Lock()const; 37 | int UnLock()const; 38 | 39 | private: 40 | tsk_mutex_handle_t *mutex; 41 | }; 42 | 43 | #endif /* TINYWRAP_SAFEOBJECT_H */ 44 | -------------------------------------------------------------------------------- /mp_proxyplugin.cc: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2012-2015 Doubango Telecom 2 | * 3 | * This file is part of Open Source 'webrtc2sip' project 4 | * 5 | * 6 | * 'webrtc2sip' is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * 'webrtc2sip' is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with 'webrtc2sip'. 18 | */ 19 | #include "mp_proxyplugin.h" 20 | 21 | namespace webrtc2sip { 22 | 23 | MPProxyPlugin::MPProxyPlugin(MPMediaType_t eMediaType, uint64_t nId, const ProxyPlugin* pcProxyPlugin) 24 | : MPObject() 25 | { 26 | m_eMediaType = eMediaType; 27 | m_nId = nId; 28 | m_pcProxyPlugin = pcProxyPlugin; 29 | m_bValid = true; 30 | m_bStarted = false; 31 | m_bPaused = false; 32 | m_oMutex = MPMutex::New(); 33 | } 34 | 35 | 36 | MPProxyPlugin::~MPProxyPlugin() 37 | { 38 | m_pcProxyPlugin = NULL; 39 | } 40 | 41 | }//namespace -------------------------------------------------------------------------------- /mp_session.cc: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2012-2015 Doubango Telecom 2 | * 3 | * This file is part of Open Source 'webrtc2sip' project 4 | * 5 | * 6 | * 'webrtc2sip' is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * 'webrtc2sip' is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with 'webrtc2sip'. 18 | */ 19 | #include "mp_session.h" 20 | 21 | #include 22 | 23 | namespace webrtc2sip { 24 | 25 | MPSipSession::MPSipSession(SipSession** ppSipSessionToWrap) 26 | : m_eState(MPSessionState_None) 27 | { 28 | assert(ppSipSessionToWrap && *ppSipSessionToWrap); 29 | 30 | m_pWrappedSession = *ppSipSessionToWrap; 31 | *ppSipSessionToWrap = NULL; 32 | } 33 | 34 | MPSipSession::~MPSipSession() 35 | { 36 | if(m_pWrappedSession){ 37 | delete m_pWrappedSession, m_pWrappedSession = NULL; 38 | } 39 | 40 | TSK_DEBUG_INFO("MPSipSession object destroyed"); 41 | } 42 | 43 | 44 | } // namespace 45 | -------------------------------------------------------------------------------- /mp_object.cc: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2012-2015 Doubango Telecom 2 | * 3 | * This file is part of Open Source 'webrtc2sip' project 4 | * 5 | * 6 | * 'webrtc2sip' is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * 'webrtc2sip' is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with 'webrtc2sip'. 18 | */ 19 | #include "mp_object.h" 20 | 21 | namespace webrtc2sip { 22 | 23 | MPObject::MPObject() 24 | { 25 | m_nRefCount = 0; 26 | } 27 | 28 | MPObject::MPObject(const MPObject &) 29 | { 30 | m_nRefCount = 0; 31 | } 32 | 33 | MPObject::~MPObject() 34 | { 35 | 36 | } 37 | 38 | void MPObject::operator=(const MPObject &){ 39 | } 40 | 41 | int MPObject::takeRef() const{ 42 | // lock 43 | m_nRefCount++; 44 | // unlock 45 | return m_nRefCount; 46 | } 47 | 48 | int MPObject::releaseRef() const{ 49 | // lock 50 | if(m_nRefCount){ 51 | m_nRefCount--; 52 | } 53 | // unlock 54 | return m_nRefCount; 55 | } 56 | 57 | } // namespace -------------------------------------------------------------------------------- /mp_mutex.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2012-2015 Doubango Telecom 2 | * 3 | * This file is part of Open Source 'webrtc2sip' project 4 | * 5 | * 6 | * 'webrtc2sip' is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * 'webrtc2sip' is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with 'webrtc2sip'. 18 | */ 19 | #if !defined(_MEDIAPROXY_MUTEX_H_) 20 | #define _MEDIAPROXY_MUTEX_H_ 21 | 22 | #include "mp_config.h" 23 | #include "mp_object.h" 24 | #include "tsk_mutex.h" 25 | 26 | namespace webrtc2sip { 27 | 28 | class MPMutex : public MPObject 29 | { 30 | protected: 31 | MPMutex(bool bRecursive = true); 32 | public: 33 | virtual ~MPMutex(); 34 | virtual MP_INLINE const char* getObjectId() { return "MPMutex"; } 35 | bool lock(); 36 | bool unlock(); 37 | static MPObjectWrapper New(bool bRecursive = true); 38 | 39 | private: 40 | tsk_mutex_handle_t* m_phMPMutex; 41 | }; 42 | 43 | }// namespace 44 | #endif /* _MEDIAPROXY_MUTEX_H_ */ 45 | -------------------------------------------------------------------------------- /website/assets/js/bootstrap-scrollspy.js: -------------------------------------------------------------------------------- 1 | !function(b){function a(f,e){var g=b.proxy(this.process,this),c=b(f).is("body")?b(window):b(f),d;this.options=b.extend({},b.fn.scrollspy.defaults,e);this.$scrollElement=c.on("scroll.scroll.data-api",g);this.selector=(this.options.target||((d=b(f).attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""))||"")+" .nav li > a";this.$body=b("body").on("click.scroll.data-api",this.selector,g);this.refresh();this.process()}a.prototype={constructor:a,refresh:function(){this.targets=this.$body.find(this.selector).map(function(){var c=b(this).attr("href");return/^#\w/.test(c)&&b(c).length?c:null});this.offsets=b.map(this.targets,function(c){return b(c).position().top})},process:function(){var f=this.$scrollElement.scrollTop()+this.options.offset,e=this.offsets,c=this.targets,g=this.activeTarget,d;for(d=e.length;d--;){g!=c[d]&&f>=e[d]&&(!e[d+1]||f<=e[d+1])&&this.activate(c[d])}},activate:function(d){var c;this.activeTarget=d;this.$body.find(this.selector).parent(".active").removeClass("active");c=this.$body.find(this.selector+'[href="'+d+'"]').parent("li").addClass("active");if(c.parent(".dropdown-menu")){c.closest("li.dropdown").addClass("active")}}};b.fn.scrollspy=function(c){return this.each(function(){var f=b(this),e=f.data("scrollspy"),d=typeof c=="object"&&c;if(!e){f.data("scrollspy",(e=new a(this,d)))}if(typeof c=="string"){e[c]()}})};b.fn.scrollspy.Constructor=a;b.fn.scrollspy.defaults={offset:10};b(function(){b('[data-spy="scroll"]').each(function(){var c=b(this);c.scrollspy(c.data())})})}(window.jQuery); -------------------------------------------------------------------------------- /SSL_CA.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIEITCCAwmgAwIBAgIJAPItJ/nUv/rKMA0GCSqGSIb3DQEBBQUAMIGmMQswCQYD 3 | VQQGEwJGUjEWMBQGA1UECAwNSWxlLWRlLUZyYW5jZTEOMAwGA1UEBwwFUGFyaXMx 4 | HjAcBgNVBAoMFURvdWJhbmdvIFRlbGVjb20gRVVSTDENMAsGA1UECwwEVm9JUDEe 5 | MBwGA1UEAwwVRG91YmFuZ28gVGVsZWNvbSBFVVJMMSAwHgYJKoZIhvcNAQkBFhFp 6 | bmZvQGRvdWJhbmdvLm9yZzAeFw0xNTAzMDQwMTUwNDNaFw0yNTAzMDEwMTUwNDNa 7 | MIGmMQswCQYDVQQGEwJGUjEWMBQGA1UECAwNSWxlLWRlLUZyYW5jZTEOMAwGA1UE 8 | BwwFUGFyaXMxHjAcBgNVBAoMFURvdWJhbmdvIFRlbGVjb20gRVVSTDENMAsGA1UE 9 | CwwEVm9JUDEeMBwGA1UEAwwVRG91YmFuZ28gVGVsZWNvbSBFVVJMMSAwHgYJKoZI 10 | hvcNAQkBFhFpbmZvQGRvdWJhbmdvLm9yZzCCASIwDQYJKoZIhvcNAQEBBQADggEP 11 | ADCCAQoCggEBAKzwFx7dj50Zcyruel9wgLhVbNIDV7jmnYglUbydSjZ9TPOfM8Zp 12 | 7bT2rrIl6DK4tnnjdB9OOCRpSm8tOfPsUGSG3ivkheNU2P2lrdn7MM6L9kFiiyZQ 13 | n3ROlvoeyIA4MkoYDOwE26CmXqNQY8f/4eaKwRtaWdT1Iddv+vFAqWycoL0MD9vA 14 | PO7K2TKyVvzSIiGMCMCj2WHhW58871kwl517fMIB//8vqa8MqXRGzLJ/uHm7xHbJ 15 | NPJAac6JIjOZEI7GdLgPnNldE92VnralWokIc9GhZEkOxIIez4lf4XE2aYiGiVAi 16 | NAjrw0QMif+eV89z5B/k66RkjlkzCPPpxOMCAwEAAaNQME4wHQYDVR0OBBYEFHyh 17 | mn70KRaiZfDVFIP00JcDBZ9xMB8GA1UdIwQYMBaAFHyhmn70KRaiZfDVFIP00JcD 18 | BZ9xMAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEFBQADggEBAFjL3MRC/UIT6PfV 19 | 49DxZi06yyJMdcV+Q4eq63PScUIKO+MH2QvTd4Pxs6ZKPPfDVNZ5Wu8B/EvydIp6 20 | ohMKtEXbi6zJOVi11BZy8+DJYSLoHU45ZpmQM6tmbRWu9x4h87uuB3j9dQdewpk3 21 | z38t/CotfkOz/xW+bAnK0xcq+9ejt/RJK/HTj03W7TfE+Vg4DoXC/QDOFyda8c15 22 | 9kkXqnil7QlBo4Eh0dFlDuYTEHVJNTaBoYZXS38MlthPuvWnR8BSMmGpejIvT2R9 23 | cTDjQYenY2FSgRZQwhlFIVLSQh/2MSJmyDm+N2puUJvExTx0QYDzkGXMxZ5t5GWT 24 | PR+M1Yk= 25 | -----END CERTIFICATE----- 26 | -------------------------------------------------------------------------------- /mp_mutex.cc: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2012-2015 Doubango Telecom 2 | * 3 | * This file is part of Open Source 'webrtc2sip' project 4 | * 5 | * 6 | * 'webrtc2sip' is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * 'webrtc2sip' is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with 'webrtc2sip'. 18 | */ 19 | #include "mp_mutex.h" 20 | 21 | namespace webrtc2sip { 22 | 23 | MPMutex::MPMutex(bool bRecursive /*= true*/) 24 | { 25 | m_phMPMutex = tsk_mutex_create_2(bRecursive ? tsk_true : tsk_false); 26 | } 27 | 28 | MPMutex::~MPMutex() 29 | { 30 | if(m_phMPMutex){ 31 | tsk_mutex_destroy(&m_phMPMutex); 32 | } 33 | } 34 | 35 | bool MPMutex::lock() 36 | { 37 | return (tsk_mutex_lock(m_phMPMutex) == 0); 38 | } 39 | 40 | bool MPMutex::unlock() 41 | { 42 | return (tsk_mutex_unlock(m_phMPMutex) == 0); 43 | } 44 | 45 | MPObjectWrapper MPMutex::New(bool bRecursive /*= true*/) 46 | { 47 | MPObjectWrapper oMPMutex = new MPMutex(bRecursive); 48 | if(!oMPMutex->m_phMPMutex){ 49 | TSK_DEBUG_ERROR("Not wrapping valid mutex handle"); 50 | MPObjectSafeRelease(oMPMutex); 51 | } 52 | return oMPMutex; 53 | } 54 | 55 | }// namespace -------------------------------------------------------------------------------- /tinywrap/DDebug.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2010-2011 Mamadou Diop. 3 | * 4 | * Contact: Mamadou Diop 5 | * 6 | * This file is part of Open Source Doubango Framework. 7 | * 8 | * DOUBANGO is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as published by 10 | * the Free Software Foundation, either version 3 of the License, or 11 | * (at your option) any later version. 12 | * 13 | * DOUBANGO is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public License 19 | * along with DOUBANGO. 20 | * 21 | */ 22 | #ifndef TINYWRAP_SIP_DEBUG_H 23 | #define TINYWRAP_SIP_DEBUG_H 24 | 25 | class DDebugCallback 26 | { 27 | public: 28 | DDebugCallback() { } 29 | virtual ~DDebugCallback() {} 30 | 31 | 32 | virtual int OnDebugInfo(const char* message) { return -1; } 33 | virtual int OnDebugWarn(const char* message) { return -1; } 34 | virtual int OnDebugError(const char* message) { return -1; } 35 | virtual int OnDebugFatal(const char* message) { return -1; } 36 | 37 | #if !defined(SWIG) 38 | public: 39 | static int debug_info_cb(const void* arg, const char* fmt, ...); 40 | static int debug_warn_cb(const void* arg, const char* fmt, ...); 41 | static int debug_error_cb(const void* arg, const char* fmt, ...); 42 | static int debug_fatal_cb(const void* arg, const char* fmt, ...); 43 | #endif 44 | 45 | private: 46 | 47 | }; 48 | 49 | #endif /* TINYWRAP_SIP_DEBUG_H */ 50 | -------------------------------------------------------------------------------- /tinywrap/SipUri.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2010-2011 Mamadou Diop. 3 | * 4 | * Contact: Mamadou Diop 5 | * 6 | * This file is part of Open Source Doubango Framework. 7 | * 8 | * DOUBANGO is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as published by 10 | * the Free Software Foundation, either version 3 of the License, or 11 | * (at your option) any later version. 12 | * 13 | * DOUBANGO is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public License 19 | * along with DOUBANGO. 20 | * 21 | */ 22 | #ifndef TINYWRAP_SIPURI_H 23 | #define TINYWRAP_SIPURI_H 24 | 25 | #include "tinyWRAP_config.h" 26 | 27 | #include "tinysip.h" 28 | 29 | class TINYWRAP_API SipUri 30 | { 31 | public: 32 | SipUri(const char* uriString, const char* displayName=tsk_null); 33 | ~SipUri(); 34 | 35 | public: 36 | static bool isValid(const char*); 37 | 38 | bool isValid(); 39 | const char* getScheme(); 40 | const char* getHost(); 41 | unsigned short getPort(); 42 | const char* getUserName(); 43 | const char* getPassword(); 44 | const char* getDisplayName(); 45 | const char* getParamValue(const char* pname); 46 | void setDisplayName(const char* displayName); 47 | #if !defined(SWIG) 48 | inline const tsip_uri_t* getWrappedUri()const{ 49 | return m_pUri; 50 | } 51 | #endif 52 | 53 | private: 54 | tsip_uri_t* m_pUri; 55 | }; 56 | 57 | #endif /* TINYWRAP_SIPURI_H */ 58 | -------------------------------------------------------------------------------- /mp_session.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2012-2015 Doubango Telecom 2 | * 3 | * This file is part of Open Source 'webrtc2sip' project 4 | * 5 | * 6 | * 'webrtc2sip' is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * 'webrtc2sip' is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with 'webrtc2sip'. 18 | */ 19 | #if !defined(_MEDIAPROXY_SIPSESSION_H_) 20 | #define _MEDIAPROXY_SIPSESSION_H_ 21 | 22 | #include "mp_config.h" 23 | #include "mp_object.h" 24 | #include "mp_common.h" 25 | 26 | #include "SipSession.h" 27 | 28 | namespace webrtc2sip { 29 | 30 | class MPSipSession : public MPObject 31 | { 32 | public: 33 | MPSipSession(SipSession** ppSipSessionToWrap); 34 | virtual ~MPSipSession(); 35 | MP_INLINE virtual const char* getObjectId() { return "MPSipSession"; } 36 | MP_INLINE virtual const SipSession* getWrappedSession(){ return m_pWrappedSession; } 37 | MP_INLINE virtual void setState(MPSessionState_t eState) { m_eState = eState; } 38 | MP_INLINE virtual MPSessionState_t getState(){ return m_eState; } 39 | private: 40 | SipSession* m_pWrappedSession; 41 | MPSessionState_t m_eState; 42 | }; 43 | 44 | } // namespace 45 | 46 | #endif /* _MEDIAPROXY_SIPSESSION_H_ */ 47 | -------------------------------------------------------------------------------- /tinywrap/ActionConfig.h: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2010-2011 Mamadou Diop. 2 | * 3 | * This file is part of Open Source Doubango Framework. 4 | * 5 | * DOUBANGO is free software: you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation, either version 3 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * DOUBANGO is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with DOUBANGO. 17 | */ 18 | #ifndef TINYWRAP_ACTIONCONFIG_H 19 | #define TINYWRAP_ACTIONCONFIG_H 20 | 21 | #include "tinyWRAP_config.h" 22 | 23 | #include "tinysip.h" 24 | #include "Common.h" 25 | 26 | class TINYWRAP_API ActionConfig 27 | { 28 | public: 29 | ActionConfig(); 30 | virtual ~ActionConfig(); 31 | 32 | bool addHeader(const char* name, const char* value); 33 | bool addPayload(const void* payload, unsigned len); 34 | bool setActiveMedia(twrap_media_type_t type); 35 | 36 | ActionConfig* setResponseLine(short code, const char* phrase); 37 | ActionConfig* setMediaString(twrap_media_type_t type, const char* key, const char* value); 38 | ActionConfig* setMediaInt(twrap_media_type_t type, const char* key, int value); 39 | 40 | private: 41 | tsip_action_handle_t* m_pHandle; 42 | 43 | #if !defined(SWIG) 44 | public: 45 | const inline tsip_action_handle_t* getHandle()const{ 46 | return m_pHandle; 47 | } 48 | #endif 49 | }; 50 | 51 | 52 | #endif /* TINYWRAP_ACTIONCONFIG_H */ 53 | -------------------------------------------------------------------------------- /website/assets/js/bootstrap-collapse.js: -------------------------------------------------------------------------------- 1 | !function(a){var b=function(d,c){this.$element=a(d);this.options=a.extend({},a.fn.collapse.defaults,c);if(this.options.parent){this.$parent=a(this.options.parent)}this.options.toggle&&this.toggle()};b.prototype={constructor:b,dimension:function(){var c=this.$element.hasClass("width");return c?"width":"height"},show:function(){var f=this.dimension(),c=a.camelCase(["scroll",f].join("-")),e=this.$parent&&this.$parent.find(".in"),d;if(e&&e.length){d=e.data("collapse");e.collapse("hide");d||e.data("collapse",null)}this.$element[f](0);this.transition("addClass","show","shown");this.$element[f](this.$element[0][c])},hide:function(){var c=this.dimension();this.reset(this.$element[c]());this.transition("removeClass","hide","hidden");this.$element[c](0)},reset:function(c){var d=this.dimension();this.$element.removeClass("collapse")[d](c||"auto")[0].offsetWidth;this.$element[c?"addClass":"removeClass"]("collapse");return this},transition:function(g,d,e){var f=this,c=function(){if(d=="show"){f.reset()}f.$element.trigger(e)};this.$element.trigger(d)[g]("in");a.support.transition&&this.$element.hasClass("collapse")?this.$element.one(a.support.transition.end,c):c()},toggle:function(){this[this.$element.hasClass("in")?"hide":"show"]()}};a.fn.collapse=function(c){return this.each(function(){var f=a(this),e=f.data("collapse"),d=typeof c=="object"&&c;if(!e){f.data("collapse",(e=new b(this,d)))}if(typeof c=="string"){e[c]()}})};a.fn.collapse.defaults={toggle:true};a.fn.collapse.Constructor=b;a(function(){a("body").on("click.collapse.data-api","[data-toggle=collapse]",function(h){var g=a(this),c,f=g.attr("data-target")||h.preventDefault()||(c=g.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,""),d=a(f).data("collapse")?"toggle":g.data();a(f).collapse(d)})})}(window.jQuery); -------------------------------------------------------------------------------- /mp_peer.cc: -------------------------------------------------------------------------------- 1 | /* Copyright (C) 2012-2015 Doubango Telecom 2 | * 3 | * This file is part of Open Source 'webrtc2sip' project 4 | * 5 | * 6 | * 'webrtc2sip' is free software: you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation, either version 3 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * 'webrtc2sip' is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with 'webrtc2sip'. 18 | */ 19 | #include "mp_peer.h" 20 | 21 | #include 22 | 23 | namespace webrtc2sip { 24 | 25 | uint64_t g_nId = 0; 26 | 27 | MPPeer::MPPeer(MPObjectWrapper oCallSessionLeft) 28 | : m_nSessionIdLeft(0) 29 | , m_nSessionIdRight(0) 30 | , m_eSessionLeftState(MPPeerState_None) 31 | , m_eSessionRightState(MPPeerState_None) 32 | , m_nLastSipResponseLeft(0) 33 | , m_nLastSipResponseRight(0) 34 | , m_eMediaType(MPMediaType_None) 35 | { 36 | assert(*oCallSessionLeft); 37 | 38 | m_nId = ++g_nId; 39 | m_oCallSessionLeft = oCallSessionLeft; 40 | m_nSessionIdLeft = m_oCallSessionLeft->getWrappedSession()->getId(); 41 | } 42 | 43 | MPPeer::~MPPeer() 44 | { 45 | TSK_DEBUG_INFO("MPPeer object destroyed"); 46 | } 47 | 48 | void MPPeer::setCallSessionRight(MPObjectWrapper oCallSession) 49 | { 50 | assert(*oCallSession); 51 | 52 | m_oCallSessionRight = oCallSession; 53 | m_nSessionIdRight = m_oCallSessionRight->getWrappedSession()->getId(); 54 | } 55 | 56 | } // namespace -------------------------------------------------------------------------------- /tinywrap/tinyWRAP.i: -------------------------------------------------------------------------------- 1 | /* File : tinyWRAP.i */ 2 | %module(directors="1") tinyWRAP 3 | %include "typemaps.i" 4 | %include 5 | 6 | %{ 7 | #include "tinyWRAP_config.h" 8 | #include "DDebug.h" 9 | #include "AudioResampler.h" 10 | %} 11 | 12 | %feature("director") DDebugCallback; 13 | 14 | %nodefaultctor; 15 | %include "tinyWRAP_config.h" 16 | %include "DDebug.h" 17 | %include "AudioResampler.h" 18 | %include "Common.h" 19 | %clearnodefaultctor; 20 | 21 | 22 | 23 | 24 | 25 | /* ========== Sip/Sdp Stack ========== */ 26 | %newobject getSipHeaderValue; 27 | %newobject getSdpHeaderValue; 28 | %newobject getSdpHeaderAValue; 29 | %newobject getSipHeaderParamValue; 30 | %newobject SipStack::dnsENUM; 31 | %newobject SipStack::dnsNaptrSrv; 32 | %newobject SipStack::dnsSrv; 33 | %newobject SipStack::getPreferredIdentity; 34 | %newobject SipStack::getLocalIPnPort; 35 | %newobject MediaSessionMgr::producerGetCodec; 36 | 37 | %newobject MessagingEvent::takeSessionOwnership; 38 | %newobject InviteEvent::takeCallSessionOwnership; 39 | %newobject InviteEvent::takeMsrpSessionOwnership; 40 | %newobject RegistrationEvent::takeSessionOwnership; 41 | 42 | %newobject ProxyPluginMgr::createInstance; 43 | 44 | %newobject MediaContent::parse; 45 | 46 | %include SipStack.i 47 | 48 | 49 | /* ========== Xcap Stack ========== */ 50 | %newobject XcapSelector::getString; 51 | 52 | %newobject getXcapHeaderValue; 53 | %newobject getXcapHeaderParamValue; 54 | 55 | %include Xcap.i 56 | 57 | 58 | /* ========== SMS ========== */ 59 | %newobject SMSEncoder::encodeSubmit; 60 | %newobject SMSEncoder::encodeDeliver; 61 | %newobject SMSEncoder::encodeACK; 62 | %newobject SMSEncoder::encodeError; 63 | %newobject SMSEncoder::decode; 64 | 65 | %include SMS.i 66 | 67 | 68 | /* ========== MSRP ========== */ 69 | %newobject getMsrpHeaderValue; 70 | %newobject getMsrpHeaderParamValue; 71 | 72 | %include Msrp.i 73 | -------------------------------------------------------------------------------- /tinywrap/SipCallback.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2010-2011 Mamadou Diop. 3 | * 4 | * Contact: Mamadou Diop 5 | * 6 | * This file is part of Open Source Doubango Framework. 7 | * 8 | * DOUBANGO is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as published by 10 | * the Free Software Foundation, either version 3 of the License, or 11 | * (at your option) any later version. 12 | * 13 | * DOUBANGO is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public License 19 | * along with DOUBANGO. 20 | * 21 | */ 22 | #ifndef TINYWRAP_SIPCALLBACK_H 23 | #define TINYWRAP_SIPCALLBACK_H 24 | 25 | class DialogEvent; 26 | class StackEvent; 27 | 28 | class InviteEvent; 29 | class MessagingEvent; 30 | class InfoEvent; 31 | class OptionsEvent; 32 | class PublicationEvent; 33 | class RegistrationEvent; 34 | class SubscriptionEvent; 35 | 36 | class SipCallback 37 | { 38 | public: 39 | SipCallback() { } 40 | virtual ~SipCallback() {} 41 | virtual int OnDialogEvent(const DialogEvent* e) { return -1; } 42 | virtual int OnStackEvent(const StackEvent* e) { return -1; } 43 | 44 | virtual int OnInviteEvent(const InviteEvent* e) { return -1; } 45 | virtual int OnMessagingEvent(const MessagingEvent* e) { return -1; } 46 | virtual int OnInfoEvent(const InfoEvent* e) { return -1; } 47 | virtual int OnOptionsEvent(const OptionsEvent* e) { return -1; } 48 | virtual int OnPublicationEvent(const PublicationEvent* e) { return -1; } 49 | virtual int OnRegistrationEvent(const RegistrationEvent* e) { return -1; } 50 | virtual int OnSubscriptionEvent(const SubscriptionEvent* e) { return -1; } 51 | 52 | private: 53 | 54 | }; 55 | 56 | #endif /* TINYWRAP_SIPCALLBACK_H */ 57 | -------------------------------------------------------------------------------- /tinywrap/AudioResampler.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2010-2011 Mamadou Diop. 3 | * 4 | * Contact: Mamadou Diop 5 | * 6 | * This file is part of Open Source Doubango Framework. 7 | * 8 | * DOUBANGO is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as published by 10 | * the Free Software Foundation, either version 3 of the License, or 11 | * (at your option) any later version. 12 | * 13 | * DOUBANGO is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public License 19 | * along with DOUBANGO. 20 | * 21 | */ 22 | 23 | /**@file AudioResampler.h 24 | * @brief Audio resampler 25 | * 26 | * @author Mamadou Diop 27 | */ 28 | #ifndef TINYWRAP_AUDIO_RESAMPLER_H 29 | #define TINYWRAP_AUDIO_RESAMPLER_H 30 | 31 | #include "tinyWRAP_config.h" 32 | #include "tsk_common.h" 33 | 34 | class AudioResampler 35 | { 36 | public: 37 | AudioResampler(uint32_t nInFreq, uint32_t nOutFreq, uint32_t nFrameDuration, uint32_t nChannels, uint32_t nQuality); 38 | ~AudioResampler(); 39 | 40 | public: 41 | inline bool isValid(){ return (m_pWrappedResampler != tsk_null); } 42 | inline uint32_t getOutputRequiredSizeInShort(){ return (m_nOutFreq * m_nFrameDuration)/1000; } 43 | inline uint32_t getInputRequiredSizeInShort(){ return (m_nInFreq * m_nFrameDuration)/1000; } 44 | uint32_t process(const void* pInData, uint32_t nInSizeInBytes, void* pOutData, uint32_t nOutSizeInBytes); 45 | 46 | private: 47 | struct tmedia_resampler_s* m_pWrappedResampler; 48 | uint32_t m_nOutFreq; 49 | uint32_t m_nInFreq; 50 | uint32_t m_nFrameDuration; 51 | uint32_t m_nChannels; 52 | uint32_t m_nQuality; 53 | }; 54 | 55 | 56 | #endif /* TINYWRAP_AUDIO_RESAMPLER_H */ 57 | -------------------------------------------------------------------------------- /config.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ERROR 6 | 7 | udp;*;10060 8 | ws;*;10060 9 | wss;*;10062 10 | 11 | 12 | 13 | yes 14 | no 15 | no 16 | yes 17 | vga 18 | 65535 19 | 100;400 20 | optional 21 | sdes;dtls 22 | rfc4733 23 | 24 | opus;pcma;pcmu;gsm;vp8;h264-bp;h264-mp;h263;h263+ 25 | 48000;48000 26 | 27 | stun.l.google.com;19302;stun-user@doubango.org;stun-password 28 | yes 29 | 30 | -1 31 | 32 | 33 | 34 | 40 | 41 | 42 | 43 | c2c;*;10070 44 | c2cs;*;10072 45 | sqlite;* 46 | 47 | 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /Makefile.am: -------------------------------------------------------------------------------- 1 | sbin_PROGRAMS = webrtc2sip 2 | 3 | webrtc2sip_CPPFLAGS = \ 4 | ${TINYSAK_CFLAGS} \ 5 | ${TINYNET_CFLAGS} \ 6 | ${TINYHTTP_CFLAGS} \ 7 | ${TINYSIP_CFLAGS} \ 8 | ${TINYDAV_CFLAGS} \ 9 | ${TINYSDP_CFLAGS} \ 10 | ${TINYBFCP_CFLAGS} \ 11 | ${TINYSIGCOMP_CFLAGS} \ 12 | ${TINYMEDIA_CFLAGS} \ 13 | ${TINYXCAP_CFLAGS} \ 14 | ${TINYSMS_CFLAGS} \ 15 | ${TINYMSRP_CFLAGS} \ 16 | ${TINYRTP_CFLAGS} \ 17 | ${TINYIPSEC_CFLAGS} \ 18 | -I${LIBXML2_INCLUDE} \ 19 | -I${LIBPTHREAD_INCLUDE} \ 20 | -Itinywrap 21 | 22 | webrtc2sip_LDADD = \ 23 | -L${LIBXML2_LIB} \ 24 | -L${LIBPTHREAD_LIB} \ 25 | ${DOUBANGO_LIBS_FALLBACK} \ 26 | ${TINYSAK_LIBS} \ 27 | ${TINYNET_LIBS} \ 28 | ${TINYHTTP_LIBS} \ 29 | ${TINYSIP_LIBS} \ 30 | ${TINYDAV_LIBS} \ 31 | ${TINYSDP_LIBS} \ 32 | ${TINYBFCP_LIBS} \ 33 | ${TINYSIGCOMP_LIBS} \ 34 | ${TINYMEDIA_LIBS} \ 35 | ${TINYXCAP_LIBS} \ 36 | ${TINYSMS_LIBS} \ 37 | ${TINYMSRP_LIBS} \ 38 | ${TINYRTP_LIBS} \ 39 | ${TINYIPSEC_LIBS} \ 40 | -lxml2 \ 41 | -lpthread 42 | 43 | 44 | webrtc2sip_SOURCES = \ 45 | mp_c2c.cc\ 46 | mp_engine.cc\ 47 | mp_mail.cc\ 48 | mp_mediaproxy.cc\ 49 | mp_mutex.cc\ 50 | mp_net_transport.cc\ 51 | mp_object.cc\ 52 | mp_peer.cc\ 53 | mp_proxyplugin.cc\ 54 | mp_proxyplugin_consumer_audio.cc\ 55 | mp_proxyplugin_consumer_video.cc\ 56 | mp_proxyplugin_mgr.cc\ 57 | mp_proxyplugin_producer_audio.cc\ 58 | mp_proxyplugin_producer_video.cc\ 59 | mp_recaptcha.cc\ 60 | mp_session.cc\ 61 | mp_session_av.cc\ 62 | mp_wrap.cc 63 | 64 | webrtc2sip_SOURCES += \ 65 | db/sqlite/mp_db_sqlite.cc\ 66 | db/sqlite/sqlite3.c\ 67 | db/mp_db.cc\ 68 | db/mp_db_model.cc 69 | 70 | webrtc2sip_SOURCES += \ 71 | jsoncpp/jsoncpp.cc 72 | 73 | webrtc2sip_SOURCES += \ 74 | tinywrap/ActionConfig.cxx\ 75 | tinywrap/AudioResampler.cxx\ 76 | tinywrap/DDebug.cxx\ 77 | tinywrap/MediaContent.cxx\ 78 | tinywrap/MediaSessionMgr.cxx\ 79 | tinywrap/Msrp.cxx\ 80 | tinywrap/ProxyConsumer.cxx\ 81 | tinywrap/ProxyPluginMgr.cxx\ 82 | tinywrap/ProxyProducer.cxx\ 83 | tinywrap/SafeObject.cxx\ 84 | tinywrap/SipCallback.cxx\ 85 | tinywrap/SipEvent.cxx\ 86 | tinywrap/SipMessage.cxx\ 87 | tinywrap/SipSession.cxx\ 88 | tinywrap/SipStack.cxx\ 89 | tinywrap/SipUri.cxx\ 90 | tinywrap/SMSEncoder.cxx\ 91 | tinywrap/Xcap.cxx 92 | 93 | -------------------------------------------------------------------------------- /website/assets/js/bootstrap-carousel.js: -------------------------------------------------------------------------------- 1 | !function(a){var b=function(d,c){this.$element=a(d);this.options=a.extend({},a.fn.carousel.defaults,c);this.options.slide&&this.slide(this.options.slide);this.options.pause=="hover"&&this.$element.on("mouseenter",a.proxy(this.pause,this)).on("mouseleave",a.proxy(this.cycle,this))};b.prototype={cycle:function(){this.interval=setInterval(a.proxy(this.next,this),this.options.interval);return this},to:function(g){var c=this.$element.find(".active"),d=c.parent().children(),e=d.index(c),f=this;if(g>(d.length-1)||g<0){return}if(this.sliding){return this.$element.one("slid",function(){f.to(g)})}if(e==g){return this.pause().cycle()}return this.slide(g>e?"next":"prev",a(d[g]))},pause:function(){clearInterval(this.interval);this.interval=null;return this},next:function(){if(this.sliding){return}return this.slide("next")},prev:function(){if(this.sliding){return}return this.slide("prev")},slide:function(f,e){var c=this.$element.find(".active"),d=e||c[f](),j=this.interval,h=f=="next"?"left":"right",i=f=="next"?"first":"last",g=this;this.sliding=true;j&&this.pause();d=d.length?d:this.$element.find(".item")[i]();if(d.hasClass("active")){return}if(!a.support.transition&&this.$element.hasClass("slide")){this.$element.trigger("slide");c.removeClass("active");d.addClass("active");this.sliding=false;this.$element.trigger("slid")}else{d.addClass(f);d[0].offsetWidth;c.addClass(h);d.addClass(h);this.$element.trigger("slide");this.$element.one(a.support.transition.end,function(){d.removeClass([f,h].join(" ")).addClass("active");c.removeClass(["active",h].join(" "));g.sliding=false;setTimeout(function(){g.$element.trigger("slid")},0)})}j&&this.cycle();return this}};a.fn.carousel=function(c){return this.each(function(){var f=a(this),e=f.data("carousel"),d=typeof c=="object"&&c;if(!e){f.data("carousel",(e=new b(this,d)))}if(typeof c=="number"){e.to(c)}else{if(typeof c=="string"||(c=d.slide)){e[c]()}else{e.cycle()}}})};a.fn.carousel.defaults={interval:5000,pause:"hover"};a.fn.carousel.Constructor=b;a(function(){a("body").on("click.carousel.data-api","[data-slide]",function(h){var g=a(this),d,c=a(g.attr("data-target")||(d=g.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,"")),f=!c.data("modal")&&a.extend({},c.data(),g.data());c.carousel(f);h.preventDefault()})})}(window.jQuery); -------------------------------------------------------------------------------- /tinywrap/MediaContent.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2010-2011 Mamadou Diop. 3 | * 4 | * Contact: Mamadou Diop 5 | * 6 | * This file is part of Open Source Doubango Framework. 7 | * 8 | * DOUBANGO is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as published by 10 | * the Free Software Foundation, either version 3 of the License, or 11 | * (at your option) any later version. 12 | * 13 | * DOUBANGO is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public License 19 | * along with DOUBANGO. 20 | * 21 | */ 22 | #ifndef TINYWRAP_MEDIA_CONTENT_H 23 | #define TINYWRAP_MEDIA_CONTENT_H 24 | 25 | #include "tinymedia.h" 26 | #include "Common.h" 27 | 28 | class MediaContentCPIM; 29 | 30 | class MediaContent 31 | { 32 | public: 33 | #if !defined(SWIG) 34 | MediaContent(tmedia_content_t* content); 35 | #endif 36 | virtual ~MediaContent(); 37 | 38 | public: 39 | const char* getType(); 40 | virtual unsigned getDataLength(); 41 | virtual unsigned getData(void* pOutput, unsigned nMaxsize); 42 | 43 | // SWIG %newobject() 44 | static MediaContent* parse(const void* pData, unsigned nSize, const char* pType); 45 | static MediaContentCPIM* parse(const void* pData, unsigned nSize); 46 | 47 | virtual unsigned getPayloadLength() = 0; 48 | virtual unsigned getPayload(void* pOutput, unsigned nMaxsize) = 0; 49 | 50 | protected: 51 | tmedia_content_t* m_pContent; 52 | 53 | private: 54 | tsk_buffer_t* m_pData; 55 | }; 56 | 57 | 58 | /* ============ message/CPIM ================= */ 59 | class MediaContentCPIM : public MediaContent 60 | { 61 | public: 62 | #if !defined(SWIG) 63 | MediaContentCPIM(tmedia_content_t* pContent); 64 | #endif 65 | virtual ~MediaContentCPIM(); 66 | 67 | public: 68 | virtual unsigned getPayloadLength(); 69 | virtual unsigned getPayload(void* pOutput, unsigned nMaxsize); 70 | #if !defined(SWIG) 71 | const void* getPayloadPtr(); 72 | #endif 73 | const char* getHeaderValue(const char* pName); 74 | }; 75 | 76 | #endif /*TINYWRAP_MEDIA_CONTENT_H*/ 77 | -------------------------------------------------------------------------------- /tinywrap/tinyWRAP_config.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2010-2011 Mamadou Diop. 3 | * 4 | * Contact: Mamadou Diop 5 | * 6 | * This file is part of Open Source Doubango Framework. 7 | * 8 | * DOUBANGO is free software: you can redistribute it and/or modify 9 | * it under the terms of the GNU General Public License as published by 10 | * the Free Software Foundation, either version 3 of the License, or 11 | * (at your option) any later version. 12 | * 13 | * DOUBANGO is distributed in the hope that it will be useful, 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 | * GNU General Public License for more details. 17 | * 18 | * You should have received a copy of the GNU General Public License 19 | * along with DOUBANGO. 20 | * 21 | */ 22 | 23 | #ifndef TINYWRAP_CONFIG_H 24 | #define TINYWRAP_CONFIG_H 25 | 26 | #ifdef __SYMBIAN32__ 27 | #undef _WIN32 /* Because of WINSCW */ 28 | #endif 29 | 30 | // Windows (XP/Vista/7/CE and Windows Mobile) macro definition. 31 | #if defined(WIN32)|| defined(_WIN32) || defined(_WIN32_WCE) 32 | # define TWRAP_UNDER_WINDOWS 1 33 | # if defined(WINAPI_FAMILY) && (WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP || WINAPI_FAMILY == WINAPI_FAMILY_APP) 34 | # define TWRAP_UNDER_WINDOWS_RT 1 35 | # endif 36 | #endif 37 | 38 | #if (TWRAP_UNDER_WINDOWS || defined(__SYMBIAN32__)) && defined(TINYWRAP_EXPORTS) 39 | # define TINYWRAP_API __declspec(dllexport) 40 | # define TINYWRAP_GEXTERN extern __declspec(dllexport) 41 | #elif (TWRAP_UNDER_WINDOWS || defined(__SYMBIAN32__)) && !defined(TINYWRAP_IMPORTS_IGNORE) 42 | # define TINYWRAP_API __declspec(dllimport) 43 | # define TINYWRAP_GEXTERN __declspec(dllimport) 44 | #else 45 | # define TINYWRAP_API 46 | # define TINYWRAP_GEXTERN extern 47 | #endif 48 | 49 | /* Guards against C++ name mangling 50 | */ 51 | #ifdef __cplusplus 52 | # define TWRAP_BEGIN_DECLS extern "C" { 53 | # define TWRAP_END_DECLS } 54 | #else 55 | # define TWRAP_BEGIN_DECLS 56 | # define TWRAP_END_DECLS 57 | #endif 58 | 59 | /* Disable some well-known warnings 60 | */ 61 | #ifdef _MSC_VER 62 | # define _CRT_SECURE_NO_WARNINGS 63 | #endif 64 | 65 | #include 66 | 67 | 68 | #if HAVE_CONFIG_H 69 | #include "../config.h" 70 | #endif 71 | 72 | #endif // TINYWRAP_CONFIG_H 73 | -------------------------------------------------------------------------------- /website/assets/js/application.js: -------------------------------------------------------------------------------- 1 | !function(a){a(function(){a("section [href^=#]").click(function(j){j.preventDefault()});window.prettyPrint&&prettyPrint();a(".add-on :checkbox").on("click",function(){var j=a(this),k=j.attr("checked")?"addClass":"removeClass";a(this).parents(".add-on")[k]("active")});if(a(".twipsies a").length){a(window).on("load resize",function(){a(".twipsies a").each(function(){a(this).tooltip({placement:a(this).attr("title"),trigger:"manual"}).tooltip("show")})})}if(a("#grid-system").length){a("#grid-system").tooltip({selector:".show-grid > div",title:function(){return a(this).width()+"px"}})}var i=a(window),b=a(".subnav"),e=a(".subnav").length&&a(".subnav").offset().top-40,g=0;d();i.on("scroll",d);function d(){var j,k=i.scrollTop();if(k>=e&&!g){g=1;b.addClass("subnav-fixed")}else{if(k<=e&&g){g=0;b.removeClass("subnav-fixed")}}}a(".tooltip-demo.well").tooltip({selector:"a[rel=tooltip]"});a(".tooltip-test").tooltip();a(".popover-test").popover();a("a[rel=popover]").popover().click(function(j){j.preventDefault()});a("#fat-btn").click(function(){var j=a(this);j.button("loading");setTimeout(function(){j.button("reset")},3000)});a("#myCarousel").carousel();var c=a("#components.download input"),f=a("#plugins.download input"),h=a("#variables.download input");a("#components.download .toggle-all").on("click",function(j){j.preventDefault();c.attr("checked",!c.is(":checked"))});a("#plugins.download .toggle-all").on("click",function(j){j.preventDefault();f.attr("checked",!f.is(":checked"))});a("#variables.download .toggle-all").on("click",function(j){j.preventDefault();h.val("")});a(".download-btn").on("click",function(){var k=a("#components.download input:checked").map(function(){return this.value}).toArray(),m=a("#plugins.download input:checked").map(function(){return this.value}).toArray(),l={},j=["glyphicons-halflings.png","glyphicons-halflings-white.png"];a("#variables.download input").each(function(){a(this).val()&&(l[a(this).prev().text()]=a(this).val())});a.ajax({type:"POST",url:"http://bootstrap.herokuapp.com",dataType:"jsonpi",params:{js:m,css:k,vars:l,img:j}})})});a.ajaxTransport("jsonpi",function(d,e,c){var b=d.url;return{send:function(g,j){var f="jQuery_iframe_"+jQuery.now(),h,i;h=a("