Directory ApacheDS
  1. Directory ApacheDS
  2. DIRSERVER-836

Requesting an unknown attribute in a search operation causes an error

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: 1.0.1
    • Fix Version/s: 1.0.1
    • Component/s: None
    • Labels:
      None
    • Environment:
      * ApacheDS 1.5.0 (SNAPSHOT)
      * Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_07-b03)
      * Windows XP Professional SP2

      Description

      If someone tries to fetch an unknown attribute within a search operation, it causes an error. The expected behaviour is that the server ignores the unknown attribute. Here is a command line example:

      $ ldapsearch -h localhost -p 10389 -D "uid=admin,ou=system" -w ****** -b "dc=example,dc=com" -s base "(objectClass=*)" dc
      version: 1
      dn: dc=example,dc=com
      dc: example
      $ ldapsearch -h localhost -p 10389 -D "uid=admin,ou=system" -w ****** -b "dc=example,dc=com" -s base "(objectClass=*)" dc unknown
      ldap_search: Alias dereferencing problem
      ldap_search: additional info: failed on search operation: OID for name 'unknown' was not found within the OID registry
      $ ldapsearch -h localhost -p 10389 -D "uid=admin,ou=system" -w *****-b "dc=example,dc=com" -s base "(objectClass=)" dc;unknownOption
      ldap_search: Alias dereferencing problem
      ldap_search: additional info: failed on search operation: OID for name 'dc;unknownOption' was not found within the OID registry
      $

      I'll attach a JUnit test which demonstrates the problem with the help of JNDI.

        Activity

        Hide
        Stefan Zoerner added a comment -

        Here is the test case for this issue. I have successfully tested it on

        • Sun Java System Directory Server 5.2
        • IBM Tivoli Directory Server 6.0
        • OpenLDAP 2.3

        On the current ApacheDS 1.5.0 snapshot, both test methods fail.

        Show
        Stefan Zoerner added a comment - Here is the test case for this issue. I have successfully tested it on Sun Java System Directory Server 5.2 IBM Tivoli Directory Server 6.0 OpenLDAP 2.3 On the current ApacheDS 1.5.0 snapshot, both test methods fail.
        Show
        Emmanuel Lecharny added a comment - Fixed in 1.0.1 : test : http://svn.apache.org/viewvc?view=rev&rev=499730 fix : http://svn.apache.org/viewvc?view=rev&rev=499731 Fixed in 1.5.0 : test : http://svn.apache.org/viewvc?view=rev&rev=499740 fix : http://svn.apache.org/viewvc?view=rev&rev=499739
        Hide
        Stefan Zoerner added a comment -

        I have checked the situation with a current build; the problem does not occur anymore. Therefore I close this issue. Thanks for resolving it!

        Show
        Stefan Zoerner added a comment - I have checked the situation with a current build; the problem does not occur anymore. Therefore I close this issue. Thanks for resolving it!
        Hide
        Stefan Zoerner added a comment -

        Exactly this error is present in the current ApacheDS 1.0.1-SNAPSHOT Rev. 507868. The test case originally attached fails (both test methods).

        The problem is Open Group Certification relevant.

        Show
        Stefan Zoerner added a comment - Exactly this error is present in the current ApacheDS 1.0.1-SNAPSHOT Rev. 507868. The test case originally attached fails (both test methods). The problem is Open Group Certification relevant.
        Hide
        Stefan Zoerner added a comment -

        Although not that important from a user point of view, this problem is Open Group LDAP certification relevant.
        Hence I set it to "blocker".

        Show
        Stefan Zoerner added a comment - Although not that important from a user point of view, this problem is Open Group LDAP certification relevant. Hence I set it to "blocker".
        Show
        Emmanuel Lecharny added a comment - Fixed : http://svn.apache.org/viewvc?view=rev&rev=508127 and http://svn.apache.org/viewvc?view=rev&rev=508126
        Hide
        Stefan Zoerner added a comment -

        I do confirm that it works with rev. 508131, well done, Emmanuel!

        Show
        Stefan Zoerner added a comment - I do confirm that it works with rev. 508131, well done, Emmanuel!

          People

          • Assignee:
            Unassigned
            Reporter:
            Stefan Zoerner
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development