|
From: Hans A. <Han...@Ph...> - 2002-04-04 08:38:07
|
On Wednesday, 3. April 2002 20:48, Michael Ströder wrote: > Hans Aschauer wrote: > > On Wednesday, 3. April 2002 16:37, you wrote: [about doing clever things in climbing down trees] > I'm pretty sure there are situations where tree climbing does not > work. Don't try to be clever. Most times it does not work out. Anyway > we should review RFC 2251, section 3.2.2 for that more closely. Ok, I went back to RFC 2251. That's how I understand it (please correct me when I'm wrong): Sec. 3.4: We can query the RootDSE for the subschemaSubentry attribute, which tells us which "subschema entries (or subentries) [are] known by this server": [aschauer@pygar]$ldapsearch -LLL -x -b "" -s base "(objectclass=*)" \ subschemaSubentry dn: subschemaSubentry: cn=Subschema Sec. 3.2.2: The result conforms to this section: "cn: this attribute MUST be used to form the RDN of the subschema entry". One thing I missed up to now: "Clients MUST only retrieve attributes from a subschema entry by requesting a base object search of the entry, where the search filter is '(objectClass=subschema)'" (up to now I used '(objectClass=*)'). Let's try it: [aschauer@pygar]$ldapsearch -LLL -x -b "cn=Subschema" -s base \ "(objectclass=subschema)" objectclasses | less Works! So, as far as I understand it, we should first query the rootDSE for the subschema (sub)entries, and use the results as search bases for querying the schema information. > BTW: There could be also these attributes in sub schema sub entry: > matchingRuleUse, dITStructureRules, dITContentRules and nameForms. > I know OpenLDAP 2 server does not implement any of these. Does the > schema parser in OpenLDAP 2 libs handle any of these? Nope. I just looked at the source, and the parsers seem to be kind of hard-coded. No generic BNF parser. But then, that's exactly how I would write such a parser ;-) So long, Hans -- Han...@Ph... |