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

Cannot login with ldap auth #187

Closed
paddex opened this issue Dec 5, 2023 · 4 comments
Closed

Cannot login with ldap auth #187

paddex opened this issue Dec 5, 2023 · 4 comments

Comments

@paddex
Copy link

paddex commented Dec 5, 2023

Hello,
we cannot use ldap auth anymore. It used to work and already existing accounts still can login. When trying to login with a new account though we get an error message.

These are the logs synapse produces:

2023-12-05 12:56:45,855 - synapse.rest.client.login - 333 - INFO - POST-1 - Got login request with identifier: {'type': 'm.id.user', 'user': '<user_redacted>'}, medium: None, address: None, user: None
2023-12-05 12:56:45,895 - ldap_auth_provider - 178 - INFO - sentinel - User authenticated against LDAP server: ldap://10.14.71.248:389 - cleartext - user: <dn_redacted> - not lazy - bound - open - <local: 10.14.71.9:52901 - remote: 10.14.71.248:389> - tls started - listening - SyncStrategy - internal decoder
2023-12-05 12:56:45,896 - synapse.storage.database - 907 - WARNING - sentinel - Starting db txn 'get_users_by_id_case_insensitive' from sentinel context
2023-12-05 12:56:45,896 - synapse.storage.database - 973 - WARNING - sentinel - Starting db connection from sentinel context: metrics will be lost
2023-12-05 12:56:45,899 - synapse.handlers.auth - 1071 - WARNING - sentinel - Attempted to login as @<user_redacted>:<url_redacted> but they do not exist
2023-12-05 12:56:45,899 - synapse.storage.database - 907 - WARNING - sentinel - Starting db txn 'get_users_by_id_case_insensitive' from sentinel context
2023-12-05 12:56:45,900 - synapse.storage.database - 973 - WARNING - sentinel - Starting db connection from sentinel context: metrics will be lost
2023-12-05 12:56:45,902 - synapse.handlers.auth - 1071 - WARNING - sentinel - Attempted to login as @<user_redacted>:<url_redacted> but they do not exist
2023-12-05 12:56:45,902 - synapse.handlers.auth - 2164 - WARNING - sentinel - Failed to run module API callback <bound method LdapAuthProviderModule.wrapped_check_auth of <ldap_auth_provider.LdapAuthProviderModule object at 0x7f19c551db50>>: Invalid version: '1.97.0 (b=master,63c471d)'
2023-12-05 12:56:45,903 - synapse.storage.database - 907 - WARNING - sentinel - Starting db txn 'get_users_by_id_case_insensitive' from sentinel context
2023-12-05 12:56:45,903 - synapse.storage.database - 973 - WARNING - sentinel - Starting db connection from sentinel context: metrics will be lost
2023-12-05 12:56:45,906 - synapse.handlers.auth - 1071 - WARNING - sentinel - Attempted to login as @<user_redacted>:<url_redacted> but they do not exist
2023-12-05 12:56:45,906 - synapse.http.server - 124 - INFO - sentinel - <XForwardedForRequest at 0x7f19c5533f10 method='POST' uri='/_matrix/client/v3/login' clientproto='HTTP/1.0' site='8008'> SynapseError: 403 - Invalid username or password
@DMRobertson
Copy link
Contributor

The relevant source in current Synapse is https://github.com/matrix-org/synapse/blob/63d96bfc61fcbf53e9607c63f215d2dde387de29/synapse/handlers/auth.py#L1057-L1072

Can you confirm what version of Synapse and the LDAP plugin you're using, and how they're installed?

@paddex
Copy link
Author

paddex commented Dec 5, 2023

We are using the latest packages from pip.

$: pip list
[...]
matrix-common             1.3.0
matrix-synapse            1.97.0
matrix-synapse-ldap3      0.3.0
[...]

@erikjohnston
Copy link
Member

@paddex can you give us the config you are using please?

@reivilibre
Copy link
Contributor

There doesn't seem to be enough information here in order to reproduce or fix this issue right now.

I will close this issue but it can be reopened (or a new issue, linking to this one, opened) if the issue recurs with more information available.

Thank you.

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

No branches or pull requests

4 participants