summary refs log tree commit diff
path: root/synapse/handlers/login.py
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/handlers/login.py')
-rw-r--r--synapse/handlers/login.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/synapse/handlers/login.py b/synapse/handlers/login.py
index 1204dc3b8f..979086a3d6 100644
--- a/synapse/handlers/login.py
+++ b/synapse/handlers/login.py
@@ -99,8 +99,12 @@ class LoginHandler(BaseHandler):
     def _query_email(self, email):
         httpCli = SimpleHttpClient(self.hs)
         data = yield httpCli.get_json(
-            'matrix.org:8090',  # TODO FIXME This should be configurable.
-            "/_matrix/identity/api/v1/lookup?medium=email&address=" +
-            "%s" % urllib.quote(email)
+            # TODO FIXME This should be configurable.
+            # XXX: ID servers need to use HTTPS
+            "http://%s%s" % ("matrix.org:8090", "/_matrix/identity/api/v1/lookup"),
+            {
+                'medium': 'email',
+                'address': email
+            }
         )
         defer.returnValue(data)