-
Notifications
You must be signed in to change notification settings - Fork 186
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
Error at OIDC initialization - restart in loop #17637
Comments
EDIT : I've tried with let's encrypt certificates and the issue is still present. |
I've modified the code to avoid raising a Commenting the line https://github.com/element-hq/synapse/blob/v1.114.0/synapse/http/client.py#L933 request_deferred.addErrback(_timeout_to_request_timed_out_error) And re-running the server allowed me to get the true error: twisted.web._newclient.ResponseNeverReceived: [<twisted.python.failure.Failure OpenSSL.SSL.Error: [('SSL routines', '', 'tlsv1 alert internal error')]>] Here are the ciphers offered by my IdP server (thanks this comment):
|
Can you confirm the length of the client secret ? |
The client secret is 32 hex chars long. |
Increase it to at least 128 chars long. |
My mistake, it was 64 chars long. Will try, thanks for the hint |
An EMS customer ran into this when their IdP went down. It would be useful is Synapse would start when unable to connect to the IdP, just with user authentication disabled. Not sure if it's easily doable, but maybe differentiate between when initially configuring OIDC vs. an OIDC config that has worked for a long time but the IdP is just down temporarily. Synapse OIDC config: oidc_config:
client_auth_method: client_secret_basic
client_id: redacted
client_secret: redacted
discover: true
enabled: true
idp_id: oidc
issuer: https://auth.their-idp.com:8443/...
scopes:
... redacted
skip_verification: false
user_mapping_provider:
config:
display_name_template: '{{ user.firstName }}'
localpart_template: '{{ user.name }}'
subject_template: '{{ user.sub }}' curl -vi https://auth.their-idp.com:8443
Their IdP is behind Cloudflare: https://developers.cloudflare.com/support/troubleshooting/cloudflare-errors/troubleshooting-cloudflare-5xx-errors/#error-522-connection-timed-out Synapse Logs
|
Description
I've configured my OIDC server (Authentik) for Synapse using the official guide.
My
homeserver.yml
is populated as this (the URL of the matrix server ismatrix.tld
):However, at the
docker compose up
, the synapse server restarts in loop because it can't initialize the provider. It seems it reaches a timeout, from the logs, although it doesn't even wait half a second and directly restarts.Here are the logs:
But I can browse to the Element homepage, and then when clicking on "Sign in", I get these log lines:
I have this page:
I don't know why is there a timeout. My OIDC server is using a self-signed certificate, but I've patched the Dockerfile to add the CA to the trusted store.
How could I further debug this ?
Thanks
Steps to reproduce
docker compose up
Homeserver
self-hosted, not federated
Synapse Version
1.113.0
Installation Method
Docker (matrixdotorg/synapse)
Database
PostgreSQL
Workers
Single process
Platform
Dockerized with docker compose.
Configuration
No response
Relevant log output
Anything else that would be useful to know?
No response
The text was updated successfully, but these errors were encountered: