webrtccoturnrfc5766turnserver

Coturn not working with video calls with react client on android


Weird thing happening with our react app in its video call process. We have tested almost every option in /etc/turnserver.conf to find the problem and checked log several times. Our app works fine with paid turnservers such as metered but when trying to check our own packets succeed, no data is coming to our clients. TurnServer has been checked with trickle ice in advance and passes. Here is the config file and log file. Any help is appreciated.

Config :

min-port=10000
max-port=20000
fingerprint
user=USER:PASSWORD
lt-cred-mech
realm=OUR_DOMAIN
log-file=/var/log/turnserver/turnserver.log
verbose
external-ip=OUR_IP
cli-password=OUR_CLI_PASSWORD

Log:

: handle_udp_packet: New UDP endpoint: local addr OUR_IP:9127, remote addr PEER2:26679
3: session 000000000000000001: realm <OUR_DOMAIN> user <>: incoming packet BINDING processed, success
28: handle_udp_packet: New UDP endpoint: local addr OUR_IP:9127, remote addr PEER2:26682
28: handle_udp_packet: New UDP endpoint: local addr OUR_IP:9127, remote addr PEER2:26681
28: session 001000000000000001: realm <OUR_DOMAIN> user <>: incoming packet BINDING processed, success
28: session 000000000000000002: realm <OUR_DOMAIN> user <>: incoming packet BINDING processed, success
28: session 001000000000000001: realm <OUR_DOMAIN> user <>: incoming packet message processed, error 401: Unauthorized
28: session 000000000000000002: realm <OUR_DOMAIN> user <>: incoming packet message processed, error 401: Unauthorized
28: IPv4. Local relay addr: OUR_IP:19045
28: session 000000000000000002: new, realm=<OUR_DOMAIN>, username=<USER>, lifetime=600
28: session 000000000000000002: realm <OUR_DOMAIN> user <USER>: incoming packet ALLOCATE processed, success
28: IPv4. Local relay addr: OUR_IP:12749
28: session 001000000000000001: new, realm=<OUR_DOMAIN>, username=<USER>, lifetime=600
28: session 001000000000000001: realm <OUR_DOMAIN> user <USER>: incoming packet ALLOCATE processed, success
32: session 000000000000000002: refreshed, realm=<OUR_DOMAIN>, username=<USER>, lifetime=0
32: session 000000000000000002: realm <OUR_DOMAIN> user <USER>: incoming packet REFRESH processed, success
32: handle_udp_packet: New UDP endpoint: local addr OUR_IP:9127, remote addr PEER1:38872
32: session 001000000000000002: realm <OUR_DOMAIN> user <>: incoming packet message processed, error 401: Unauthorized
32: IPv4. Local relay addr: OUR_IP:11002
32: session 001000000000000002: new, realm=<OUR_DOMAIN>, username=<USER>, lifetime=600  
32: session 001000000000000002: realm <OUR_DOMAIN> user <USER>: incoming packet ALLOCATE processed, success
32: session 001000000000000002: realm <OUR_DOMAIN> user <USER>: incoming packet BINDING processed, success
32: session 001000000000000001: peer 21.202.221.104 lifetime updated: 300
32: session 001000000000000001: realm <OUR_DOMAIN> user <USER>: incoming packet CREATE_PERMISSION processed, success
32: session 001000000000000001: peer OUR_IP lifetime updated: 300
32: session 001000000000000001: realm <OUR_DOMAIN> user <USER>: incoming packet CREATE_PERMISSION processed, success
33: session 001000000000000001: peer PEER1 lifetime updated: 300
33: session 001000000000000001: realm <OUR_DOMAIN> user <USER>: incoming packet CREATE_PERMISSION processed, success
33: session 000000000000000002: closed (2nd stage), user <USER> realm <OUR_DOMAIN> origin <>, local OUR_IP:9127, remote PEER2:26682, reason: allocation timeout
42: session 001000000000000002: realm <OUR_DOMAIN> user <USER>: incoming packet BINDING processed, success
38: session 001000000000000001: realm <OUR_DOMAIN> user <USER>: incoming packet BINDING processed, success
48: session 001000000000000001: realm <OUR_DOMAIN> user <USER>: incoming packet BINDING processed, success
52: session 001000000000000002: realm <OUR_DOMAIN> user <USER>: incoming packet BINDING processed, success
59: session 001000000000000001: realm <OUR_DOMAIN> user <USER>: incoming packet BINDING processed, success

Solution

  • I found out that there is a bug in official release in ubuntu repositories. Built with source code and now it works as a charm!