Uploaded image for project: 'Directory ApacheDS'
  1. Directory ApacheDS
  2. DIRSERVER-2057

Server returns search continuation only if 'ref' or '+' attributes are requested

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0-M19
    • Fix Version/s: 2.0.0-M20
    • Component/s: None
    • Labels:
      None

      Description

      If the search scope includes referral entries, then the server only converts them to search continuations if the search requested '+' or 'ref' attributes, otherwise the referral entry is returned.

      In 2.0.0-M14 this was different, even if only objectClass was requested by the client the referral object was converted to a search continuation.

      Unfortunately our tests don't cover this case.

      • SearchWithReferralsTest always requests * and +. ReferralSearchIT
      • ReferralSearchIT.testSearchContinuations() checks ReferralException but that catch block is never reached.

        Activity

        Hide
        elecharny Emmanuel Lecharny added a comment - - edited

        Whaoh... This is deep into the server : we consider that because the 'ref' attribute is operational (distributedOperation per RFC 3296), we don't return the entry as a referal if the '+' is not injected into the search.

        This is absolutely wrong.

        There are many use cases to consider though :

        • if the manageDSAIT control is present
          • the entry will be returned as if it was not a referral, so all the attributes will be filtered as it's done currently
        • if the manageDSAIT control is not present
          • if the entry is a referral, we return a SearchResultReference
          • otherwise we proceed as it's done currently

        I believe the only missing part is the handling of referrals when the manageDSAIT control is not present.

        Show
        elecharny Emmanuel Lecharny added a comment - - edited Whaoh... This is deep into the server : we consider that because the 'ref' attribute is operational ( distributedOperation per RFC 3296), we don't return the entry as a referal if the '+' is not injected into the search. This is absolutely wrong. There are many use cases to consider though : if the manageDSAIT control is present the entry will be returned as if it was not a referral, so all the attributes will be filtered as it's done currently if the manageDSAIT control is not present if the entry is a referral, we return a SearchResultReference otherwise we proceed as it's done currently I believe the only missing part is the handling of referrals when the manageDSAIT control is not present.
        Hide
        elecharny Emmanuel Lecharny added a comment -

        Should be fixed with http://svn.apache.org/r1676080

        Show
        elecharny Emmanuel Lecharny added a comment - Should be fixed with http://svn.apache.org/r1676080
        Hide
        seelmann Stefan Seelmann added a comment -

        I confirm it is fixed. I enabled the SWTBot test for Studio. Many thanks Emmanuel!

        Show
        seelmann Stefan Seelmann added a comment - I confirm it is fixed. I enabled the SWTBot test for Studio. Many thanks Emmanuel!

          People

          • Assignee:
            Unassigned
            Reporter:
            seelmann Stefan Seelmann
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development