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

Non-automatic recognition of auxiliary objectClasses #1065

Open
jasongabler opened this issue Nov 1, 2022 · 1 comment
Open

Non-automatic recognition of auxiliary objectClasses #1065

jasongabler opened this issue Nov 1, 2022 · 1 comment

Comments

@jasongabler
Copy link

My organization has a custom structural objectClass of ucsfEduPerson. It's a subclass of inetOrgPerson. It incorporates the auxiliary objectClass of eduPerson by referring to the eduPersonAffiliation attribute. If I do not specify the auxiliary class when creating an ObjectDef for ucsfEduPerson, subsequent search operations on that structural objectClass will fail when specifically trying to retrieve eduPersonAffiliation or ldap3.ALL_ATTRIBUTES. It seems this is because Ldap3 doesn't know what to do with the eduPersonAffiliation attribute returned by my LDAP server as it is not aware of the auxiliary association. It behaves as though the LDAP server is in error, having returned an attribute that is not in the structural objectClass' schema.

I did get this to work, of course, by specifying the auxiliary objectClass when creating the ObjectDef. But, I've never had to provide that sort of additional instruction with any other LDAP library. So I was surprised. I would surmise that the other LDAP libraries I've used see the reference to an auxiliary objectClass when retrieving the structural objectClass defitniion and make an additional call to retrieve the auxiliary definition, or at least enough to incorporate the desired attributes as viable members of the structural objectClass.

What is the benefit of Ldap3 not taking this extra step? Obviously, it's not a deal breaker to have to put in a few dozen more characters of code. But, from my experience, it would seem to be more like an oversight. Now that I've spent 3 hours figuring out what was going on, I'll never have this problem again. And, thankfully, I've learned something along the way. But, shouldn't Ldap3 also do this extra step? The real question I have, why doesn't it?

@cannatag
Copy link
Owner

cannatag commented Nov 5, 2022 via email

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