active-directoryldapopenldapapacheds

Do we have any class schema available for OpenLDAP and ApacheDS for each object class?


We can find the classSchema available for each object class in active directory. As per the documentation of ApacheDS and OpenLDAP we could not find any class schema for finding Class identifiers, Possible attributes, Possible parents and Superclasses and auxiliary classes.

Do we have class schema available for OpenLDAP and ApacheDS? If no is there any way to find the system attributes for each object class for OpenLDAP and ApacheDS?


Solution

  • For most LDAP Server implementation the rootDSE has an attribute value for the defined in RFC 4512 section 4.4,

    To discover the DN of the subschema (sub)entry holding the subschema controlling a particular entry, a client reads that entry's 'subschemaSubentry' operational attribute.

    Typically this would be like subschemaSubentry: cn=schema. So a ldapsearch similar to:

    ldapsearch -h yourLDAPDNS  -b "cn=schema" -s base -D cn=admin,ou=...,dc=example,dc=com -w secretpassword "(objectclass=*)" > schema.ldif
    

    Should put the schema definition into the schema.ldif file. Some ldapserver implementations use a slightly different format for the ldapsearch requiring the return attributes be specified:

    ldapsearch -h yourLDAPDNS  -b "cn=schema" -s base -D cn=admin,ou=...,dc=example,dc=com -w secretpassword "(objectclass=*)" attributeTypes objectClasses