[go: nahoru, domu]

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

starttls upgrades don't appear to function correctly #110

Open
daikema opened this issue Nov 6, 2018 · 1 comment
Open

starttls upgrades don't appear to function correctly #110

daikema opened this issue Nov 6, 2018 · 1 comment

Comments

@daikema
Copy link
daikema commented Nov 6, 2018

I hit a similar error with JupyterHub with an LDAP server updated to require STARTTLS where the debug logs were showing the following errors:

LDAPBindError: automatic bind not successful - confidentialityRequired

i.e. connections don't seem to be getting upgrading properly in the latest release:

Note that if I update the following line in ldapauthenticator.py

auto_bind=self.use_ssl and ldap3.AUTO_BIND_TLS_BEFORE_BIND or ldap3.AUTO_BIND_NO_TLS

to

auto_bind=ldap3.AUTO_BIND_TLS_BEFORE_BIND

the problem disappears. Without this modification based on a look at the LDAP3 source it seems to me as though the connection will never recieve the starttls upgrade that the docs mention should happen with the current auto_bind setting.

use_ssl appears to be used for both creating a Server object (which triggers a connection attempt to port 636 which isn't open in my case) and for evaluating whether or not to do a starttls upgrade. Is there a need for an additional configuration option to disambiguate these?

(It's unclear me whether or not this might be the root problem underlying #90).

It seems there's been a cosmetic change to the auto_bind formatting since the 1.2.2 release but it doesn't look to me like the underlying issue has been eliminated.

@dhirschfeld
Copy link
Collaborator

Thanks for the report - I'll try to take a look in the next several days.

From your description it sounds like we may indeed need a new config option...

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

2 participants