summary refs log tree commit diff
diff options
context:
space:
mode:
authorTravis Ralston <travpc@gmail.com>2018-10-03 15:25:53 -0600
committerTravis Ralston <travpc@gmail.com>2018-10-03 15:57:42 -0600
commit149c4f176563bd8c976d9c4601825753f7292b12 (patch)
tree5b1c5f2d8a647063169ef596df869d22789bf697
parentIncorporate Dave's work for GDPR login flows (diff)
downloadsynapse-149c4f176563bd8c976d9c4601825753f7292b12.tar.xz
Supply params for terms auth stage
As per https://github.com/matrix-org/matrix-doc/pull/1692
-rw-r--r--synapse/handlers/auth.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/synapse/handlers/auth.py b/synapse/handlers/auth.py
index f08a2cdd7e..d6a19b74e9 100644
--- a/synapse/handlers/auth.py
+++ b/synapse/handlers/auth.py
@@ -466,6 +466,15 @@ class AuthHandler(BaseHandler):
     def _get_params_recaptcha(self):
         return {"public_key": self.hs.config.recaptcha_public_key}
 
+    def _get_params_terms(self):
+        return {
+            "policies": [{
+                "name": "Privacy Policy",
+                "version": self.hs.config.user_consent_version,
+                "url": "%s/_matrix/consent/public" % (self.hs.config.public_baseurl,),
+            }],
+        }
+
     def _auth_dict_for_flows(self, flows, session):
         public_flows = []
         for f in flows: