Skip to content
This repository has been archived by the owner on Mar 29, 2024. It is now read-only.

KeyError: 'sAMAccountName' #110

Open
bsysmitch opened this issue Oct 19, 2023 · 0 comments
Open

KeyError: 'sAMAccountName' #110

bsysmitch opened this issue Oct 19, 2023 · 0 comments

Comments

@bsysmitch
Copy link

Everything seems to be working with this project save for the creation of users.

Here is my debug output when I attempt to create a user:

Traceback (most recent call last):
File "/home/boonyasys/AD-webmanager/venv/lib/python3.10/site-packages/flask/app.py", line 2091, in call
return self.wsgi_app(environ, start_response)
File "/home/boonyasys/AD-webmanager/venv/lib/python3.10/site-packages/flask/app.py", line 2076, in wsgi_app
response = self.handle_exception(e)
File "/home/boonyasys/AD-webmanager/venv/lib/python3.10/site-packages/flask/app.py", line 2073, in wsgi_app
response = self.full_dispatch_request()
File "/home/boonyasys/AD-webmanager/venv/lib/python3.10/site-packages/flask/app.py", line 1518, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/boonyasys/AD-webmanager/venv/lib/python3.10/site-packages/flask/app.py", line 1516, in full_dispatch_request
rv = self.dispatch_request()
File "/home/boonyasys/AD-webmanager/venv/lib/python3.10/site-packages/flask/app.py", line 1502, in dispatch_request
return self.ensure_sync(self.view_functions[rule.endpoint])(**req.view_args)
File "/home/boonyasys/AD-webmanager/libs/ldap_func.py", line 630, in _decorator
return view_func(*args, **kwargs)
File "/home/boonyasys/AD-webmanager/plugins/user.py", line 99, in user_add
users = ldap_get_all_users(attrset=['sAMAccountName'])
File "/home/boonyasys/AD-webmanager/libs/ldap_func.py", line 270, in ldap_get_all_users
user_list = ldap_get_entries(filter, base, scope, attrlist)
File "/home/boonyasys/AD-webmanager/libs/ldap_func.py", line 245, in ldap_get_entries
g.ldap_cache[attributes[attrlist[0]]] = attributes
KeyError: 'sAMAccountName'

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

No branches or pull requests

1 participant