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

Re: HEAD doesn't handle escaped characters properly?



> While I was testing some of the paged results code in HEAD (which appears
> fixed, thank you very much to those who fixed it) I discovered that I can
> no longer navigate to nodes in my ldap tree that have special characters
> like '<' in their dn from my ldap client (Softerra), nor can I get their
> children or attributes with my previously working java code.
>
> The following works fine when I bring up a database with 2.2.11, but fails
> when I bring up the database with today's HEAD code.  When I say fails, I
> mean I just get an object not found (or equivalent) message.

Did you rebuild the database?  I think from 2.2 to HEAD some of the DN
normalization choices changed to make ACL writing more robust.  This
implies that normalized DNs present the "special" chars as of RFC 2252
escaped thru the "\" + hexpair mechanism.  Of course slapd still
understands the "\" + special, but converts it to the other form.

I suggest you check a (2.2) slapcat and a (HEAD) slapadd before digging
any further.

p.

>
> Here is the dn I can not navigate to:
>
> conceptCode=LIST<T>,dc=Concepts,codingScheme=.......[snip]
>
> Softerra (correctly, as far as I know) escapes this as
> conceptCode=LIST\<T\>,dc=Concepts......[snip]
>
>
> And here is a debug level 1 from that navigation:
>
>
> connection_get(33): got connid=0
> connection_read(33): checking for input on id=0
> ber_get_next
> ber_get_next: tag 0x30 len 162 contents:
> ber_get_next
> ber_get_next on fd 33 failed errno=11 (Resource temporarily unavailable)
> do_search
> ber_scanf fmt ({miiiib) ber:
>>>> dnPrettyNormal:
>>>> <conceptCode=LIST\<T\>,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org>
> =>
> ldap_bv2dn(conceptCode=LIST\<T\>,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org,0)<=
> ldap_bv2dn(conceptCode=LIST\<T\>,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org,0)=0
> => ldap_dn2bv(272)
> <=
> ldap_dn2bv(conceptCode=LIST\3CT\3E,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org,272)=0
> => ldap_dn2bv(272)
> <=
> ldap_dn2bv(conceptCode=list\3Ct\3E,dc=concepts,codingScheme=parameterizeddatatype,dc=codingschemes,service=cts,dc=lexgrid,dc=org,272)=0
> <<< dnPrettyNormal:
> <conceptCode=LIST\3CT\3E,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org>,
> <conceptCode=list\3Ct\3E,dc=concepts,codingScheme=parameterizeddatatype,dc=codingschemes,service=cts,dc=lexgrid,dc=org>
> ber_scanf fmt (m) ber:
> ber_scanf fmt ({M}}) ber:
> ==> limits_get: conn=0 op=21 dn="[anonymous]"
> => bdb_search
> bdb_dn2entry("conceptCode=list\3Ct\3E,dc=concepts,codingScheme=parameterizeddatatype,dc=codingschemes,service=cts,dc=lexgrid,dc=org")
> => bdb_dn2id(
> "conceptCode=list\3Ct\3E,dc=concepts,codingScheme=parameterizeddatatype,dc=codingschemes,service=cts,dc=lexgrid,dc=org"
> )
> <= bdb_dn2id: get failed: DB_NOTFOUND: No matching key/data pair found
> (-30990)
> send_ldap_result: conn=0 op=21 p=3
> send_ldap_response: msgid=797 tag=101 err=32
> ber_flush: 108 bytes to sd 33
> connection_get(33): got connid=0
> connection_read(33): checking for input on id=0
> ber_get_next
> ber_get_next: tag 0x30 len 167 contents:
> ber_get_next
> ber_get_next on fd 33 failed errno=11 (Resource temporarily unavailable)
> do_search
> ber_scanf fmt ({miiiib) ber:
>>>> dnPrettyNormal:
>>>> <conceptCode=LIST\<T\>,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org>
> =>
> ldap_bv2dn(conceptCode=LIST\<T\>,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org,0)<=
> ldap_bv2dn(conceptCode=LIST\<T\>,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org,0)=0
> => ldap_dn2bv(272)
> <=
> ldap_dn2bv(conceptCode=LIST\3CT\3E,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org,272)=0
> => ldap_dn2bv(272)
> <=
> ldap_dn2bv(conceptCode=list\3Ct\3E,dc=concepts,codingScheme=parameterizeddatatype,dc=codingschemes,service=cts,dc=lexgrid,dc=org,272)=0
> <<< dnPrettyNormal:
> <conceptCode=LIST\3CT\3E,dc=Concepts,codingScheme=ParameterizedDataType,dc=CodingSchemes,service=CTS,dc=LexGrid,dc=org>,
> <conceptCode=list\3Ct\3E,dc=concepts,codingScheme=parameterizeddatatype,dc=codingschemes,service=cts,dc=lexgrid,dc=org>
> ber_scanf fmt (m) ber:
> ber_scanf fmt ({M}}) ber:
> ==> limits_get: conn=0 op=22 dn="[anonymous]"
> => bdb_search
> bdb_dn2entry("conceptCode=list\3Ct\3E,dc=concepts,codingScheme=parameterizeddatatype,dc=codingschemes,service=cts,dc=lexgrid,dc=org")
> => bdb_dn2id(
> "conceptCode=list\3Ct\3E,dc=concepts,codingScheme=parameterizeddatatype,dc=codingschemes,service=cts,dc=lexgrid,dc=org"
> )
> <= bdb_dn2id: get failed: DB_NOTFOUND: No matching key/data pair found
> (-30990)
> send_ldap_result: conn=0 op=22 p=3
> send_ldap_response: msgid=798 tag=101 err=32
> ber_flush: 108 bytes to sd 33
>
> Dan
>


-- 
Pierangelo Masarati
mailto:pierangelo.masarati@sys-net.it


    SysNet - via Dossi,8 27100 Pavia Tel: +390382573859 Fax: +390382476497