Problem with WebRTC

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

Problem with WebRTC

Postby GBGS » Thu Jan 28, 2021 11:12 am

Hello,

We just installed Vicidial9 but we faced some issues when using the Webphones. We faced one way audio when making calls (the calling part couldn’t hear the other part but the other part could perfectly hear the calling part), and we got the error:

[Nov 19 18:13:11] ERROR[2240]: utils.c:1499 ast_careful_fwrite: fflush() returned error: Bad file descriptor
[Nov 19 18:13:11] ERROR[2240]: tcptls.c:488 tcptls_stream_close: SSL_shutdown() failed: error:00000005:lib(0):func(0):DH lib, Underlying BIO error: Bad file descriptor

We have activated NAT on firewall for both SIP and RTP ports.

We noticed that currently Vicidial9 is using chan_sip, we are wondering if it can use pjsip too?

Our installation was done using Vicibox, and cluster version of Vicidial composed of: Asterisk v.13.34.0-vici, Apache and MySql server.

These are my configurations:

/etc/asterisk/sip.conf

Code: Select all
transport=udp,ws,wss
avpf=yes
udpbindaddr=0.0.0.0:5060
rtcp_mux=yes
context=trunkinbound            ; Default context for incoming calls
allowguest=no                  ; Allow or reject guest calls (default is yes)
allowoverlap=no                 ; Disable overlap dialing support. (Default is yes)
;allowtransfer=no               ; Disable all transfers (unless enabled in peers or users)
realm=xxxxxx             ; Realm for digest authentication
bindport=5060                   ; UDP Port to bind to (SIP standard port is 5060)
bindaddr=0.0.0.0                ; IP address to bind to (0.0.0.0 binds to all)
srvlookup=yes                   ; Enable DNS SRV lookups on outbound calls
disallow=all                    ; First disallow all codecs
allow=opus
allow=ulaw                      ; Allow codecs in order of preference
allow=alaw
allow=gsm
mohinterpret=default
mohsuggest=default
nat=yes                         ; Global NAT settings  (Affects all peers and users)
externip = x.x.x.x.
localnet=y.y.y.y.y/255.255.255.0
canreinvite=no          ; Asterisk by default tries to redirect the



/etc/asterisk/http.conf

Code: Select all
[general]

enabled=yes

bindaddr=0.0.0.0

bindport=8088

tlsenable=yes          ; enable tls - default no.
tlsbindaddr=0.0.0.0:8089    ; address and port to bind to - default is bindaddr and port 8089.

tlscertfile=/etc/certbot/live/xxxx.xxxxx.com/cert.pem
tlsprivatekey=/etc/certbot/live/xxxxx.xxxx/privkey.pem


/etc/asterisk/./rtp.conf
Code: Select all
[general]

rtpstart=10000
rtpend=20000
icesupport=true
stunaddr=stun.l.google.com:19302


configuratons of Vicidial:

webRTC template

Code: Select all
type=friend
host=dynamic
encryption=yes
avpf=yes
icesupport=yes
directmedia=no
transport=ws,wss,udp,tls
force_avp=yes
dtlsenable=yes
dtlsverify=no
dtlscertfile=/etc/certbot/live/xxxx.xxxxx.com/cert.pem
dtlsprivatekey=/etc/certbot/live/xxxxx.xxxx/privkey.pem
dtlssetup=actpass
context=default
nat=force_rport,comedia
rtcp_mux=yes
disallow=all
allow=opus
allow=alaw
allow=ulaw
quality=yes


vicidial server asterisk config, set enable:

Web Socket URL:wss://xxxx.xxx:8089/ws

vicidial phones template are setting with webRTC
vicidial phones Set As Webphone = Y


Hopping for any suggestion/help from you
Thank you
GBGS
 
Posts: 2
Joined: Wed Jan 27, 2021 11:43 am

Re: Problem with WebRTC

Postby carpenox » Thu Jan 28, 2021 11:24 am

change nat=yes to nat=force_rport_comedia on sip.conf as well

Currently Vicidial doesnt support pjsip but that doesnt mean you cant use it within asterisk itself which i currently have 1 user on for testing purposes exploring options for uses on vicidial

Which version of a webphone are you using?
Alma Linux 9.3 | SVN Version: 3822 | DB Schema Version: 1711 | Asterisk 18.18.1
www.dialer.one -:- 1-833-DIALER-1 -:- https://linktr.ee/CyburDial -:- WhatsApp: +19549477572 -:- Skype: live:carpenox_3 | Discord: https://discord.gg/DVktk6smbh
carpenox
 
Posts: 2250
Joined: Wed Apr 08, 2020 2:02 am
Location: St Petersburg, FL

Re: Problem with WebRTC

Postby GBGS » Thu Jan 28, 2021 12:34 pm

Thank you for your reply.
We are going to configure Nat as you suggested, and do a test using a pjsip client connected directly to Asterisk.
About the Webphone, we are currently using Viciphone version 2.0 .
https://github.com/vicimikec/ViciPhone
GBGS
 
Posts: 2
Joined: Wed Jan 27, 2021 11:43 am

Re: Problem with WebRTC

Postby carpenox » Thu Jan 28, 2021 12:38 pm

That one I believe may still have some bugs with new ssl updates recently. Try this one or cabrera's

https://github.com/carpenox/CyburPhone
Alma Linux 9.3 | SVN Version: 3822 | DB Schema Version: 1711 | Asterisk 18.18.1
www.dialer.one -:- 1-833-DIALER-1 -:- https://linktr.ee/CyburDial -:- WhatsApp: +19549477572 -:- Skype: live:carpenox_3 | Discord: https://discord.gg/DVktk6smbh
carpenox
 
Posts: 2250
Joined: Wed Apr 08, 2020 2:02 am
Location: St Petersburg, FL


Return to Support

Who is online

Users browsing this forum: Google [Bot] and 131 guests