Add user-connection and proper connection teardowns
If LDAP_SERVICE_BIND_DN is empty, use the current users credentials for all LDAP actions.
The user_password is stored in the cookie for that reason.
Also, ensure teardown of all opened LDAP connection afterwards
Merge request reports
Activity
added 1 commit
- ca40cd31 - since we only check on hasattr(request, ldap_connection), we must not
added 1 commit
- 8f54d50c - when using connect_and_bind_to_ldap directly, handle the LDAPBINDError
- Resolved by sistason
- Resolved by sistason
- Resolved by sistason
How does this interact with other functionality? I guess signup and invite won't work at all. Maybe they should be disabled somehow if LDAP_SERVICE_BIND_DN empty (e.g. by not adding the blueprints to the app in
uffd/__init__.py
). I can also imagine that some other things subtly break.I generally think there should be a list of features that we support with user-connections enabled and that are also covered by our test-suite in this configuration. The OpenLDAP tests should be relatively easy to adapt.
added 1 commit
- 0de9e6e5 - cosmetics and reorganized imports more efficiently
added 1 commit
- a363d4a1 - started with unittests, but stuck on a mock issue