[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Enhancement to implement V3 Referral / SearchReferenceHandling (ITS#546)




Dmitry Kovalev wrote:

> Hello!
>
> Several questions about this patch and referral support in general.
>
> 1) What functionality does exactly this patch add? Brief examination of patch makes me think that it has something to do with following referrals on server side (not returning them to clients, but querying referred servers transparently). Is is so, or maybe something more? If not - what is it?
>

This is the client API.  This patch allows applications using the API to transparently follow LDAP V3 referrals & searchreferences received from the server, or to have more control over the referral by coding a rebind proc.  I tried to make the rebind functionality similiar to the existing V2
referral handling functionality.

>
> 2) Is there some document (rfc or draft or whatever) it is based on?
>

I am listing drafts that describe referrals from a client perspective.
The protocol for V3 referrals is described in RFC 2251.
The URL format is described in RFC 2255.
draft-ietf-ldapext-ldap-c-api-04.txt describes the following:
    behavior of automatically following referrals
    ldap_set_option (LDAP_REFERRAL) to control automatic following of referrals
    A Client Control That Governs Referral Processing - not implemented
    Parsing referrals using ldap_parse_result
At this time there is no draft or RFC that describes the rebind function or any other API to control referral chasing other than ldap_set_option.

>
> 3) Has it something to do with "draft-ietf-ldapext-namedref-xx.txt" I found in OpenLDAP's docs subdirectory?
> I'm not clear what ways of defining (storing) references are recognized by LDAP servers and OpenLDAP particularly. The document I menioned above defines
> "ref" attribute, which is suggested to be used in several following ways (described briefly):

As I understand this draft, this is one way a server could implement storing referral information.  The client API receives the referrals as described in RFC 2251 without regard as to how the server actually implements the capability or stores the information.  The examples show the kind of
referral information that is returned to the client.

>
> - when doing "base search" (retrieval of particular object): if entry is present, and contains "ref" attribute, return referral (unless manageDsaIT set), if entry is absent,
>  try to find "ref" attribute in superior entries (remove rdn and  search untill entry with "ref" present or root is reached), then return referral, or global (config-file) referral, or error
> - when doing onelevel or subtree search: return referrals for each object containing "ref" attribute and matching filter, along with entries
>
> Which of these are supported in OpenLDAP? How are they supported (primarily - is there some frontend support, or it is all left to backends)?
> Is this a most recent document on this matter? If not - where is updated document?
>

I don't know if V3 referrals are implemented in the development branch of the source (Someone fill in here).  I did my testing using a Novell Server which does support V3 referrals.

>
> I am going to implement all of these ways in my back-sql (since I need this functionality anyway), and willing to make it in conformance to standards, if they exist at all... Also, consider developing of some frontend support for this, to make implementation in other backends simplier.
>

When you do, this patch will allow applications to follow the referrals sent by the servers.

>
> 4)Also, there is some statement about "referral" objectclass in that document, which constraints that those "ref" attributes only can be found in "referral" objects.
> I'm not very clear about subclassing and things (BTW, where could I learn more about it?), so it seems to me that such constraint would render "ref" almost completely USELESS (since I cannot add it to any entry I want), especially for base search! If I am wrong - please explain, why...
>
> Anyway, in case of back-sql, there can be no subclassing at all, so I'm going to support "ref" automatically in any objectclass...
>
> Again, brief examination of OpenLDAP sources makes me think that referrals are returned only if objectclass is "referral", and "base search" logic is absent.
> And support for referrals consist of is_entry_referral() macro and get_entry_referrals() function...
> Am I right? If not - what is true situation?
>
> Any information on these questions is appreciated, because it will save me lots of time looking into sources and RFCs and things... :)

Someone else needs to respond on specific capabilities relating to OpenLDAP servers.

-Steve

>
>
> WBW, Dmitry
>
> "Kurt D. Zeilenga" wrote:
>
> > Developers, please review and provide technical comments to this
> > list. Thanks!
> >
> > Kurt
> >
> > At 03:55 PM 5/24/00 -0600, Steve Sonntag wrote:
> > >>>>
> > Full_Name: Steven Sonntag
> >
> > Here is the patch for the implementation of V3 referrals.