FusionPBX and WebRTC Recommendations

Status
Not open for further replies.

InTeleSync

New Member
Feb 9, 2020
11
7
3
www.intelesync.com
It's 2020 and I'm sick of installing "apps" for my customers on desktops. What are some recommendations for a good quality WebRTC browser app with voice, chat, file sharing, video, presence, etc. for FusionPBX, paid or otherwise?
 
  • Like
Reactions: AratisPBX

AratisPBX

New Member
I second the motion.

WebRTC is getting better and we have reached out to a partner to see what we can build together on our FusionPBX server rather than on a seperate web-server (easier billing). Our journey has just begun so excuse my ignorance but here are some promising findings.

OnSIP has done a fantastic job with SIP.js which is basically a fork of JsSIP with more SIP compatibility, just what we need. They also provide some excellent developer docs that gave me some ideas.

https://www.onsip.com/voip-news/ons...ce-javascript-sip-stack-for-webrtc-developers
https://sipjs.com/guides/server-configuration/freeswitch/
https://developer.onsip.com/docs/guides/a-webrtc-button
https://developer.onsip.com/docs/guides/b-webrtc-phone

Another, SignalWire provides WebRTC to its SIP endoints using JsSIP however I would have to then relay calls in and out of Fusion via LAML bins and might get messy, kind of wanting to stay on box.

Please share.
 

ad5ou

Active Member
Jun 12, 2018
884
196
43
https://collecttix.github.io/ctxSip/
Link above has a demo of a working implementation of sip.js with basic phone capability.

Someone with more php/html/JavaScript knowledge than I have should be able to modify the existing code to pull sip credentials from Fusionpbx database allow tighter integration.
 

DigitalDaz

Administrator
Staff member
Sep 29, 2016
3,043
565
113
https://collecttix.github.io/ctxSip/
Link above has a demo of a working implementation of sip.js with basic phone capability.

Someone with more php/html/JavaScript knowledge than I have should be able to modify the existing code to pull sip credentials from Fusionpbx database allow tighter integration.

This has already been done by one of our members, he has made an app, he hasn't made it public yet as he didn't want to start fielding loads of questions. Who know, maybe he will read this post and share his repo :)

webphonefusion.png
 

ad5ou

Active Member
Jun 12, 2018
884
196
43
This has already been done by one of our members, he has made an app, he hasn't made it public yet as he didn't want to start fielding loads of questions. Who know, maybe he will read this post and share his repo :)

I’d be thrilled even if he dropped the code into a burner/anonymous account repository and let you as forum admin share the link.
 

wa4zlw

Member
Jun 7, 2019
131
2
18
69
Blandon, PA
www.myinternetsupport.com
Thanks @KonradSC I think I found that article. WE found this https://github.com/sippet/g729 but have decided right now to use opus/8000. What I have found is interesting and it follows through on hard phones or other soft phones.

Extension on PBX is forced to opus

1597341689105.png

1. my sip client (either zoiper or my grandstreams as well as the JS client we're developing) originating a call works as expected opus/8000 selected.
2. with an inbound call to my extension, the PBX doesn't seem to be offering opus/8000 to the client so if the client only has opus/8000, zoiper gets this error
Code:
Can't find matching codec in SDP (code: 2)
if the client has other codecs enabled, it will go to the next one (i.e. g.729).

Here is a zoiper log and comment from them:
Code:
Here is a different invite from the second(smaller) log called "logfile_2020-08-11_15-00-54.txt

received: INVITE sip:1522@70.44.10.180:65030;transport=TLS;rinstance=9523c47ca7247807 SIP/2.0
Via: SIP/2.0/TLS 206.189.77.7:5061;rport;branch=z9hG4bKy0Be2aHXX42Sj
Max-Forwards: 68
Route: <sip:1522@70.44.10.180:65030>;transport=TLS;rinstance=9523c47ca7247807
Contact: <sip:mod_sofia@206.189.77.7:5061;transport=tls>
To: <sip:1522@70.44.10.180:65030;transport=TLS;rinstance=9523c47ca7247807>
From: "BACKWOODS WIREL" <sip:4847658051@myis.pbxhostingnow.com>;tag=aSN78DU6a0vKQ
Call-ID: e8a07cde-56a7-1239-5cb5-124260aa133a
CSeq: 24032453 INVITE
Session-Expires: 120;refresher=uac
Min-SE: 120
Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REGISTER, REFER, NOTIFY, PUBLISH, SUBSCRIBE
Content-Disposition: session
Content-Type: application/sdp
Supported: timer, path, replaces
User-Agent: FreeSWITCH
Allow-Events: talk, hold, conference, presence, as-feature-event, dialog, line-seize, call-info, sla, include-session-description, presence.winfo, message-summary, refer
Remote-Party-ID: "BACKWOODS WIREL" <sip:4847658051@myis.pbxhostingnow.com>;party=calling;screen=yes;privacy=off
X-FS-Support: update_display,send_info
Content-Length: 625

v=0
o=FreeSWITCH 1597155126 1597155127 IN IP4 206.189.77.7
s=FreeSWITCH
c=IN IP4 206.189.77.7
t=0 0
m=audio 17364 RTP/AVP 0 18 8 3 101 13
a=rtpmap:0 PCMU/8000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=rtpmap:13 CN/8000
a=ptime:20
m=video 22002 RTP/AVP 102 103
b=AS:1024
a=rtpmap:102 H264/90000
a=rtpmap:103 VP8/90000
a=inactive
a=rtcp-fb:102 ccm fir
a=rtcp-fb:102 ccm tmmbr
a=rtcp-fb:102 nack
a=rtcp-fb:102 nack pli
a=rtcp-fb:103 ccm fir
a=rtcp-fb:103 ccm tmmbr
a=rtcp-fb:103 nack
a=rtcp-fb:103 nack pli


Again, I cannot see Opus being sent from the server, the invite again has "a=inactive" for media state.

Here's another log and their comments:

Code:
In the logs I can see the following INVITE coming from your server:

INVITE sip:1522@70.44.10.180:54512;transport=TLS;rinstance=54dcaf3a8bb7758c SIP/2.0
Via: SIP/2.0/TLS 206.189.77.7:5061;rport=5061;branch=z9hG4bKXyH6DvXFS7a3S
Max-Forwards: 68
Route: <sip:1522@70.44.10.180:54512>;transport=TLS;rinstance=54dcaf3a8bb7758c
Contact: <sip:mod_sofia@206.189.77.7:5061;transport=tls>
To: <sip:1522@70.44.10.180:54512;transport=TLS;rinstance=54dcaf3a8bb7758c>
From: "BACKWOODS WIREL" <sip:4847658051@myis.pbxhostingnow.com>;tag=FevDr37yrNK3p
Call-ID: 8c6c01ae-56a8-1239-5cb5-124260aa133a
CSeq: 24032590 INVITE
Session-Expires: 120;refresher=uac
Min-SE: 120
Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REGISTER, REFER, NOTIFY, PUBLISH, SUBSCRIBE
Content-Disposition: session
Content-Type: application/sdp
Supported: timer, path, replaces
User-Agent: FreeSWITCH
Allow-Events: talk, hold, conference, presence, as-feature-event, dialog, line-seize, call-info, sla, include-session-description, presence.winfo, message-summary, refer
Remote-Party-ID: "BACKWOODS WIREL" <sip:4847658051@myis.pbxhostingnow.com>;party=calling;screen=yes;privacy=off
X-FS-Support: update_display,send_info
Content-Length: 625

v=0
o=FreeSWITCH 1597153093 1597153094 IN IP4 206.189.77.7
s=FreeSWITCH
c=IN IP4 206.189.77.7
t=0 0
m=audio 19672 RTP/AVP 0 18 8 3 101 13
a=rtpmap:0 PCMU/8000
a=rtpmap:18 G729/8000
a=fmtp:18 annexb=no
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=rtpmap:13 CN/8000
a=ptime:20
m=video 32262 RTP/AVP 102 103
b=AS:1024
a=rtpmap:102 H264/90000
a=rtpmap:103 VP8/90000
a=inactive
a=rtcp-fb:102 ccm fir
a=rtcp-fb:102 ccm tmmbr
a=rtcp-fb:102 nack
a=rtcp-fb:102 nack pli
a=rtcp-fb:103 ccm fir
a=rtcp-fb:103 ccm tmmbr
a=rtcp-fb:103 nack
a=rtcp-fb:103 nack pli


As you can see on the INVITE above, OPUS is missing as media suggestion and actually the server is sending a video call for some reason with call state "On hold"

In this case there are few issues, if you have left only Opus on Zoiper as available codec, there is no codec to be matched since your server is not proposing Opus at all.

The second issue is that the call is being sent "On hold", which is not supported for initial INVITE in Zoiper. It can be sent as a re-INVITE, but not as initial invite.

I'm confused as to why the PBX is NOT offering opus on ringing the extension. What am I missing? I'd like to solve this so we can move forward.

Many thanks Leon
 
Status
Not open for further replies.