Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The project lacks documentation for implementing identity server in real life #29

Closed
sander85 opened this issue Nov 27, 2016 · 6 comments

Comments

@sander85
Copy link

I started the server with python -m sydent.sydent - everything seems to work but there is no info how I should configure web client or Android app to use the identity server.

Currently synapse gives this error:

2016-11-27 16:57:30,814 - synapse.http.server - 139 - ERROR - POST-53- Failed handle request synapse.http.server._async_render on <synapse.rest.ClientRestResource object at 0x7f5694cc1f90>: <SynapseRequest at 0x7f568ddf1518 method=POST uri=/_matrix/client/r0/account/3pid/email/requestToken clientproto=HTTP/1.1 site=8448>
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/synapse/http/server.py", line 116, in wrapped_request_handler
    yield request_handler(self, request, request_metrics)
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1126, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 389, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/usr/lib/python2.7/dist-packages/synapse/http/server.py", line 255, in _async_render
    callback_return = yield callback(request, **kwargs)
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1126, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 389, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/usr/lib/python2.7/dist-packages/synapse/rest/client/v2_alpha/account.py", line 195, in on_POST
    ret = yield self.identity_handler.requestEmailToken(**body)
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1126, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 389, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/usr/lib/python2.7/dist-packages/synapse/handlers/identity.py", line 158, in requestEmailToken
    params
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1128, in _inlineCallbacks
    result = g.send(result)
  File "/usr/lib/python2.7/dist-packages/synapse/http/client.py", line 128, in post_urlencoded_get_json
    defer.returnValue(json.loads(body))
  File "/usr/lib/python2.7/dist-packages/simplejson/__init__.py", line 505, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python2.7/dist-packages/simplejson/decoder.py", line 370, in decode
    obj, end = self.raw_decode(s)
  File "/usr/lib/python2.7/dist-packages/simplejson/decoder.py", line 400, in raw_decode
    return self.scan_once(s, idx=_w(s, idx).end())
JSONDecodeError: Expecting value: line 2 column 1 (char 1)

Should I specify port (8090) too or will the server detect itself? If the port is specified in web client then it starts to spin but there is no response nor anything interesting in the logs. Really no idea what I'm missing here..

@ara4n
Copy link
Member

ara4n commented Jan 22, 2017

@dbkr enough people are trying to run their own sydents that we should write a basic README sometime soon.

@ara4n ara4n closed this as completed Jan 22, 2017
@ara4n ara4n reopened this Jan 22, 2017
@maxidorius
Copy link

maxidorius commented Jan 23, 2017

@sander85 We have created a read-only identity server backed by a LDAP server (more to come), in case that would fit your use: https://github.com/kamax-io/mxisd

@richvdh
Copy link
Member

richvdh commented Mar 14, 2019

we have a readme?

@richvdh richvdh closed this as completed Mar 14, 2019
@menturion
Copy link

I am missing the responses to the listed requests. Could you please add examples to the documentation.

For instance, how does the (JSON) response of the identity server upon a lookup request look like ...

Request:
curl 'http://localhost:8090/_matrix/identity/api/v1/lookup?medium=email&address=henry%40matrix.org'

Response:
{
???
}

Many thanks in advance.

@menturion
Copy link

@t3chguy Many thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants