summary refs log tree commit diff
path: root/synapse/config
diff options
context:
space:
mode:
authorDavid Baker <dbkr@users.noreply.github.com>2017-01-19 14:28:31 +0000
committerGitHub <noreply@github.com>2017-01-19 14:28:31 +0000
commit691c8198b71354cd569d02ec6df2547b23667060 (patch)
tree782b8fe245e03f692fb6bb2aa279afebef03b53c /synapse/config
parentMerge pull request #1828 from matrix-org/erikj/iterable_cache_size (diff)
parentAdded default config for turn username and password (diff)
downloadsynapse-691c8198b71354cd569d02ec6df2547b23667060.tar.xz
Merge pull request #1832 from xsteadfastx/xsteadfastx/turn-username-password
Added username and password for turn server
Diffstat (limited to 'synapse/config')
-rw-r--r--synapse/config/voip.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/synapse/config/voip.py b/synapse/config/voip.py
index 169980f60d..eeb693027b 100644
--- a/synapse/config/voip.py
+++ b/synapse/config/voip.py
@@ -19,7 +19,9 @@ class VoipConfig(Config):
 
     def read_config(self, config):
         self.turn_uris = config.get("turn_uris", [])
-        self.turn_shared_secret = config["turn_shared_secret"]
+        self.turn_shared_secret = config.get("turn_shared_secret")
+        self.turn_username = config.get("turn_username")
+        self.turn_password = config.get("turn_password")
         self.turn_user_lifetime = self.parse_duration(config["turn_user_lifetime"])
 
     def default_config(self, **kwargs):
@@ -32,6 +34,11 @@ class VoipConfig(Config):
         # The shared secret used to compute passwords for the TURN server
         turn_shared_secret: "YOUR_SHARED_SECRET"
 
+        # The Username and password if the TURN server needs them and
+        # does not use a token
+        #turn_username: "TURNSERVER_USERNAME"
+        #turn_password: "TURNSERVER_PASSWORD"
+
         # How long generated TURN credentials last
         turn_user_lifetime: "1h"
         """