You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by el...@apache.org on 2012/01/24 18:27:12 UTC

svn commit: r1235364 [18/27] - in /directory/shared/trunk: asn1/api/src/main/java/org/apache/directory/shared/asn1/util/ asn1/api/src/test/java/org/apache/directory/shared/asn1/util/ asn1/ber/src/main/java/org/apache/directory/shared/asn1/actions/ asn1...

Modified: directory/shared/trunk/ldap/codec/core/src/test/java/org/apache/directory/shared/ldap/codec/search/SearchRequestTest.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/codec/core/src/test/java/org/apache/directory/shared/ldap/codec/search/SearchRequestTest.java?rev=1235364&r1=1235363&r2=1235364&view=diff
==============================================================================
--- directory/shared/trunk/ldap/codec/core/src/test/java/org/apache/directory/shared/ldap/codec/search/SearchRequestTest.java (original)
+++ directory/shared/trunk/ldap/codec/core/src/test/java/org/apache/directory/shared/ldap/codec/search/SearchRequestTest.java Tue Jan 24 17:27:00 2012
@@ -124,7 +124,8 @@ public class SearchRequestTest extends A
         stream.put( new byte[]
             { 0x30, ( byte ) 0x81,
                 ( byte ) 0x8D, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x01, // messageID MessageID
                 0x63,
                 ( byte ) 0x81,
@@ -133,49 +134,162 @@ public class SearchRequestTest extends A
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x1F, // baseObject LDAPDN,
-                'u', 'i', 'd', '=', 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u', ',', 'd', 'c', '=', 'e', 'x', 'a',
-                'm', 'p', 'l', 'e', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0A, 0x01, 0x01, // scope ENUMERATED {
+                'u',
+                'i',
+                'd',
+                '=',
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
+                ',',
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0A,
+                0x01,
+                0x01, // scope ENUMERATED {
                 // baseObject (0),
                 // singleLevel (1),
                 // wholeSubtree (2) },
-                0x0A, 0x01, 0x03, // derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x03, // derefAliases ENUMERATED {
                 // neverDerefAliases (0),
                 // derefInSearching (1),
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
-                0x01, 0x01, ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
+                0x01,
+                0x01,
+                ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
                 // filter Filter,
-                ( byte ) 0xA0, 0x3C, // Filter ::= CHOICE {
+                ( byte ) 0xA0,
+                0x3C, // Filter ::= CHOICE {
                 // and [0] SET OF Filter,
-                ( byte ) 0xA1, 0x24, // or [1] SET of Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3]
+                ( byte ) 0xA1,
+                0x24, // or [1] SET of Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3]
                 // Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 'o', 'p', ( byte ) 0xA3, 0x0E, // equalityMatch [3] Assertion,
+                0x04,
+                0x03,
+                't',
+                'o',
+                'p',
+                ( byte ) 0xA3,
+                0x0E, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
-                0x04, 0x02, 'o', 'u', // attributeDesc AttributeDescription (LDAPString),
+                0x04,
+                0x02,
+                'o',
+                'u', // attributeDesc AttributeDescription (LDAPString),
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x08, 'c', 'o', 'n', 't', 'a', 'c', 't', 's', ( byte ) 0xA2, 0x14, // not [2] Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3] Assertion,
+                0x04,
+                0x08,
+                'c',
+                'o',
+                'n',
+                't',
+                'a',
+                'c',
+                't',
+                's',
+                ( byte ) 0xA2,
+                0x14, // not [2] Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 't', 't',
+                0x04,
+                0x03,
+                't',
+                't',
+                't',
                 // attributes AttributeDescriptionList }
-                0x30, 0x15, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x15, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x05, 'a', 't', 't', 'r', '0', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '1', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '2' // AttributeDescription ::= LDAPString
-            } );
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '0', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '1', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '2' // AttributeDescription ::= LDAPString
+        } );
 
-        String decodedPdu = Strings.dumpBytes(stream.array());
+        String decodedPdu = Strings.dumpBytes( stream.array() );
         stream.flip();
 
         // Allocate a BindRequest Container
@@ -261,7 +375,7 @@ public class SearchRequestTest extends A
             // Check the length
             assertEquals( 0x90, bb.limit() );
 
-            String encodedPdu = Strings.dumpBytes(bb.array());
+            String encodedPdu = Strings.dumpBytes( bb.array() );
 
             assertEquals( encodedPdu.substring( 0, 0x81 ), decodedPdu.substring( 0, 0x81 ) );
         }
@@ -287,7 +401,8 @@ public class SearchRequestTest extends A
         stream.put( new byte[]
             { 0x30, ( byte ) 0x81,
                 ( byte ) 0x8D, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x01, //     messageID MessageID
                 0x63,
                 ( byte ) 0x81,
@@ -296,46 +411,156 @@ public class SearchRequestTest extends A
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x1F, //     baseObject LDAPDN,
-                'u', 'i', 'd', '=', 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u', ',', 'd', 'c', '=', 'e', 'x', 'a',
-                'm', 'p', 'l', 'e', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0A, 0x01, 0x01, //     scope ENUMERATED {
+                'u',
+                'i',
+                'd',
+                '=',
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
+                ',',
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0A,
+                0x01,
+                0x01, //     scope ENUMERATED {
                 //         baseObject   (0),
                 //         singleLevel  (1),
                 //         wholeSubtree (2) },
-                0x0A, 0x01, 0x03, //     derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x03, //     derefAliases ENUMERATED {
                 //         neverDerefAliases (0),
                 //         derefInSearching (1),
                 //         derefFindingBaseObj (2),
                 //         derefAlways (3) },
-                0x02, 0x02, 0x03, ( byte ) 0xE8, //     sizeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03, ( byte ) 0xE8, //     timeLimit INTEGER (0 .. maxInt), (1000)
-                0x01, 0x01, ( byte ) 0xFF, //     typesOnly BOOLEAN, (TRUE)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, //     sizeLimit INTEGER (0 .. maxInt), (1000)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, //     timeLimit INTEGER (0 .. maxInt), (1000)
+                0x01,
+                0x01,
+                ( byte ) 0xFF, //     typesOnly BOOLEAN, (TRUE)
                 //     filter Filter,
-                ( byte ) 0xA0, 0x3C, // Filter ::= CHOICE {
+                ( byte ) 0xA0,
+                0x3C, // Filter ::= CHOICE {
                 //      and [0] SET OF Filter,
-                ( byte ) 0xA1, 0x24, //      or [1] SET of Filter,
-                ( byte ) 0xA8, 0x12, //      approxMatch [8]
+                ( byte ) 0xA1,
+                0x24, //      or [1] SET of Filter,
+                ( byte ) 0xA8,
+                0x12, //      approxMatch [8]
                 // Assertion,
                 // Assertion ::= SEQUENCE {
-                0x04, 0x0B, // attributeDesc AttributeDescription (LDAPString),
-                'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's', 0x04, 0x03, // attributeDesc AttributeDescription (LDAPString),
-                't', 'o', 'p', ( byte ) 0xA6, 0x0E, // lessOrEqual [3] Assertion,
-                0x04, 0x02, // Assertion ::= SEQUENCE {
-                'o', 'u', // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x08, // assertionValue AssertionValue (OCTET STRING) }
-                'c', 'o', 'n', 't', 'a', 'c', 't', 's', ( byte ) 0xA2, 0x14, // not [2] Filter,
-                ( byte ) 0xA5, 0x12, // greaterOrEqual [5] Assertion,
+                0x04,
+                0x0B, // attributeDesc AttributeDescription (LDAPString),
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
+                0x04,
+                0x03, // attributeDesc AttributeDescription (LDAPString),
+                't',
+                'o',
+                'p',
+                ( byte ) 0xA6,
+                0x0E, // lessOrEqual [3] Assertion,
+                0x04,
+                0x02, // Assertion ::= SEQUENCE {
+                'o',
+                'u', // attributeDesc AttributeDescription (LDAPString),
+                0x04,
+                0x08, // assertionValue AssertionValue (OCTET STRING) }
+                'c',
+                'o',
+                'n',
+                't',
+                'a',
+                'c',
+                't',
+                's',
+                ( byte ) 0xA2,
+                0x14, // not [2] Filter,
+                ( byte ) 0xA5,
+                0x12, // greaterOrEqual [5] Assertion,
                 // Assertion ::= SEQUENCE {
-                0x04, 0x0B, // attributeDesc AttributeDescription (LDAPString),
-                'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's', 0x04, 0x03, 't', 't', 't', // assertionValue AssertionValue (OCTET STRING) }
+                0x04,
+                0x0B, // attributeDesc AttributeDescription (LDAPString),
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
+                0x04,
+                0x03,
+                't',
+                't',
+                't', // assertionValue AssertionValue (OCTET STRING) }
                 // attributes AttributeDescriptionList }
-                0x30, 0x15, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x15, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x05, 'a', 't', 't', 'r', '0', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '1', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '2' // AttributeDescription ::= LDAPString
-            } );
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '0', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '1', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '2' // AttributeDescription ::= LDAPString
+        } );
 
-        String decodedPdu = Strings.dumpBytes(stream.array());
+        String decodedPdu = Strings.dumpBytes( stream.array() );
         stream.flip();
 
         // Allocate a BindRequest Container
@@ -422,7 +647,7 @@ public class SearchRequestTest extends A
             // Check the length
             assertEquals( 0x0090, bb.limit() );
 
-            String encodedPdu = Strings.dumpBytes(bb.array());
+            String encodedPdu = Strings.dumpBytes( bb.array() );
 
             assertEquals( encodedPdu.substring( 0, 0x81 ), decodedPdu.substring( 0, 0x81 ) );
         }
@@ -448,62 +673,159 @@ public class SearchRequestTest extends A
         stream.put( new byte[]
             { 0x30,
                 0x79, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x01, // messageID MessageID
                 0x63,
                 0x74, // CHOICE { ..., searchRequest SearchRequest, ...
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x1F, // baseObject LDAPDN,
-                'u', 'i', 'd', '=', 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u', ',', 'd', 'c', '=', 'e', 'x', 'a',
-                'm', 'p', 'l', 'e', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0A, 0x01, 0x01, // scope
+                'u',
+                'i',
+                'd',
+                '=',
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
+                ',',
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0A,
+                0x01,
+                0x01, // scope
                 // ENUMERATED
                 // {
                 // baseObject (0),
                 // singleLevel (1),
                 // wholeSubtree (2) },
-                0x0A, 0x01, 0x03, // derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x03, // derefAliases ENUMERATED {
                 // neverDerefAliases (0),
                 // derefInSearching (1),
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
                 // sizeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03, ( byte ) 0xE8,
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8,
                 // timeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03, ( byte ) 0xE8, 0x01, 0x01, ( byte ) 0xFF, // typesOnly
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8,
+                0x01,
+                0x01,
+                ( byte ) 0xFF, // typesOnly
                 // BOOLEAN,
                 // (TRUE)
                 // filter Filter,
-                ( byte ) 0xA0, 0x29, // Filter ::= CHOICE {
+                ( byte ) 0xA0,
+                0x29, // Filter ::= CHOICE {
                 // and [0] SET OF Filter,
-                ( byte ) 0xA1, 0x11, // or [1] SET of Filter,
-                ( byte ) 0x87, 0x0B, // present [7] AttributeDescription,
+                ( byte ) 0xA1,
+                0x11, // or [1] SET of Filter,
+                ( byte ) 0x87,
+                0x0B, // present [7] AttributeDescription,
                 // AttributeDescription ::= LDAPString
-                'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                ( byte ) 0x87, 0x02, 'o', 'u', // present [7]
+                ( byte ) 0x87,
+                0x02,
+                'o',
+                'u', // present [7]
                 // AttributeDescription,
                 // AttributeDescription ::= LDAPString
-                ( byte ) 0xA2, 0x14, // not [2] Filter,
-                ( byte ) 0xA5, 0x12, // greaterOrEqual [5]
+                ( byte ) 0xA2,
+                0x14, // not [2] Filter,
+                ( byte ) 0xA5,
+                0x12, // greaterOrEqual [5]
                 // Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 't', 't',
+                0x04,
+                0x03,
+                't',
+                't',
+                't',
                 // attributes AttributeDescriptionList }
-                0x30, 0x15, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x15, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x05, 'a', 't', 't', 'r', '0', // AttributeDescription
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '0', // AttributeDescription
                 // ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '1', // AttributeDescription
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '1', // AttributeDescription
                 // ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '2' // AttributeDescription ::=
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '2' // AttributeDescription ::=
             // LDAPString
-            } );
+        } );
 
-        String decodedPdu = Strings.dumpBytes(stream.array());
+        String decodedPdu = Strings.dumpBytes( stream.array() );
         stream.flip();
 
         // Allocate a BindRequest Container
@@ -589,7 +911,7 @@ public class SearchRequestTest extends A
             // Check the length
             assertEquals( 0x7B, bb.limit() );
 
-            String encodedPdu = Strings.dumpBytes(bb.array());
+            String encodedPdu = Strings.dumpBytes( bb.array() );
 
             assertEquals( encodedPdu.substring( 0, 0x6C ), decodedPdu.substring( 0, 0x6C ) );
         }
@@ -614,40 +936,85 @@ public class SearchRequestTest extends A
         stream.put( new byte[]
             { 0x30,
                 0x37, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x03, // messageID MessageID
                 0x63,
                 0x32, // CHOICE { ..., searchRequest SearchRequest, ...
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x12, // baseObject LDAPDN,
-                'o', 'u', '=', 'u', 's', 'e', 'r', 's', ',', 'o', 'u', '=', 's', 'y', 's', 't', 'e', 'm', 0x0A, 0x01,
+                'o',
+                'u',
+                '=',
+                'u',
+                's',
+                'e',
+                'r',
+                's',
+                ',',
+                'o',
+                'u',
+                '=',
+                's',
+                'y',
+                's',
+                't',
+                'e',
+                'm',
+                0x0A,
+                0x01,
                 0x00, // scope ENUMERATED {
                 // baseObject (0),
                 // singleLevel (1),
                 // wholeSubtree (2) },
-                0x0A, 0x01, 0x03, // derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x03, // derefAliases ENUMERATED {
                 // neverDerefAliases (0),
                 // derefInSearching (1),
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
                 // sizeLimit INTEGER (0 .. maxInt), (infinite)
-                0x02, 0x01, 0x00,
+                0x02,
+                0x01,
+                0x00,
                 // timeLimit INTEGER (0 .. maxInt), (infinite)
-                0x02, 0x01, 0x00, 0x01, 0x01, ( byte ) 0x00, // typesOnly
+                0x02,
+                0x01,
+                0x00,
+                0x01,
+                0x01,
+                ( byte ) 0x00, // typesOnly
                 // BOOLEAN,
                 // (FALSE)
                 // filter Filter,
                 // Filter ::= CHOICE {
-                ( byte ) 0x87, 0x0B, // present [7] AttributeDescription,
-                'o', 'b', 'j', 'e', 'c', 't', 'C', 'l', 'a', 's', 's',
+                ( byte ) 0x87,
+                0x0B, // present [7] AttributeDescription,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'C',
+                'l',
+                'a',
+                's',
+                's',
                 // attributes AttributeDescriptionList }
-                0x30, 0x00, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x00, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x00, 0x00, // Some trailing 00, useless.
-                0x00, 0x00, 0x00, 0x00 } );
+                0x00,
+                0x00, // Some trailing 00, useless.
+                0x00,
+                0x00,
+                0x00,
+                0x00 } );
 
-        String decodedPdu = Strings.dumpBytes(stream.array());
+        String decodedPdu = Strings.dumpBytes( stream.array() );
         stream.flip();
 
         // Allocate a BindRequest Container
@@ -696,7 +1063,7 @@ public class SearchRequestTest extends A
             // Check the length
             assertEquals( 0x39, bb.limit() );
 
-            String encodedPdu = Strings.dumpBytes(bb.array());
+            String encodedPdu = Strings.dumpBytes( bb.array() );
 
             assertEquals( encodedPdu, decodedPdu.substring( 0, decodedPdu.length() - 35 ) );
         }
@@ -721,38 +1088,83 @@ public class SearchRequestTest extends A
         stream.put( new byte[]
             { 0x30,
                 0x3D, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x03, // messageID MessageID
                 0x63,
                 0x38, // CHOICE { ..., searchRequest SearchRequest, ...
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x12, // baseObject LDAPDN,
-                'o', 'u', '=', 'u', 's', 'e', 'r', 's', ',', 'o', 'u', '=', 's', 'y', 's', 't', 'e', 'm', 0x0A, 0x01,
+                'o',
+                'u',
+                '=',
+                'u',
+                's',
+                'e',
+                'r',
+                's',
+                ',',
+                'o',
+                'u',
+                '=',
+                's',
+                'y',
+                's',
+                't',
+                'e',
+                'm',
+                0x0A,
+                0x01,
                 0x00, // scope ENUMERATED {
                 // baseObject (0),
                 // singleLevel (1),
                 // wholeSubtree (2) },
-                0x0A, 0x01, 0x03, // derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x03, // derefAliases ENUMERATED {
                 // neverDerefAliases (0),
                 // derefInSearching (1),
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
                 // sizeLimit INTEGER (0 .. maxInt), (infinite)
-                0x02, 0x01, 0x00, // timeLimit INTEGER (0 .. maxInt), (infinite)
-                0x02, 0x01, 0x00, 0x01, 0x01, 0x00, // typesOnly
-                // BOOLEAN,
-                // (FALSE)
-                // filter Filter,
-                // Filter ::= CHOICE {
-                ( byte ) 0x87, 0x0B, // present [7] AttributeDescription,
-                'o', 'b', 'j', 'e', 'c', 't', 'C', 'l', 'a', 's', 's',
-                // attributes AttributeDescriptionList }
-                0x30, 0x06, // AttributeDescriptionList ::= SEQUENCE OF
+                0x02,
+                0x01,
+                0x00, // timeLimit INTEGER (0 .. maxInt), (infinite)
+                0x02,
+                0x01,
+                0x00,
+                0x01,
+                0x01,
+                0x00, // typesOnly
+                // BOOLEAN,
+                // (FALSE)
+                // filter Filter,
+                // Filter ::= CHOICE {
+                ( byte ) 0x87,
+                0x0B, // present [7] AttributeDescription,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'C',
+                'l',
+                'a',
+                's',
+                's',
+                // attributes AttributeDescriptionList }
+                0x30,
+                0x06, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x02, // Request for sn
-                's', 'n', 0x04, 0x00 // Empty attribute
-            } );
+                0x04,
+                0x02, // Request for sn
+                's',
+                'n',
+                0x04,
+                0x00 // Empty attribute
+        } );
 
         stream.flip();
 
@@ -809,38 +1221,84 @@ public class SearchRequestTest extends A
         stream.put( new byte[]
             { 0x30,
                 0x3E, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x03, // messageID MessageID
                 0x63,
                 0x39, // CHOICE { ..., searchRequest SearchRequest, ...
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x12, // baseObject LDAPDN,
-                'o', 'u', '=', 'u', 's', 'e', 'r', 's', ',', 'o', 'u', '=', 's', 'y', 's', 't', 'e', 'm', 0x0A, 0x01,
+                'o',
+                'u',
+                '=',
+                'u',
+                's',
+                'e',
+                'r',
+                's',
+                ',',
+                'o',
+                'u',
+                '=',
+                's',
+                'y',
+                's',
+                't',
+                'e',
+                'm',
+                0x0A,
+                0x01,
                 0x00, // scope ENUMERATED {
                 // baseObject (0),
                 // singleLevel (1),
                 // wholeSubtree (2) },
-                0x0A, 0x01, 0x03, // derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x03, // derefAliases ENUMERATED {
                 // neverDerefAliases (0),
                 // derefInSearching (1),
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
                 // sizeLimit INTEGER (0 .. maxInt), (infinite)
-                0x02, 0x01, 0x00, // timeLimit INTEGER (0 .. maxInt), (infinite)
-                0x02, 0x01, 0x00, 0x01, 0x01, 0x00, // typesOnly
+                0x02,
+                0x01,
+                0x00, // timeLimit INTEGER (0 .. maxInt), (infinite)
+                0x02,
+                0x01,
+                0x00,
+                0x01,
+                0x01,
+                0x00, // typesOnly
                 // BOOLEAN,
                 // (FALSE)
                 // filter Filter,
                 // Filter ::= CHOICE {
-                ( byte ) 0x87, 0x0B, // present [7] AttributeDescription,
-                'o', 'b', 'j', 'e', 'c', 't', 'C', 'l', 'a', 's', 's',
+                ( byte ) 0x87,
+                0x0B, // present [7] AttributeDescription,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'C',
+                'l',
+                'a',
+                's',
+                's',
                 // attributes AttributeDescriptionList }
-                0x30, 0x07, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x07, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x02, // Request for sn
-                's', 'n', 0x04, 0x01, '*' // * attribute
-            } );
+                0x04,
+                0x02, // Request for sn
+                's',
+                'n',
+                0x04,
+                0x01,
+                '*' // * attribute
+        } );
 
         stream.flip();
 
@@ -910,28 +1368,150 @@ public class SearchRequestTest extends A
                 0x63,
                 ( byte ) 0x81,
                 ( byte ) 0x8D, // "dc=example,dc=com"
-                0x04, 0x11, 'd', 'c', '=', 'e', 'x', 'a', 'm', 'p', 'l', 'e', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0A,
-                0x01, 0x00, 0x0A, 0x01, 0x02, 0x02, 0x01, 0x02, 0x02, 0x01, 0x03, 0x01, 0x01,
+                0x04,
+                0x11,
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0A,
+                0x01,
+                0x00,
+                0x0A,
+                0x01,
+                0x02,
+                0x02,
+                0x01,
+                0x02,
+                0x02,
+                0x01,
+                0x03,
+                0x01,
+                0x01,
                 ( byte ) 0xFF,
                 ( byte ) 0xA1,
                 0x52, // ( |
                 ( byte ) 0xA3,
                 0x10, // ( uid=akarasulu )
-                0x04, 0x03, 'u', 'i', 'd', 0x04, 0x09, 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u',
+                0x04,
+                0x03,
+                'u',
+                'i',
+                'd',
+                0x04,
+                0x09,
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
                 ( byte ) 0xA3,
                 0x09, // ( cn=aok )
-                0x04, 0x02, 'c', 'n', 0x04, 0x03, 'a', 'o', 'k', ( byte ) 0xA3,
+                0x04,
+                0x02,
+                'c',
+                'n',
+                0x04,
+                0x03,
+                'a',
+                'o',
+                'k',
+                ( byte ) 0xA3,
                 0x15, // ( ou=Human Resources )
-                0x04, 0x02, 'o', 'u', 0x04, 0x0F, 'H', 'u', 'm', 'a', 'n', ' ', 'R', 'e', 's', 'o', 'u', 'r', 'c', 'e',
-                's', ( byte ) 0xA3, 0x10, 0x04, 0x01, 'l', // (l=Santa Clara )
-                0x04, 0x0B, 'S', 'a', 'n', 't', 'a', ' ', 'C', 'l', 'a', 'r', 'a', ( byte ) 0xA3, 0x0A, // ( cn=abok ))
-                0x04, 0x02, 'c', 'n', 0x04, 0x04, 'a', 'b', 'o', 'k', 0x30, 0x15, // Attributes
-                0x04, 0x05, 'a', 't', 't', 'r', '0', // attr0
-                0x04, 0x05, 'a', 't', 't', 'r', '1', // attr1
-                0x04, 0x05, 'a', 't', 't', 'r', '2' // attr2
-            } );
+                0x04,
+                0x02,
+                'o',
+                'u',
+                0x04,
+                0x0F,
+                'H',
+                'u',
+                'm',
+                'a',
+                'n',
+                ' ',
+                'R',
+                'e',
+                's',
+                'o',
+                'u',
+                'r',
+                'c',
+                'e',
+                's',
+                ( byte ) 0xA3,
+                0x10,
+                0x04,
+                0x01,
+                'l', // (l=Santa Clara )
+                0x04,
+                0x0B,
+                'S',
+                'a',
+                'n',
+                't',
+                'a',
+                ' ',
+                'C',
+                'l',
+                'a',
+                'r',
+                'a',
+                ( byte ) 0xA3,
+                0x0A, // ( cn=abok ))
+                0x04,
+                0x02,
+                'c',
+                'n',
+                0x04,
+                0x04,
+                'a',
+                'b',
+                'o',
+                'k',
+                0x30,
+                0x15, // Attributes
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '0', // attr0
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '1', // attr1
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '2' // attr2
+        } );
 
-        String decodedPdu = Strings.dumpBytes(stream.array());
+        String decodedPdu = Strings.dumpBytes( stream.array() );
         stream.flip();
 
         // Allocate a BindRequest Container
@@ -1013,7 +1593,7 @@ public class SearchRequestTest extends A
             // Check the length
             assertEquals( 0x0096, bb.limit() );
 
-            String encodedPdu = Strings.dumpBytes(bb.array());
+            String encodedPdu = Strings.dumpBytes( bb.array() );
 
             assertEquals( encodedPdu.substring( 0, 0x87 ), decodedPdu.substring( 0, 0x87 ) );
         }
@@ -1034,79 +1614,273 @@ public class SearchRequestTest extends A
         byte[] asn1BERJava5 = new byte[]
             { 0x30, 0x7f,
                 0x02, 0x01, 0x04, // messageID
-                0x63, 0x33,
-                  0x04, 0x13, // baseObject
-                    'd', 'c', '=', 'm', 'y', '-', 'd', 'o', 'm', 'a', 'i', 'n', ',', 'd', 'c', '=', 'c', 'o', 'm',
-                  0x0a, 0x01, 0x02, // scope: subtree
-                  0x0a, 0x01, 0x03, // derefAliases: derefAlways
-                  0x02, 0x01, 0x00, // sizeLimit: 0
-                  0x02, 0x01, 0x00, // timeLimit: 0
-                  0x01, 0x01, 0x00, // typesOnly: false
-                  ( byte ) 0x87, 0x0b, // Present filter: (objectClass=*)
-                    'o', 'b', 'j', 'e', 'c', 't', 'C', 'l', 'a', 's', 's',
-                  0x30, 0x00, // Attributes = '*'
-                  ( byte ) 0xa0, 0x45, // controls
-                    0x30, 0x28,
-                      0x04, 0x16, // control
-                        '1', '.', '2', '.', '8', '4', '0', '.',
-                        '1', '1', '3', '5', '5', '6', '.', '1',
-                        '.', '4', '.', '3', '1', '9',
-                      0x01, 0x01, ( byte ) 0xff, // criticality: false
-                      0x04, 0x0b,
-                        0x30, 0x09,
-                          0x02, 0x01, 0x02,
-                          0x04, 0x04, 0x47, 0x00, 0x00, 0x00, // value: pageSize=2
-                    0x30, 0x19,
-                      0x04, 0x17, // control
-                        '2', '.', '1', '6', '.', '8', '4', '0',
-                        '.', '1', '.', '1', '1', '3', '7', '3',
-                        '0', '.', '3', '.', '4', '.', '2',
-                        };
+                0x63,
+                0x33,
+                0x04,
+                0x13, // baseObject
+                'd',
+                'c',
+                '=',
+                'm',
+                'y',
+                '-',
+                'd',
+                'o',
+                'm',
+                'a',
+                'i',
+                'n',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0a,
+                0x01,
+                0x02, // scope: subtree
+                0x0a,
+                0x01,
+                0x03, // derefAliases: derefAlways
+                0x02,
+                0x01,
+                0x00, // sizeLimit: 0
+                0x02,
+                0x01,
+                0x00, // timeLimit: 0
+                0x01,
+                0x01,
+                0x00, // typesOnly: false
+                ( byte ) 0x87,
+                0x0b, // Present filter: (objectClass=*)
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'C',
+                'l',
+                'a',
+                's',
+                's',
+                0x30,
+                0x00, // Attributes = '*'
+                ( byte ) 0xa0,
+                0x45, // controls
+                0x30,
+                0x28,
+                0x04,
+                0x16, // control
+                '1',
+                '.',
+                '2',
+                '.',
+                '8',
+                '4',
+                '0',
+                '.',
+                '1',
+                '1',
+                '3',
+                '5',
+                '5',
+                '6',
+                '.',
+                '1',
+                '.',
+                '4',
+                '.',
+                '3',
+                '1',
+                '9',
+                0x01,
+                0x01,
+                ( byte ) 0xff, // criticality: false
+                0x04,
+                0x0b,
+                0x30,
+                0x09,
+                0x02,
+                0x01,
+                0x02,
+                0x04,
+                0x04,
+                0x47,
+                0x00,
+                0x00,
+                0x00, // value: pageSize=2
+                0x30,
+                0x19,
+                0x04,
+                0x17, // control
+                '2',
+                '.',
+                '1',
+                '6',
+                '.',
+                '8',
+                '4',
+                '0',
+                '.',
+                '1',
+                '.',
+                '1',
+                '1',
+                '3',
+                '7',
+                '3',
+                '0',
+                '.',
+                '3',
+                '.',
+                '4',
+                '.',
+                '2',
+        };
 
         byte[] asn1BERJava6 = new byte[]
-           { 0x30, 0x7f,
-               0x02, 0x01, 0x04, // messageID
-               0x63, 0x33,
-                 0x04, 0x13, // baseObject
-                   'd', 'c', '=', 'm', 'y', '-', 'd', 'o', 'm', 'a', 'i', 'n', ',', 'd', 'c', '=', 'c', 'o', 'm',
-                 0x0a, 0x01, 0x02, // scope: subtree
-                 0x0a, 0x01, 0x03, // derefAliases: derefAlways
-                 0x02, 0x01, 0x00, // sizeLimit: 0
-                 0x02, 0x01, 0x00, // timeLimit: 0
-                 0x01, 0x01, 0x00, // typesOnly: false
-                 ( byte ) 0x87, 0x0b, // Present filter: (objectClass=*)
-                   'o', 'b', 'j', 'e', 'c', 't', 'C', 'l', 'a', 's', 's',
-                 0x30, 0x00, // Attributes = '*'
-                 ( byte ) 0xa0, 0x45, // controls
-                   0x30, 0x19,
-                     0x04, 0x17, // control
-                       '2', '.', '1', '6', '.', '8', '4', '0',
-                       '.', '1', '.', '1', '1', '3', '7', '3',
-                       '0', '.', '3', '.', '4', '.', '2',
-                   0x30, 0x28,
-                     0x04, 0x16, // control
-                       '1', '.', '2', '.', '8', '4', '0', '.',
-                       '1', '1', '3', '5', '5', '6', '.', '1',
-                       '.', '4', '.', '3', '1', '9',
-                     0x01, 0x01, ( byte ) 0xff, // criticality: false
-                     0x04, 0x0b,
-                       0x30, 0x09,
-                         0x02, 0x01, 0x02,
-                         0x04, 0x04, 0x47, 0x00, 0x00, 0x00, // value: pageSize=2
-                       };
+            { 0x30, 0x7f,
+                0x02, 0x01, 0x04, // messageID
+                0x63,
+                0x33,
+                0x04,
+                0x13, // baseObject
+                'd',
+                'c',
+                '=',
+                'm',
+                'y',
+                '-',
+                'd',
+                'o',
+                'm',
+                'a',
+                'i',
+                'n',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0a,
+                0x01,
+                0x02, // scope: subtree
+                0x0a,
+                0x01,
+                0x03, // derefAliases: derefAlways
+                0x02,
+                0x01,
+                0x00, // sizeLimit: 0
+                0x02,
+                0x01,
+                0x00, // timeLimit: 0
+                0x01,
+                0x01,
+                0x00, // typesOnly: false
+                ( byte ) 0x87,
+                0x0b, // Present filter: (objectClass=*)
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'C',
+                'l',
+                'a',
+                's',
+                's',
+                0x30,
+                0x00, // Attributes = '*'
+                ( byte ) 0xa0,
+                0x45, // controls
+                0x30,
+                0x19,
+                0x04,
+                0x17, // control
+                '2',
+                '.',
+                '1',
+                '6',
+                '.',
+                '8',
+                '4',
+                '0',
+                '.',
+                '1',
+                '.',
+                '1',
+                '1',
+                '3',
+                '7',
+                '3',
+                '0',
+                '.',
+                '3',
+                '.',
+                '4',
+                '.',
+                '2',
+                0x30,
+                0x28,
+                0x04,
+                0x16, // control
+                '1',
+                '.',
+                '2',
+                '.',
+                '8',
+                '4',
+                '0',
+                '.',
+                '1',
+                '1',
+                '3',
+                '5',
+                '5',
+                '6',
+                '.',
+                '1',
+                '.',
+                '4',
+                '.',
+                '3',
+                '1',
+                '9',
+                0x01,
+                0x01,
+                ( byte ) 0xff, // criticality: false
+                0x04,
+                0x0b,
+                0x30,
+                0x09,
+                0x02,
+                0x01,
+                0x02,
+                0x04,
+                0x04,
+                0x47,
+                0x00,
+                0x00,
+                0x00, // value: pageSize=2
+            };
 
         Asn1Decoder ldapDecoder = new Asn1Decoder();
 
         // For Java6
         ByteBuffer streamJava6 = ByteBuffer.allocate( asn1BERJava6.length );
         streamJava6.put( asn1BERJava6 );
-        String decodedPduJava6 = Strings.dumpBytes(streamJava6.array());
+        String decodedPduJava6 = Strings.dumpBytes( streamJava6.array() );
         streamJava6.flip();
 
         // For Java5
         ByteBuffer streamJava5 = ByteBuffer.allocate( asn1BERJava5.length );
         streamJava5.put( asn1BERJava5 );
-        String decodedPduJava5 = Strings.dumpBytes(streamJava5.array());
+        String decodedPduJava5 = Strings.dumpBytes( streamJava5.array() );
 
         LdapMessageContainer<SearchRequestDecorator> ldapMessageContainer =
             new LdapMessageContainer<SearchRequestDecorator>( codec );
@@ -1159,8 +1933,8 @@ public class SearchRequestTest extends A
             // Check the length
             assertEquals( 0x81, bb.limit() );
 
-            String encodedPdu = Strings.dumpBytes(bb.array());
-            
+            String encodedPdu = Strings.dumpBytes( bb.array() );
+
             assertTrue( decodedPduJava5.equals( encodedPdu ) || decodedPduJava6.equals( encodedPdu ) );
         }
         catch ( EncoderException ee )
@@ -1198,8 +1972,32 @@ public class SearchRequestTest extends A
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x1F, // baseObject LDAPDN,
-                'u', 'i', 'd', '=', 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u', ',', 'd', 'c', '=', 'e', 'x', 'a',
-                'm', 'p', 'l', 'e', ',', 'd',
+                'u',
+                'i',
+                'd',
+                '=',
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
+                ',',
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
                 'c',
                 '=',
                 'c',
@@ -1221,9 +2019,14 @@ public class SearchRequestTest extends A
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
                 // sizeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03, ( byte ) 0xE8,
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8,
                 // timeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03,
+                0x02,
+                0x02,
+                0x03,
                 ( byte ) 0xE8,
                 0x01,
                 0x01,
@@ -1241,23 +2044,51 @@ public class SearchRequestTest extends A
                 // Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 'o',
+                0x04,
+                0x03,
+                't',
+                'o',
                 'p',
                 ( byte ) 0xA3,
                 0x14, // equalityMatch
                 // [3]
                 // Assertion,
                 // Assertion ::= SEQUENCE {
-                0x04, 0x08, '2', '.', '5', '.', '4',
+                0x04,
+                0x08,
+                '2',
+                '.',
+                '5',
+                '.',
+                '4',
                 '.',
                 '1',
                 '1', // attributeDesc
                 // AttributeDescription
                 // (LDAPString),
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x08, 'c', 'o', 'n', 't', 'a', 'c',
+                0x04,
+                0x08,
+                'c',
+                'o',
+                'n',
+                't',
+                'a',
+                'c',
                 't',
                 's',
                 ( byte ) 0xA2,
@@ -1269,20 +2100,65 @@ public class SearchRequestTest extends A
                 // Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x16, 'o', 'r', 'g', 'a', 'n', 'i', 'z', 'a', 't', 'i', 'o', 'n', 'a', 'l', 'U', 'n', 'i', 't',
-                'N', 'a', 'm', 'e',
+                0x04,
+                0x16,
+                'o',
+                'r',
+                'g',
+                'a',
+                'n',
+                'i',
+                'z',
+                'a',
+                't',
+                'i',
+                'o',
+                'n',
+                'a',
+                'l',
+                'U',
+                'n',
+                'i',
+                't',
+                'N',
+                'a',
+                'm',
+                'e',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 't', 't',
+                0x04,
+                0x03,
+                't',
+                't',
+                't',
                 // attributes AttributeDescriptionList }
-                0x30, 0x15, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x15, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x05, 'a', 't', 't', 'r', '0', // AttributeDescription
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '0', // AttributeDescription
                 // ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '1', // AttributeDescription
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '1', // AttributeDescription
                 // ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '2' // AttributeDescription ::=
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '2' // AttributeDescription ::=
             // LDAPString
-            } );
+        } );
 
         stream.flip();
 
@@ -1328,7 +2204,7 @@ public class SearchRequestTest extends A
         // (& (| (obectclass=top) (...
         List<ExprNode> orNodes = orFilter.getChildren();
         assertEquals( 2, orNodes.size() );
-        
+
         EqualityNode<?> equalityNode = ( EqualityNode<?> ) orNodes.get( 0 );
         assertNotNull( equalityNode );
 
@@ -1375,35 +2251,103 @@ public class SearchRequestTest extends A
             { 0x30, 0x5D, 0x02,
                 0x01,
                 0x04, // messageID
-                0x63, 0x33,
+                0x63,
+                0x33,
                 0x04,
                 0x13, // baseObject: dc=my-domain,dc=com
-                'd', 'c', '=', 'm', 'y', '-', 'd', 'o', 'm', 'a', 'i', 'n', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0a,
+                'd',
+                'c',
+                '=',
+                'm',
+                'y',
+                '-',
+                'd',
+                'o',
+                'm',
+                'a',
+                'i',
+                'n',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0a,
                 0x01,
                 0x02, // scope: subtree
-                0x0a, 0x01,
+                0x0a,
+                0x01,
                 0x03, // derefAliases: derefAlways
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x00, // sizeLimit: 0
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x00, // timeLimit: 0
-                0x01, 0x01,
+                0x01,
+                0x01,
                 0x00, // typesOnly: false
                 ( byte ) 0x87,
                 0x0b, // filter: (objectClass=*)
-                'o', 'b', 'j', 'e', 'c', 't', 'C', 'l', 'a', 's', 's', 0x30, 0x00, ( byte ) 0xa0,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'C',
+                'l',
+                'a',
+                's',
+                's',
+                0x30,
+                0x00,
+                ( byte ) 0xa0,
                 0x23, // controls
-                0x30, 0x21, 0x04, 0x17, '1', '.', '3', '.', '6', '.', '1', '.', '4', '.', '1', '.', '4', '2', '0', '3',
-                '.', '1', '.', '1', '0', '.', '1', // SubEntry OID
-                0x01, 0x01, ( byte ) 0xFF, // criticality: true
-                0x04, 0x03, 0x01, 0x01, ( byte ) 0xFF // SubEntry visibility
-            };
+                0x30,
+                0x21,
+                0x04,
+                0x17,
+                '1',
+                '.',
+                '3',
+                '.',
+                '6',
+                '.',
+                '1',
+                '.',
+                '4',
+                '.',
+                '1',
+                '.',
+                '4',
+                '2',
+                '0',
+                '3',
+                '.',
+                '1',
+                '.',
+                '1',
+                '0',
+                '.',
+                '1', // SubEntry OID
+                0x01,
+                0x01,
+                ( byte ) 0xFF, // criticality: true
+                0x04,
+                0x03,
+                0x01,
+                0x01,
+                ( byte ) 0xFF // SubEntry visibility
+        };
 
         Asn1Decoder ldapDecoder = new Asn1Decoder();
 
         ByteBuffer stream = ByteBuffer.allocate( asn1BER.length );
         stream.put( asn1BER );
-        String decodedPdu = Strings.dumpBytes(stream.array());
+        String decodedPdu = Strings.dumpBytes( stream.array() );
         stream.flip();
 
         LdapMessageContainer<SearchRequestDecorator> ldapMessageContainer =
@@ -1454,7 +2398,7 @@ public class SearchRequestTest extends A
             // Check the length
             assertEquals( 0x5F, bb.limit() );
 
-            String encodedPdu = Strings.dumpBytes(bb.array());
+            String encodedPdu = Strings.dumpBytes( bb.array() );
             assertEquals( decodedPdu, encodedPdu );
         }
         catch ( EncoderException ee )
@@ -1474,7 +2418,8 @@ public class SearchRequestTest extends A
     {
         byte[] asn1BER = new byte[]
             { 0x30, 0x05, 0x02, 0x01, 0x04, // messageID
-                0x63, 0x00 };
+                0x63,
+                0x00 };
 
         Asn1Decoder ldapDecoder = new Asn1Decoder();
 
@@ -1509,7 +2454,10 @@ public class SearchRequestTest extends A
     {
         byte[] asn1BER = new byte[]
             { 0x30, 0x07, 0x02, 0x01, 0x04, // messageID
-                0x63, 0x02, 0x04, 0x00 };
+                0x63,
+                0x02,
+                0x04,
+                0x00 };
 
         Asn1Decoder ldapDecoder = new Asn1Decoder();
 
@@ -1548,53 +2496,140 @@ public class SearchRequestTest extends A
         ByteBuffer stream = ByteBuffer.allocate( 0x6F );
         stream.put( new byte[]
             { 0x30, 0x6D, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01, 0x01, // messageID MessageID
-                0x63, 0x68, // CHOICE { ...,
+                0x02,
+                0x01,
+                0x01, // messageID MessageID
+                0x63,
+                0x68, // CHOICE { ...,
                 // searchRequest SearchRequest, ...
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
-                0x04, 0x00, // baseObject LDAPDN,
-                0x0A, 0x01, 0x01, // scope ENUMERATED {
+                0x04,
+                0x00, // baseObject LDAPDN,
+                0x0A,
+                0x01,
+                0x01, // scope ENUMERATED {
                 // baseObject (0),
                 // singleLevel (1),
                 // wholeSubtree (2) },
-                0x0A, 0x01, 0x03, // derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x03, // derefAliases ENUMERATED {
                 // neverDerefAliases (0),
                 // derefInSearching (1),
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
-                0x01, 0x01, ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
+                0x01,
+                0x01,
+                ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
                 // filter Filter,
-                ( byte ) 0xA0, 0x3C, // Filter ::= CHOICE {
+                ( byte ) 0xA0,
+                0x3C, // Filter ::= CHOICE {
                 // and [0] SET OF Filter,
-                ( byte ) 0xA1, 0x24, // or [1] SET of Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3]
+                ( byte ) 0xA1,
+                0x24, // or [1] SET of Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3]
                 // Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 'o', 'p', ( byte ) 0xA3, 0x0E, // equalityMatch [3] Assertion,
+                0x04,
+                0x03,
+                't',
+                'o',
+                'p',
+                ( byte ) 0xA3,
+                0x0E, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
-                0x04, 0x02, 'o', 'u', // attributeDesc AttributeDescription (LDAPString),
+                0x04,
+                0x02,
+                'o',
+                'u', // attributeDesc AttributeDescription (LDAPString),
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x08, 'c', 'o', 'n', 't', 'a', 'c', 't', 's', ( byte ) 0xA2, 0x14, // not [2] Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3] Assertion,
+                0x04,
+                0x08,
+                'c',
+                'o',
+                'n',
+                't',
+                'a',
+                'c',
+                't',
+                's',
+                ( byte ) 0xA2,
+                0x14, // not [2] Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 't', 't',
+                0x04,
+                0x03,
+                't',
+                't',
+                't',
                 // attributes AttributeDescriptionList }
-                0x30, 0x15, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x15, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x05, 'a', 't', 't', 'r', '0', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '1', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '2' // AttributeDescription ::= LDAPString
-            } );
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '0', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '1', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '2' // AttributeDescription ::= LDAPString
+        } );
 
-        String decodedPdu = Strings.dumpBytes(stream.array());
+        String decodedPdu = Strings.dumpBytes( stream.array() );
         stream.flip();
 
         // Allocate a BindRequest Container
@@ -1639,7 +2674,7 @@ public class SearchRequestTest extends A
         // (& (| (obectclass=top) (...
         List<ExprNode> orNodes = orFilter.getChildren();
         assertEquals( 2, orNodes.size() );
-        
+
         EqualityNode<?> equalityNode = ( EqualityNode<?> ) orNodes.get( 0 );
         assertNotNull( equalityNode );
 
@@ -1681,7 +2716,7 @@ public class SearchRequestTest extends A
             // Check the length
             assertEquals( 0x6F, bb.limit() );
 
-            String encodedPdu = Strings.dumpBytes(bb.array());
+            String encodedPdu = Strings.dumpBytes( bb.array() );
 
             assertEquals( encodedPdu.substring( 0, 0x6F ), decodedPdu.substring( 0, 0x6F ) );
         }
@@ -1705,7 +2740,8 @@ public class SearchRequestTest extends A
         stream.put( new byte[]
             { 0x30, ( byte ) 0x81,
                 ( byte ) 0x8D, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x01, // messageID MessageID
                 0x63,
                 ( byte ) 0x81,
@@ -1714,47 +2750,160 @@ public class SearchRequestTest extends A
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x1F, // baseObject LDAPDN,
-                'u', 'i', 'd', ':', 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u', ',', 'd', 'c', '=', 'e', 'x', 'a',
-                'm', 'p', 'l', 'e', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0A, 0x01, 0x01, // scope ENUMERATED {
+                'u',
+                'i',
+                'd',
+                ':',
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
+                ',',
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0A,
+                0x01,
+                0x01, // scope ENUMERATED {
                 // baseObject (0),
                 // singleLevel (1),
                 // wholeSubtree (2) },
-                0x0A, 0x01, 0x03, // derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x03, // derefAliases ENUMERATED {
                 // neverDerefAliases (0),
                 // derefInSearching (1),
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
-                0x01, 0x01, ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
+                0x01,
+                0x01,
+                ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
                 // filter Filter,
-                ( byte ) 0xA0, 0x3C, // Filter ::= CHOICE {
+                ( byte ) 0xA0,
+                0x3C, // Filter ::= CHOICE {
                 // and [0] SET OF Filter,
-                ( byte ) 0xA1, 0x24, // or [1] SET of Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3]
+                ( byte ) 0xA1,
+                0x24, // or [1] SET of Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3]
                 // Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 'o', 'p', ( byte ) 0xA3, 0x0E, // equalityMatch [3] Assertion,
+                0x04,
+                0x03,
+                't',
+                'o',
+                'p',
+                ( byte ) 0xA3,
+                0x0E, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
-                0x04, 0x02, 'o', 'u', // attributeDesc AttributeDescription (LDAPString),
+                0x04,
+                0x02,
+                'o',
+                'u', // attributeDesc AttributeDescription (LDAPString),
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x08, 'c', 'o', 'n', 't', 'a', 'c', 't', 's', ( byte ) 0xA2, 0x14, // not [2] Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3] Assertion,
+                0x04,
+                0x08,
+                'c',
+                'o',
+                'n',
+                't',
+                'a',
+                'c',
+                't',
+                's',
+                ( byte ) 0xA2,
+                0x14, // not [2] Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 't', 't',
+                0x04,
+                0x03,
+                't',
+                't',
+                't',
                 // attributes AttributeDescriptionList }
-                0x30, 0x15, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x15, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x05, 'a', 't', 't', 'r', '0', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '1', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '2' // AttributeDescription ::= LDAPString
-            } );
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '0', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '1', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '2' // AttributeDescription ::= LDAPString
+        } );
 
         stream.flip();
 
@@ -1789,10 +2938,43 @@ public class SearchRequestTest extends A
         byte[] asn1BER = new byte[]
             { 0x30, 0x28, 0x02, 0x01,
                 0x04, // messageID
-                0x63, 0x23, 0x04,
+                0x63,
+                0x23,
+                0x04,
                 0x1F, // baseObject LDAPDN,
-                'u', 'i', 'd', '=', 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u', ',', 'd', 'c', '=', 'e', 'x', 'a',
-                'm', 'p', 'l', 'e', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0A, 0x00 };
+                'u',
+                'i',
+                'd',
+                '=',
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
+                ',',
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0A,
+                0x00 };
 
         Asn1Decoder ldapDecoder = new Asn1Decoder();
 
@@ -1831,7 +3013,8 @@ public class SearchRequestTest extends A
         stream.put( new byte[]
             { 0x30, ( byte ) 0x81,
                 ( byte ) 0x8D, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x01, // messageID MessageID
                 0x63,
                 ( byte ) 0x81,
@@ -1840,47 +3023,160 @@ public class SearchRequestTest extends A
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x1F, // baseObject LDAPDN,
-                'u', 'i', 'd', ':', 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u', ',', 'd', 'c', '=', 'e', 'x', 'a',
-                'm', 'p', 'l', 'e', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0A, 0x01, 0x03, // scope ENUMERATED {
+                'u',
+                'i',
+                'd',
+                ':',
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
+                ',',
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0A,
+                0x01,
+                0x03, // scope ENUMERATED {
                 // baseObject (0),
                 // singleLevel (1),
                 // wholeSubtree (2) },
-                0x0A, 0x01, 0x03, // derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x03, // derefAliases ENUMERATED {
                 // neverDerefAliases (0),
                 // derefInSearching (1),
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
-                0x01, 0x01, ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
+                0x01,
+                0x01,
+                ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
                 // filter Filter,
-                ( byte ) 0xA0, 0x3C, // Filter ::= CHOICE {
+                ( byte ) 0xA0,
+                0x3C, // Filter ::= CHOICE {
                 // and [0] SET OF Filter,
-                ( byte ) 0xA1, 0x24, // or [1] SET of Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3]
+                ( byte ) 0xA1,
+                0x24, // or [1] SET of Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3]
                 // Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 'o', 'p', ( byte ) 0xA3, 0x0E, // equalityMatch [3] Assertion,
+                0x04,
+                0x03,
+                't',
+                'o',
+                'p',
+                ( byte ) 0xA3,
+                0x0E, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
-                0x04, 0x02, 'o', 'u', // attributeDesc AttributeDescription (LDAPString),
+                0x04,
+                0x02,
+                'o',
+                'u', // attributeDesc AttributeDescription (LDAPString),
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x08, 'c', 'o', 'n', 't', 'a', 'c', 't', 's', ( byte ) 0xA2, 0x14, // not [2] Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3] Assertion,
+                0x04,
+                0x08,
+                'c',
+                'o',
+                'n',
+                't',
+                'a',
+                'c',
+                't',
+                's',
+                ( byte ) 0xA2,
+                0x14, // not [2] Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 't', 't',
+                0x04,
+                0x03,
+                't',
+                't',
+                't',
                 // attributes AttributeDescriptionList }
-                0x30, 0x15, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x15, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x05, 'a', 't', 't', 'r', '0', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '1', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '2' // AttributeDescription ::= LDAPString
-            } );
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '0', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '1', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '2' // AttributeDescription ::= LDAPString
+        } );
 
         stream.flip();
 
@@ -1911,10 +3207,46 @@ public class SearchRequestTest extends A
         byte[] asn1BER = new byte[]
             { 0x30, 0x2B, 0x02, 0x01,
                 0x04, // messageID
-                0x63, 0x26, 0x04,
+                0x63,
+                0x26,
+                0x04,
                 0x1F, // baseObject LDAPDN,
-                'u', 'i', 'd', '=', 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u', ',', 'd', 'c', '=', 'e', 'x', 'a',
-                'm', 'p', 'l', 'e', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0A, 0x01, 0x00, 0x0A, 0x00 };
+                'u',
+                'i',
+                'd',
+                '=',
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
+                ',',
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0A,
+                0x01,
+                0x00,
+                0x0A,
+                0x00 };
 
         Asn1Decoder ldapDecoder = new Asn1Decoder();
 
@@ -1953,7 +3285,8 @@ public class SearchRequestTest extends A
         stream.put( new byte[]
             { 0x30, ( byte ) 0x81,
                 ( byte ) 0x8D, // LDAPMessage ::=SEQUENCE {
-                0x02, 0x01,
+                0x02,
+                0x01,
                 0x01, // messageID MessageID
                 0x63,
                 ( byte ) 0x81,
@@ -1962,47 +3295,160 @@ public class SearchRequestTest extends A
                 // SearchRequest ::= APPLICATION[3] SEQUENCE {
                 0x04,
                 0x1F, // baseObject LDAPDN,
-                'u', 'i', 'd', ':', 'a', 'k', 'a', 'r', 'a', 's', 'u', 'l', 'u', ',', 'd', 'c', '=', 'e', 'x', 'a',
-                'm', 'p', 'l', 'e', ',', 'd', 'c', '=', 'c', 'o', 'm', 0x0A, 0x01, 0x01, // scope ENUMERATED {
+                'u',
+                'i',
+                'd',
+                ':',
+                'a',
+                'k',
+                'a',
+                'r',
+                'a',
+                's',
+                'u',
+                'l',
+                'u',
+                ',',
+                'd',
+                'c',
+                '=',
+                'e',
+                'x',
+                'a',
+                'm',
+                'p',
+                'l',
+                'e',
+                ',',
+                'd',
+                'c',
+                '=',
+                'c',
+                'o',
+                'm',
+                0x0A,
+                0x01,
+                0x01, // scope ENUMERATED {
                 // baseObject (0),
                 // singleLevel (1),
                 // wholeSubtree (2) },
-                0x0A, 0x01, 0x04, // derefAliases ENUMERATED {
+                0x0A,
+                0x01,
+                0x04, // derefAliases ENUMERATED {
                 // neverDerefAliases (0),
                 // derefInSearching (1),
                 // derefFindingBaseObj (2),
                 // derefAlways (3) },
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
-                0x02, 0x02, 0x03, ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
-                0x01, 0x01, ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // sizeLimit INTEGER (0 .. maxInt), (1000)
+                0x02,
+                0x02,
+                0x03,
+                ( byte ) 0xE8, // timeLimit INTEGER (0 .. maxInt), (1000)
+                0x01,
+                0x01,
+                ( byte ) 0xFF, // typesOnly  BOOLEAN, (TRUE)
                 // filter Filter,
-                ( byte ) 0xA0, 0x3C, // Filter ::= CHOICE {
+                ( byte ) 0xA0,
+                0x3C, // Filter ::= CHOICE {
                 // and [0] SET OF Filter,
-                ( byte ) 0xA1, 0x24, // or [1] SET of Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3]
+                ( byte ) 0xA1,
+                0x24, // or [1] SET of Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3]
                 // Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 'o', 'p', ( byte ) 0xA3, 0x0E, // equalityMatch [3] Assertion,
+                0x04,
+                0x03,
+                't',
+                'o',
+                'p',
+                ( byte ) 0xA3,
+                0x0E, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
-                0x04, 0x02, 'o', 'u', // attributeDesc AttributeDescription (LDAPString),
+                0x04,
+                0x02,
+                'o',
+                'u', // attributeDesc AttributeDescription (LDAPString),
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x08, 'c', 'o', 'n', 't', 'a', 'c', 't', 's', ( byte ) 0xA2, 0x14, // not [2] Filter,
-                ( byte ) 0xA3, 0x12, // equalityMatch [3] Assertion,
+                0x04,
+                0x08,
+                'c',
+                'o',
+                'n',
+                't',
+                'a',
+                'c',
+                't',
+                's',
+                ( byte ) 0xA2,
+                0x14, // not [2] Filter,
+                ( byte ) 0xA3,
+                0x12, // equalityMatch [3] Assertion,
                 // Assertion ::= SEQUENCE {
                 // attributeDesc AttributeDescription (LDAPString),
-                0x04, 0x0B, 'o', 'b', 'j', 'e', 'c', 't', 'c', 'l', 'a', 's', 's',
+                0x04,
+                0x0B,
+                'o',
+                'b',
+                'j',
+                'e',
+                'c',
+                't',
+                'c',
+                'l',
+                'a',
+                's',
+                's',
                 // assertionValue AssertionValue (OCTET STRING) }
-                0x04, 0x03, 't', 't', 't',
+                0x04,
+                0x03,
+                't',
+                't',
+                't',
                 // attributes AttributeDescriptionList }
-                0x30, 0x15, // AttributeDescriptionList ::= SEQUENCE OF
+                0x30,
+                0x15, // AttributeDescriptionList ::= SEQUENCE OF
                 // AttributeDescription
-                0x04, 0x05, 'a', 't', 't', 'r', '0', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '1', // AttributeDescription ::= LDAPString
-                0x04, 0x05, 'a', 't', 't', 'r', '2' // AttributeDescription ::= LDAPString
-            } );
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '0', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '1', // AttributeDescription ::= LDAPString
+                0x04,
+                0x05,
+                'a',
+                't',
+                't',
+                'r',
+                '2' // AttributeDescription ::= LDAPString
+        } );
 
         stream.flip();
 
@@ -2033,10 +3479,49 @@ public class SearchRequestTest extends A
         byte[] asn1BER = new byte[]
             { 0x30, 0x2E, 0x02, 0x01,

[... 2925 lines stripped ...]