Testing and configuring Nextcloud Talk


(sb) #1

NethServer Version: NethServer release 7.4.1708 (Final)

Hi community,

I wonder if someone tested and/or configured Nextcloud Talk.

On my tests on Nextcloud 13 only works partially on the same lan. Should we install and configure stun/turn server manually?

Beyond that the the screensharing functions does not work.

Thanks in advance!

(Marc) #2

I think the firewall is blocking webrtc or the connection form the stun server.
@alep @alefattorini, any advice? did you try Nextcloud Talk from public network?

Screensharing is supposed to work natively from Firefox 52+. On Chrome an extension is required.

(Alessio Fattorini) #3

Yes. And it doesn’t work, local network only. @alep gonna make some tests

(Alessandro Polidori) #4

Me too have done only local tests, sorry.
I hope to try it on the public.

(sb) #5

FYI Now it’s working on NC 13!

(Michael Träumner) #6

Please tell us how you get it working and mark it as solved please.

(Marc) #7

Today I’ve tried to configure it with a TURN server.

Download and install a TURN server (here we use coturn).

wget http://coturn.net/turnserver/v4.5.0.7/turnserver-    # check coturn's release page for latest version
tar xvfz turnserver-
cd turnserver-
chmod +x install.sh

Prepare some information to configure coturn:

openssl rand -hex 32  # generate an static-auth-secret; example: de187fd1cefc7cd6dade0eee65dfc3c242affe6027574597344be43c467a54ef
config show pki       # get certificate information, otherwise consider generating a specific certificate for turnserver.

Edit turnserver configuration, uncommenting the following settings (not all of them are required):

vi /etc/turnserver/turnserver.conf
# port for plain connection (no TLS)

# TURN listener port for TLS

# Uncomment to use fingerprints in the TURN messages

# Uncomment to use long-term credential mechanism.
# By default no credentials mechanism is used (any user allowed).
# If lt-cred-mech and user-auth-secret are used at the same time, the latter will override the former.

# TURN REST API flag for secret-based authentication
# This feature can be used with the long-term authentication mechanism, only.
# secret defined either by static-auth-secret, or found in the turn_secret table in the database

# 'Static' authentication secret value (a string) for TURN REST API only.
# If not set, then the turn server will try to use the 'dynamic' value in turn_secret table
# The database-stored value can be changed on-the-fly by a separate program.

#The default realm to be used for the users when no explicit origin/realm
#relationship was found in the database. Must be used with long-term
#credentials mechanism or with TURN REST API.

# Total allocation quota.

# Maximum server capacity.
# Total bytes-per-second bandwidth the TURN server is allowed to allocate for the sessions

# Uncomment if extra security is desired

# Certificate file (for TLS)

# Private key file (for TLS)

# Allowed OpenSSL cipher list for TLS/DTLS connections
# (optional) tweak as you need

# prevent stdout log messages (uncommented by default)

# (optional) set the log file name
# warning: set proper file permissions for turnserver

# redirect all log output into system log (uncommented by default)

# no log file rollover will be used, and the log file name
# will be constructed as-is, without PID and date appendage.
# This option can be used, for example, together with the logrotate tool.

# disallow peers on the loopback addresses

# disallow peers on well-known broadcast addresses

# File name to store the pid of the process. (uncommented by default)

# Turn OFF the CLI support.
# By default it is always ON.
# (optional)

# (optional) Do not allow an TLS/DTLS version of protocol

Open port(s) for turnserver (and forward them if necessary):

config set fw_turnserver service status enabled TCPPort 5349 UDPPort 5349 access public
signal-event firewall-adjust

Start and enable turnserver service:

systemctl enable --now turnserver

Configure Nextcloud Talk:

  • STUN servers: server.domain.tld:5349
  • TURN server: server.domain.tld:5349
  • TURN secret: YOUR_SECRET
  • UDP and TCP

When using TLS, make sure the certificate and private key have the right file permissions for turnserver user.
It’s easier to start without TLS to check it is working. Then change to TLS and troubleshoot if problems arise.


WebRTC uses long-term authentication mechanism, so you have to use -a option (or
–lt-cred-mech). WebRTC relaying will not work with anonymous access. With -a option, do
not forget to set the default realm (-r option). You will also have to set up the user
accounts, for that you have a number of options:

        a) command-line options (-u).
        b) a database table (SQLite or PostgreSQL or MySQL or MongoDB)
        c) Redis key/value pair(s)
        d) You also can use the TURN REST API. You will need shared secret(s)

Assorted things for your consideration:

  • Can this interfere with FreePBX (does it have a similar feature)?
  • Try if calls are sustained for long time (>30 minutes)
  • Try it through VPN
  • Try internal/external calls
  • Integation with NethServer: make nethserver-coturn package?
  • Security considerations?
  • turnadmin interface?

(sb) #8

Take a look at https://help.nextcloud.com/t/nextcloud-talk-not-working-with-symmetric-nat/30027