directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Steve hammond (JIRA)" <>
Subject [jira] Created: (DIRSERVER-1276) unescaping binary string corrupts values
Date Wed, 08 Oct 2008 14:19:44 GMT
unescaping binary string corrupts values

                 Key: DIRSERVER-1276
             Project: Directory ApacheDS
          Issue Type: Bug
          Components: core
    Affects Versions: 1.5.3
         Environment: Windows running under JBOSS
            Reporter: Steve hammond

When I pass in an escaped string into search, inside ConcreteNameComponentNormalizer, it corrupts
the binary values.
passed in 
after normalization interceptor visitor it is:
(&('0x29 0x4C 0x04 0xEF 0xBE 0xB5 0xEF 0xBF 0x94
0xEF 0xBF 0xAD 0x38 0x46 0xEF 0xBE ...'))

looks like in ConcreteNameComponentNormalizer line129                byte[] valBytes = unescaped.getBytes(
"UTF-8" );
causes the corruption.  The Variable unescaped seems correct and is 16 bytes, valBytes gets
created with 30 bytes with the extra data inserted.

The code I am using is:
         SearchOperationContext opContext = new SearchOperationContext(
               new SearchControls (
                     0, // countlim
                     0, // timelim
                     false, true));
         NamingEnumeration<ServerSearchResult> res =;

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message