OpenLDAP how to create and use an objectclass that is a child of inetOrgPerson
I'm trying to create an LDAP based address book. For each recipient/user in it, I will need to store information about their contact points. Information will include:
contact type - phone/email/fax/pager/etc.
label - grandma's attic, work, home, etc.
address - actual phone number/email/etc.
and few other properties
I've figured out by now that there is nothing out of box that can handle this, but that I can create my own ContactPoint ObjectClass, make it a structural class and have it be a child of inetOrgPerson. but I still can't seem to wrap my head around how this all comes together. For example, how would I query for a person and his/her contact points?
Make it an inetOrgPerson
and an extensibleObject
. Then you can use any attribute from anywhere in it. I would steer well clear of defining your own object classes.
LDAP is designed to be extensible and defining new schema elements is often required. When clients cannot find an attribute with the syntax and name they desire, they should define a new attribute with an appropriate object class. Designers should:
extensibleObject
unless absolutely required. Using extensibleObject
is a last resort option and is similar to using an untyped programming language and results in poor quality, brittle, difficult to maintain systems For more information, please see "LDAP: Programming Practices"
链接地址: http://www.djcxy.com/p/60884.html上一篇: 搜索PHP