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

C API: is reference following underspecified?



I am getting questions which indicate to me that the referral following 
behavior when LDAP_CHASE_SUBORDINATE_REFERRALS is on is underspecified in
the C API draft -04, even for issues besides authentication.

1. The LDAP_OPT_REFERRALS text talks about referrals but not references. Does
it apply to references as well, or just referral?

2. I was asked, why are the client controls only on the requests and not
on the responses?  If there was a LDAPControl ***clientctlsp on the 
ldap_get_entry_controls() or ldap_parse_reference() for example, then the 
library could put in a client control, such as the URL of the server 
which returned that entry or reference.  

2. When the library is following referrals and references, does it re-use the 
same message id as the original request, or create a new one?  (In our
implmentation what is returned in *msgidp is an internal request
ID which is not necessarily the same as the message id. Our message
ID is a counter per conection).  This is important if there is a 
situation where server A holds naming contexts dc=com and 
dc=foo,dc=bar,dc=com but not dc=bar,dc=com.   Server B holds dc=bar,dc=com.

So the client contacts A and subtree searches dc=com.  Server A returns 
a referral to server B for dc=bar,dc=com, but is still returning matching
entries in the dc=com naming context.  The client library contacts 
server B and issues a search of dc=bar,dc=com.  Server B returns a referral 
to server A for dc=foo,dc=bar,dc=com.  The client then contacts server A
and issues a search below dc=foo,dc=bar,dc=com.  Since the original search
may not have yet returned Search Result Done, there must be two distinct
message IDs for these searches on server A.  Therefore either the message id 
must change, or the client library block following references.  Does an 
ldap_result() still work if the message id changes?  

3. What does the library do if it cannot contact any of the URLs in a 
single search result reference? Or if it can but the server returns errors? 
Or success with controls?

Mark Wahl, Directory Product Architect
Innosoft International, Inc.