LDAP sync fails on first login afer configuring LDAP #27

Closed
opened 2021-05-31 12:36:24 +02:00 by nik · 5 comments
nik commented 2021-05-31 12:36:24 +02:00 (Migrated from edugit.org)

On first login after configuring LDAP authentication, LDAP sync for the person fails:

  File "/usr/local/lib/python3.9/dist-packages/aleksis/apps/ldap/util/ldap_sync.py", line 206, in ldap_sync_user_on_login
    person = ldap_sync_from_user(user, ldap_user.dn, ldap_user.attrs.data)
  File "/usr/lib/python3.9/contextlib.py", line 79, in inner
    return func(*args, **kwds)
  File "/usr/local/lib/python3.9/dist-packages/aleksis/apps/ldap/util/ldap_sync.py", line 263, in ldap_sync_from_user
    raise KeyError(f"No matching fields found for {dn}")

Firstly, LDAP synchronisaiton should not be enabled by default. Secondly, it should fail gracefully, and tell what is going wrong.

On first login after configuring LDAP authentication, LDAP sync for the person fails: ```plain File "/usr/local/lib/python3.9/dist-packages/aleksis/apps/ldap/util/ldap_sync.py", line 206, in ldap_sync_user_on_login person = ldap_sync_from_user(user, ldap_user.dn, ldap_user.attrs.data) File "/usr/lib/python3.9/contextlib.py", line 79, in inner return func(*args, **kwds) File "/usr/local/lib/python3.9/dist-packages/aleksis/apps/ldap/util/ldap_sync.py", line 263, in ldap_sync_from_user raise KeyError(f"No matching fields found for {dn}") ``` Firstly, LDAP synchronisaiton should not be enabled by default. Secondly, it should fail gracefully, and tell what is going wrong.
nik commented 2021-06-04 16:37:04 +02:00 (Migrated from edugit.org)

assigned to @nik

assigned to @nik
nik commented 2021-06-04 16:37:07 +02:00 (Migrated from edugit.org)

changed due date to June 11, 2021

changed due date to June 11, 2021
nik commented 2021-06-18 15:52:46 +02:00 (Migrated from edugit.org)

created merge request !131 to address this issue

created merge request !131 to address this issue
nik commented 2021-06-18 15:52:47 +02:00 (Migrated from edugit.org)

mentioned in merge request !131

mentioned in merge request !131
hansegucker commented 2021-06-19 10:18:50 +02:00 (Migrated from edugit.org)

mentioned in commit d622b7ba2c

mentioned in commit d622b7ba2c4c6a36cd94f2954715bd705eb07168
hansegucker (Migrated from edugit.org) closed this issue 2021-06-19 10:18:51 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
aleksis/AlekSIS-App-LDAP#27
No description provided.