directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject [directory-ldap-api] branch master updated: Fixed Javadoc
Date Wed, 01 Aug 2018 12:24:26 GMT
This is an automated email from the ASF dual-hosted git repository.

elecharny pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/directory-ldap-api.git


The following commit(s) were added to refs/heads/master by this push:
     new 20f7500  Fixed Javadoc
20f7500 is described below

commit 20f750002cbd9336d87d35ae14dad05e88f20ded
Author: Emmanuel L├ęcharny <elecharny@symas.com>
AuthorDate: Wed Aug 1 14:24:22 2018 +0200

    Fixed Javadoc
---
 .../ldap/model/ldif/SchemaAwareLdifReaderTest.java | 268 ++++++++++-----------
 ldap/model/src/main/antlr/distinguishedName.g      |  24 +-
 .../api/ldap/model/cursor/ListCursor.java          |   4 +-
 .../api/ldap/model/entry/AttributeUtils.java       |  22 +-
 .../api/ldap/model/entry/DefaultAttribute.java     |  17 +-
 .../api/ldap/model/entry/DefaultEntry.java         |  27 ++-
 .../directory/api/ldap/model/entry/Value.java      |   3 -
 .../LdapAuthenticationNotSupportedException.java   |   7 +-
 .../LdapInvalidAttributeValueException.java        |   1 +
 .../model/exception/LdapInvalidDnException.java    |   1 +
 .../exception/LdapSchemaViolationException.java    |   1 +
 .../exception/LdapServiceUnavailableException.java |   1 +
 .../exception/LdapUnwillingToPerformException.java |   1 +
 .../api/ldap/model/filter/FilterParser.java        |  93 ++++++-
 .../directory/api/ldap/model/filter/LeafNode.java  |  13 +-
 .../directory/api/ldap/model/ldif/LdifControl.java |   2 +-
 .../directory/api/ldap/model/ldif/LdifReader.java  |   4 +-
 .../model/message/controls/PersistentSearch.java   |   2 +-
 .../api/ldap/model/name/FastDnParser.java          |   4 +-
 .../apache/directory/api/ldap/model/name/Rdn.java  |  10 +-
 .../directory/api/ldap/model/password/BCrypt.java  |  14 +-
 .../model/schema/parsers/OpenLdapSchemaParser.java |  71 +++---
 .../directory/api/ldap/model/url/LdapUrl.java      |  23 +-
 .../api/ldap/model/ldif/LdifReaderTest.java        |   2 +-
 24 files changed, 374 insertions(+), 241 deletions(-)

diff --git a/ldap/model/src/test/java/org/apache/directory/api/ldap/model/ldif/LdifReaderTest.java b/integ/src/test/java/org/apache/directory/api/ldap/model/ldif/SchemaAwareLdifReaderTest.java
similarity index 92%
copy from ldap/model/src/test/java/org/apache/directory/api/ldap/model/ldif/LdifReaderTest.java
copy to integ/src/test/java/org/apache/directory/api/ldap/model/ldif/SchemaAwareLdifReaderTest.java
index ad88917..aab945e 100644
--- a/ldap/model/src/test/java/org/apache/directory/api/ldap/model/ldif/LdifReaderTest.java
+++ b/integ/src/test/java/org/apache/directory/api/ldap/model/ldif/SchemaAwareLdifReaderTest.java
@@ -43,7 +43,10 @@ import org.apache.directory.api.ldap.model.entry.Attribute;
 import org.apache.directory.api.ldap.model.entry.Modification;
 import org.apache.directory.api.ldap.model.entry.ModificationOperation;
 import org.apache.directory.api.ldap.model.message.Control;
+import org.apache.directory.api.ldap.model.schema.SchemaManager;
+import org.apache.directory.api.ldap.schema.manager.impl.DefaultSchemaManager;
 import org.apache.directory.api.util.Strings;
+import org.junit.Before;
 import org.junit.BeforeClass;
 import org.junit.Test;
 import org.junit.runner.RunWith;
@@ -59,12 +62,14 @@ import com.mycila.junit.concurrent.ConcurrentJunitRunner;
  */
 @RunWith(ConcurrentJunitRunner.class)
 @Concurrency()
-public class LdifReaderTest
+public class SchemaAwareLdifReaderTest
 {
     private static byte[] data;
 
     private static File HJENSEN_JPEG_FILE = null;
     private static File FIONA_JPEG_FILE = null;
+    
+    private SchemaManager schemaManager;
 
 
     private static File createFile( String name, byte[] data ) throws IOException
@@ -84,8 +89,8 @@ public class LdifReaderTest
 
         return jpeg;
     }
-
-
+    
+    
     /**
      * Create a file to be used by ":<" values
      */
@@ -102,6 +107,16 @@ public class LdifReaderTest
         HJENSEN_JPEG_FILE = createFile( "hjensen", data );
         FIONA_JPEG_FILE = createFile( "fiona", data );
     }
+    
+
+    /**
+     * Initialize the SchemaManager
+     */
+    @Before
+    public void init()
+    {
+        schemaManager = new DefaultSchemaManager();
+    }
 
 
     @Test
@@ -109,7 +124,7 @@ public class LdifReaderTest
     {
         String ldif = null;
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -122,7 +137,7 @@ public class LdifReaderTest
     {
         String ldif = "";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -135,7 +150,7 @@ public class LdifReaderTest
     {
         String ldif = "\n\n\r\r\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -153,7 +168,7 @@ public class LdifReaderTest
                 " is is still a comment\n" +
                 "\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -174,7 +189,7 @@ public class LdifReaderTest
                 " 1\n" +
                 "# end";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -198,7 +213,7 @@ public class LdifReaderTest
                 "dependencies:\n" +
                 "envVars:";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -233,7 +248,7 @@ public class LdifReaderTest
                 "\n" +
                 "# end";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -260,7 +275,7 @@ public class LdifReaderTest
                 "dependencies:\n" +
                 "envVars:";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
@@ -309,7 +324,7 @@ public class LdifReaderTest
 
     private void testReaderAttrIdCaseInsensitive( String ldif ) throws Exception
     {
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         List<LdifEntry> entries = reader.parseLdif( ldif );
         assertNotNull( entries );
@@ -355,7 +370,7 @@ public class LdifReaderTest
                 "control: 1.2.840.113556.1.4.805 true\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         try
         {
@@ -398,7 +413,7 @@ public class LdifReaderTest
                 "dn: ou=Product Development, dc=airius, dc=com\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         try
         {
@@ -442,7 +457,7 @@ public class LdifReaderTest
                 "dependencies:\n" +
                 "envVars:\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         try
         {
@@ -485,7 +500,7 @@ public class LdifReaderTest
                 "dependencies:\n" +
                 "envVars:\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         try
         {
@@ -513,10 +528,9 @@ public class LdifReaderTest
                 "objectClass: top\n" +
                 "objectClass: apApplication\n" +
                 "displayName: app1   \n" +
-                "dependencies:\n" +
-                "envVars:";
+                "userPassword:";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -537,10 +551,7 @@ public class LdifReaderTest
         attr = entry.get( "displayname" );
         assertTrue( attr.contains( "app1" ) );
 
-        attr = entry.get( "dependencies" );
-        assertEquals( "", attr.get().getValue() );
-
-        attr = entry.get( "envvars" );
+        attr = entry.get( "userPassword" );
         assertEquals( "", attr.get().getValue() );
     }
 
@@ -557,12 +568,11 @@ public class LdifReaderTest
                 "objectClass: apApplication\n" +
                 "displayName: app1\n" +
                 "serviceType: http\n" +
-                "dependencies:\n" +
+                "userPassword:\n" +
                 "httpHeaders:\n" +
-                "startupOptions:\n" +
-                "envVars:";
+                "startupOptions:";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -583,10 +593,7 @@ public class LdifReaderTest
         attr = entry.get( "displayname" );
         assertTrue( attr.contains( "app1" ) );
 
-        attr = entry.get( "dependencies" );
-        assertEquals( "", attr.get().getValue() );
-
-        attr = entry.get( "envvars" );
+        attr = entry.get( "userPassword" );
         assertEquals( "", attr.get().getValue() );
     }
 
@@ -603,12 +610,11 @@ public class LdifReaderTest
                 "objectClass: apApplication\n" +
                 "displayName: app1\n" +
                 "serviceType: http\n" +
-                "dependencies:\n" +
+                "userPassword:\n" +
                 "httpHeaders:\n" +
-                "startupOptions:\n" +
-                "envVars:";
+                "startupOptions:";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -629,10 +635,7 @@ public class LdifReaderTest
         attr = entry.get( "displayname" );
         assertTrue( attr.contains( "app1" ) );
 
-        attr = entry.get( "dependencies" );
-        assertEquals( "", attr.get().getValue() );
-
-        attr = entry.get( "envvars" );
+        attr = entry.get( "userPassword" );
         assertEquals( "", attr.get().getValue() );
     }
 
@@ -648,12 +651,11 @@ public class LdifReaderTest
                 "objectClass: apApplication\n" +
                 "displayName: app1\n" +
                 "serviceType: http\n" +
-                "dependencies:\n" +
+                "userPassword:\n" +
                 "httpHeaders:\n" +
-                "startupOptions:\n" +
-                "envVars:";
+                "startupOptions:";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -665,7 +667,7 @@ public class LdifReaderTest
         assertEquals( "cn=app1,ou=applications,ou=conf,dc=apache,dc=org", entry.getDn().getName() );
 
         Attribute attr = entry.get( "cn" );
-        assertTrue( attr.contains( "Emmanuel L\u00e9charny".getBytes( StandardCharsets.UTF_8 ) ) );
+        assertTrue( attr.contains( "Emmanuel L\u00e9charny" ) );
 
         attr = entry.get( "objectclass" );
         assertTrue( attr.contains( "top" ) );
@@ -674,10 +676,7 @@ public class LdifReaderTest
         attr = entry.get( "displayname" );
         assertTrue( attr.contains( "app1" ) );
 
-        attr = entry.get( "dependencies" );
-        assertEquals( "", attr.get().getValue() );
-
-        attr = entry.get( "envvars" );
+        attr = entry.get( "userPassword" );
         assertEquals( "", attr.get().getValue() );
     }
 
@@ -694,12 +693,11 @@ public class LdifReaderTest
                 "objectClass: apApplication\n" +
                 "displayName: app1\n" +
                 "serviceType: http\n" +
-                "dependencies:\n" +
+                "userPassword:\n" +
                 "httpHeaders:\n" +
-                "startupOptions:\n" +
-                "envVars:";
+                "startupOptions:";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -711,7 +709,7 @@ public class LdifReaderTest
         assertEquals( "cn=app1,ou=applications,ou=conf,dc=apache,dc=org", entry.getDn().getName() );
 
         Attribute attr = entry.get( "cn" );
-        assertTrue( attr.contains( "Emmanuel L\u00e9charny  ".getBytes( StandardCharsets.UTF_8 ) ) );
+        assertTrue( attr.contains( "Emmanuel L\u00e9charny  " ) );
 
         attr = entry.get( "objectclass" );
         assertTrue( attr.contains( "top" ) );
@@ -720,10 +718,7 @@ public class LdifReaderTest
         attr = entry.get( "displayname" );
         assertTrue( attr.contains( "app1" ) );
 
-        attr = entry.get( "dependencies" );
-        assertEquals( "", attr.get().getValue() );
-
-        attr = entry.get( "envvars" );
+        attr = entry.get( "userPassword" );
         assertEquals( "", attr.get().getValue() );
     }
 
@@ -753,7 +748,7 @@ public class LdifReaderTest
                 "sn: Jensen\n" +
                 "telephonenumber: +1 408 555 1212";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -829,7 +824,7 @@ public class LdifReaderTest
                 " rch of perfect sailing conditions.\n" +
                 "title:Product Manager, Rod and Reel Division";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -888,7 +883,7 @@ public class LdifReaderTest
                 " VyIGluIGl0IChhIENSKS4NICBCeSB0aGUgd2F5LCB5b3Ugc2hvdWxkIHJlYWxseSBnZXQg\n" +
                 " b3V0IG1vcmUu";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -920,8 +915,8 @@ public class LdifReaderTest
 
         attr = entry.get( "description" );
         assertTrue( attr
-            .contains( "What a careful reader you are!  This value is base-64-encoded because it has a control character in it (a CR).\r  By the way, you should really get out more."
-                .getBytes( StandardCharsets.UTF_8 ) ) );
+            .contains( "What a careful reader you are!  This value is base-64-encoded because it has a control character in it (a CR).\r" + 
+                        "  By the way, you should really get out more." ) );
     }
 
 
@@ -944,7 +939,7 @@ public class LdifReaderTest
                 " VyIGluIGl0IChhIENSKS4NICBCeSB0aGUgd2F5LCB5b3Ugc2hvdWxkIHJlYWxseSBnZXQg\n" +
                 " b3V0IG1vcmUu  ";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -976,8 +971,9 @@ public class LdifReaderTest
 
         attr = entry.get( "description" );
         assertTrue( attr
-            .contains( "What a careful reader you are!  This value is base-64-encoded because it has a control character in it (a CR).\r  By the way, you should really get out more."
-                .getBytes( StandardCharsets.UTF_8 ) ) );
+            .contains( "What a careful reader you are!  This value is base-64-encoded because it has a control character "
+                    + "in it (a CR).\r  By the way, you should really get out more."
+                 ) );
     }
 
 
@@ -1085,7 +1081,7 @@ public class LdifReaderTest
                 "cn;lang-en: Rodney Ogasawara\n" +
                 "title;lang-en: Sales, Director\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1178,7 +1174,7 @@ public class LdifReaderTest
                 HJENSEN_JPEG_FILE.getAbsolutePath() +
                 "\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1209,8 +1205,8 @@ public class LdifReaderTest
             }
             else if ( "jpegphoto".equalsIgnoreCase( values[i][0] ) )
             {
-                Attribute attr = entry.get( values[i][0] );
-                assertEquals( Strings.dumpBytes( data ), Strings.dumpBytes( attr.getBytes() ) );
+                // We can't have a jpegPhoto with a null value
+                assertNull( entry.get( values[i][0] ) );
             }
             else
             {
@@ -1247,7 +1243,7 @@ public class LdifReaderTest
                 HJENSEN_JPEG_FILE.getAbsolutePath() +
                 "\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         reader.setSizeLimit( 128 );
         reader.close();
 
@@ -1343,7 +1339,7 @@ public class LdifReaderTest
                 "delete: description\n" +
                 "-\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1465,7 +1461,7 @@ public class LdifReaderTest
         item = modifs.get( 2 );
         assertEquals( ModificationOperation.REPLACE_ATTRIBUTE, item.getOperation() );
 
-        assertEquals( values[4][3][0], item.getAttribute().getId() );
+        assertEquals( values[4][3][0], item.getAttribute().getUpId() );
         assertTrue( item.getAttribute().contains( values[4][3][1], values[4][3][2] ) );
 
         // "delete: facsimiletelephonenumber"
@@ -1509,7 +1505,7 @@ public class LdifReaderTest
                 "control: 1.2.840.113556.1.4.805 true\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1539,7 +1535,7 @@ public class LdifReaderTest
                 "control: 1.2.840.113556.1.4.805\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1569,7 +1565,7 @@ public class LdifReaderTest
                 "control: 1.2.840.113556.1.4.805:control-value\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1600,7 +1596,7 @@ public class LdifReaderTest
                 "control: true\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         try
         {
@@ -1631,7 +1627,7 @@ public class LdifReaderTest
                 "control: 1.2.840.113A556.1.4.805 true\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         try
         {
@@ -1684,7 +1680,7 @@ public class LdifReaderTest
                 "objectclass: organizationalunit\n" +
                 "ou: Users";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
@@ -1782,7 +1778,7 @@ public class LdifReaderTest
                 +
                 "prescriptiveACI: { identificationTag \"browseRoot\", precedence 100, authenticationLevel none, itemOrUserFirst userFirst: { userClasses { allUsers }, userPermissions { { protectedItems {entry}, grantsAndDenials { grantReturnDN, grantBrowse } } } } }\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1821,7 +1817,7 @@ public class LdifReaderTest
                 HJENSEN_JPEG_FILE.getAbsolutePath() +
                 "\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1840,9 +1836,9 @@ public class LdifReaderTest
             "version:   1\n" +
                 "dn: dc=example,dc=com\n" +
                 "changetype: add\n" +
-                "attr1: ATTR1\n";
+                "cn: ATTR1\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1858,7 +1854,7 @@ public class LdifReaderTest
 
         assertEquals( 1, entry.getEntry().size() );
 
-        Attribute attr = entry.get( "attr1" );
+        Attribute attr = entry.get( "cn" );
         assertTrue( attr.contains( "ATTR1" ) );
     }
 
@@ -1870,10 +1866,10 @@ public class LdifReaderTest
             "version:   1\n" +
                 "dn: dc=example,dc=com\n" +
                 "changetype: add\n" +
-                "attr1: ATTR1\n" +
-                "attr1: ATTR2\n";
+                "cn: ATTR1\n" +
+                "cn: ATTR2\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1889,7 +1885,7 @@ public class LdifReaderTest
 
         assertEquals( 1, entry.getEntry().size() );
 
-        Attribute attr = entry.get( "attr1" );
+        Attribute attr = entry.get( "cn" );
         assertEquals( 2, attr.size() );
         assertTrue( attr.contains( "ATTR1" ) );
         assertTrue( attr.contains( "ATTR2" ) );
@@ -1903,11 +1899,11 @@ public class LdifReaderTest
             "version:   1\n" +
                 "dn: dc=example,dc=com\n" +
                 "changetype: add\n" +
-                "attr1: ATTR1\n" +
-                "attr1: ATTR2\n" +
-                "attr2: ATTR1\n";
+                "cn: ATTR1\n" +
+                "cn: ATTR2\n" +
+                "sn: ATTR1\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1923,12 +1919,12 @@ public class LdifReaderTest
 
         assertEquals( 2, entry.getEntry().size() );
 
-        Attribute attr = entry.get( "attr1" );
+        Attribute attr = entry.get( "cn" );
         assertEquals( 2, attr.size() );
         assertTrue( attr.contains( "ATTR1" ) );
         assertTrue( attr.contains( "ATTR2" ) );
 
-        Attribute attr2 = entry.get( "attr2" );
+        Attribute attr2 = entry.get( "sn" );
         assertEquals( 1, attr2.size() );
         assertTrue( attr2.contains( "ATTR1" ) );
     }
@@ -1942,7 +1938,7 @@ public class LdifReaderTest
                 "dn: dc=example,dc=com\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -1967,7 +1963,7 @@ public class LdifReaderTest
                 "control: 1.1.1\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -2006,7 +2002,7 @@ public class LdifReaderTest
                 "control: 1.1.6 true::RW1tYW51ZWwgTMOpY2hhcm55\n" +
                 "changetype: delete\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -2076,7 +2072,7 @@ public class LdifReaderTest
                 "changetype: delete\n" +
                 "attr1: test";
 
-        try ( LdifReader reader = new LdifReader() )
+        try ( LdifReader reader = new LdifReader( schemaManager ) )
         {
             reader.parseLdif( ldif );
         }
@@ -2092,7 +2088,7 @@ public class LdifReaderTest
                 "control: 1.1.1\n" +
                 "attr1: test";
 
-        try ( LdifReader reader = new LdifReader() )
+        try ( LdifReader reader = new LdifReader( schemaManager ) )
         {
             reader.parseLdif( ldif );
         }
@@ -2121,7 +2117,7 @@ public class LdifReaderTest
                 "userPassword:\n" +
                 "-";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -2168,7 +2164,7 @@ public class LdifReaderTest
                 comment +
                 ldif1 + "\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
 
         List<LdifEntry> lstEntries = null;
 
@@ -2218,7 +2214,7 @@ public class LdifReaderTest
         data = new byte[rafEntry1.getLengthBeforeParsing()];
         raf.read( data, ( int ) rafEntry1.getOffset(), data.length );
 
-        reader = new LdifReader();
+        reader = new LdifReader( schemaManager );
         LdifEntry reReadeRafEntry1 = reader.parseLdif( new String( data, Charset.defaultCharset() ) ).get( 0 );
         assertNotNull( reReadeRafEntry1 );
         assertEquals( rafEntry1.getOffset(), reReadeRafEntry1.getOffset() );
@@ -2230,7 +2226,7 @@ public class LdifReaderTest
         data = new byte[rafEntry2.getLengthBeforeParsing()];
         raf.readFully( data, 0, data.length );
 
-        reader = new LdifReader();
+        reader = new LdifReader( schemaManager );
         LdifEntry reReadeRafEntry2 = reader.parseLdif( new String( data, Charset.defaultCharset() ) ).get( 0 );
         assertNotNull( reReadeRafEntry2 );
         assertEquals( rafEntry2.getLengthBeforeParsing(), reReadeRafEntry2.getLengthBeforeParsing() );
@@ -2250,7 +2246,7 @@ public class LdifReaderTest
                 "changetype: delete\n" +
                 "attr1: test";
 
-        try ( LdifReader reader = new LdifReader() )
+        try ( LdifReader reader = new LdifReader( schemaManager ) )
         {
             try
             {
@@ -2270,7 +2266,7 @@ public class LdifReaderTest
                 "changetype: delete\n" +
                 "attr1: test";
 
-        try ( LdifReader reader = new LdifReader() )
+        try ( LdifReader reader = new LdifReader( schemaManager ) )
         {
             try
             {
@@ -2291,7 +2287,7 @@ public class LdifReaderTest
                 "changetype: delete\n" +
                 "attr1: test";
         
-        try ( LdifReader reader = new LdifReader() )
+        try ( LdifReader reader = new LdifReader( schemaManager ) )
         {
             try
             {
@@ -2322,7 +2318,7 @@ public class LdifReaderTest
                 "dependencies:\n" +
                 "envVars:";
         
-        try ( LdifReader reader = new LdifReader() )
+        try ( LdifReader reader = new LdifReader( schemaManager ) )
         {
             try
             {
@@ -2344,14 +2340,13 @@ public class LdifReaderTest
         String ldif =
             "version:   1\n" +
                 "dn:\n" +
-                "cn: app1\n" +
+                "cn:: YXBwMQ==\n" +
                 "objectClass: top\n" +
                 "objectClass: apApplication\n" +
                 "displayName: app1   \n" +
-                "dependencies:\n" +
-                "envVars:";
+                "userPassword: test";
 
-        try ( LdifReader reader = new LdifReader() )
+        try ( LdifReader reader = new LdifReader( schemaManager ) )
         {
             List<LdifEntry> entries = reader.parseLdif( ldif );
     
@@ -2363,6 +2358,12 @@ public class LdifReaderTest
             assertEquals( "", entry.getDn().getName() );
     
             Attribute attr = entry.get( "cn" );
+            
+            if ( attr.isHumanReadable() )
+            {
+                String cn = attr.getString();
+            }
+            
             assertTrue( attr.contains( "app1" ) );
     
             attr = entry.get( "objectclass" );
@@ -2372,11 +2373,8 @@ public class LdifReaderTest
             attr = entry.get( "displayname" );
             assertTrue( attr.contains( "app1" ) );
     
-            attr = entry.get( "dependencies" );
-            assertEquals( "", attr.get().getValue() );
-    
-            attr = entry.get( "envvars" );
-            assertEquals( "", attr.get().getValue() );
+            attr = entry.get( "userPassword" );
+            assertEquals( "test", attr.get().getValue() );
         }
     }
 
@@ -2395,7 +2393,7 @@ public class LdifReaderTest
                 "\n" +
                 "dn: cn=test3";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         reader.close();
 
@@ -2438,7 +2436,9 @@ public class LdifReaderTest
                 "telephonenumber: +1 408 555 1212\n" +
                 "An_idiot_Attribute: thanks M$ for that";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
+        
+        schemaManager.setRelaxed();
         List<LdifEntry> entries = reader.parseLdif( ldif );
         LdifEntry entry = entries.get( 0 );
         assertEquals( entry.get( "An_idiot_Attribute" ).getString(), "thanks M$ for that" );
@@ -2455,20 +2455,20 @@ public class LdifReaderTest
                 "dn: cn=DeviceTypes,cn=SDT,cn=prod_81,o=myconfiguration\n" +
                 "cn: DeviceTypes\n" +
                 "javaClassName: java.lang.String\n" +
-                "myconfigstringvalue: P:Phone (except BlackBerry)\n" +
-                "myconfigstringvalue:: WjpCbGFja0JlcnJ5w4LCrg==\n" +
-                "myconfigstringvalue: 3:Internet only device\n" +
+                "description: P:Phone (except BlackBerry)\n" +
+                "description:: WjpCbGFja0JlcnJ5w4LCrg==\n" +
+                "description: 3:Internet only device\n" +
                 "objectClass: top\n" +
                 "objectClass: javaobject\n" +
                 "objectClass: myconfigstringvaluedobject\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         LdifEntry entry = entries.get( 0 );
 
         // Check that the myconfigstringvalue contains 3 values
-        assertEquals( 3, entry.get( "myconfigstringvalue" ).size() );
-        assertTrue( entry.get( "myconfigstringvalue" ).isHumanReadable() );
+        assertEquals( 3, entry.get( "description" ).size() );
+        assertTrue( entry.get( "description" ).isHumanReadable() );
 
         reader.close();
     }
@@ -2483,20 +2483,20 @@ public class LdifReaderTest
                 "dn: cn=DeviceTypes,cn=SDT,cn=prod_81,o=myconfiguration\n" +
                 "cn: DeviceTypes\n" +
                 "javaClassName: java.lang.String\n" +
-                "myconfigstringvalue:: WjpCbGFja0JlcnJ5w4LCrg==\n" +
-                "myconfigstringvalue: P:Phone (except BlackBerry)\n" +
-                "myconfigstringvalue: 3:Internet only device\n" +
+                "description:: WjpCbGFja0JlcnJ5w4LCrg==\n" +
+                "description: P:Phone (except BlackBerry)\n" +
+                "description: 3:Internet only device\n" +
                 "objectClass: top\n" +
                 "objectClass: javaobject\n" +
                 "objectClass: myconfigstringvaluedobject\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         LdifEntry entry = entries.get( 0 );
 
         // Check that the myconfigstringvalue contains 3 values
-        assertEquals( 3, entry.get( "myconfigstringvalue" ).size() );
-        assertFalse( entry.get( "myconfigstringvalue" ).isHumanReadable() );
+        assertEquals( 3, entry.get( "description" ).size() );
+        assertTrue( entry.get( "description" ).isHumanReadable() );
 
         reader.close();
 
@@ -2515,13 +2515,13 @@ public class LdifReaderTest
             "objectClass: person\n" +
             "objectClass: organizationalPerson\n" +
             "-\n" +
-            "replace: sn\n" +
-            "sn: Nguyen Linh\n" +
+            "replace: userPassword\n" +
+            "userPassword:: dGVzdA==\n" +
             "-\n" +
-            "replace: url\n" +
+            "replace: javaSerializedData\n" +
             "-\n";
 
-        LdifReader reader = new LdifReader();
+        LdifReader reader = new LdifReader( schemaManager );
         List<LdifEntry> entries = reader.parseLdif( ldif );
         LdifEntry entry = entries.get( 0 );
 
@@ -2555,7 +2555,7 @@ public class LdifReaderTest
             "ads-baseDn:\n" +
             "ads-enabled: TRUE";
 
-        try ( LdifReader reader = new LdifReader() )
+        try ( LdifReader reader = new LdifReader( schemaManager ) )
         {
             List<LdifEntry> entries1 = reader.parseLdif( ldif1 );
             LdifEntry entry1 = entries1.get( 0 );
diff --git a/ldap/model/src/main/antlr/distinguishedName.g b/ldap/model/src/main/antlr/distinguishedName.g
index 2d243e1..e372565 100644
--- a/ldap/model/src/main/antlr/distinguishedName.g
+++ b/ldap/model/src/main/antlr/distinguishedName.g
@@ -629,9 +629,9 @@ quotestring [UpAndNormValue value]
  *
  * hexstring = SHARP 1*hexpair
  *
- * If in <hexstring> form, a BER representation can be obtained from
- * converting each <hexpair> of the <hexstring> to the octet indicated
- * by the <hexpair>.
+ * If in &lt;hexstring&gt; form, a BER representation can be obtained from
+ * converting each &lt;hexpair&gt; of the &lt;hexstring&gt; to the octet indicated
+ * by the &lt;hexpair&gt;.
  *
  */ 
 hexstring [UpAndNormValue value]
@@ -653,7 +653,7 @@ hexstring [UpAndNormValue value]
  * RFC 4514 Section 3
  *
  * ; The following characters are to be escaped when they appear
- * ; in the value to be encoded: ESC, one of <escaped>, leading
+ * ; in the value to be encoded: ESC, one of &lt;escaped&gt;, &lt;leading&gt;
  * ; SHARP or SPACE, trailing SPACE, and NULL.
  * string =   [ ( leadchar / pair ) [ *( stringchar / pair ) ( trailchar / pair ) ] ]
  * leadchar = LUTF1 | UTFMB
@@ -857,20 +857,20 @@ utfmb [UpAndNormValue value]
  * escaped = DQUOTE / PLUS / COMMA / SEMI / LANGLE / RANGLE
  * hexpair = HEX HEX
  *
- * If in <string> form, a LDAP string representation asserted value can
- * be obtained by replacing (left to right, non-recursively) each <pair>
- * appearing in the <string> as follows:
- *   replace <ESC><ESC> with <ESC>;
- *   replace <ESC><special> with <special>;
- *   replace <ESC><hexpair> with the octet indicated by the <hexpair>.
+ * If in &lt;string&gt; form, a LDAP string representation asserted value can
+ * be obtained by replacing (left to right, non-recursively) each &lt;pair&gt;
+ * appearing in the &lt;string&gt; as follows:
+ *   replace &lt;ESC&gt;&lt;ESC&gt; with &lt;ESC&gt;;
+ *   replace &lt;ESC&gt;&lt;special&gt; with &lt;special&gt;;
+ *   replace &lt;ESC&gt;&lt;hexpair&gt; with the octet indicated by the &lt;hexpair&gt;.
  * 
  * RFC 2253, Section 3
  * pair       = "\" ( special / "\" / QUOTATION / hexpair )
- * special    = "," / "=" / "+" / "<" /  ">" / "#" / ";"
+ * special    = "," / "=" / "+" / "&lt;" /  "&gt;" / "#" / ";"
  * 
  * RFC 1779, Section 2.3
  * &lt;pair&gt; ::= "\" ( &lt;special&gt; | "\" | '"')
- * &lt;special&gt; ::= "," | "=" | &lt;CR&gt; | "+" | "&lt;" |  ">"
+ * &lt;special&gt; ::= "," | "=" | &lt;CR&gt; | "+" | "&lt;" |  "&gt;"
  *           | "#" | ";"
  * 
  */ 
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/cursor/ListCursor.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/cursor/ListCursor.java
index 7d5d40b..80a1084 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/cursor/ListCursor.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/cursor/ListCursor.java
@@ -49,10 +49,10 @@ public class ListCursor<E> extends AbstractCursor<E>
     /** The associated comparator */
     private final Comparator<E> comparator;
 
-    /** The starting position for the cursor in the list. It can be > 0 */
+    /** The starting position for the cursor in the list. It can be &gt; 0 */
     private final int start;
 
-    /** The ending position for the cursor in the list. It can be < List.size() */
+    /** The ending position for the cursor in the list. It can be &lt; List.size() */
     private final int end;
     /** The current position in the list */
 
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/AttributeUtils.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/AttributeUtils.java
index 3a30788..c756c83 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/AttributeUtils.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/AttributeUtils.java
@@ -166,9 +166,15 @@ public final class AttributeUtils
     /**
      * Parse attribute's options :
      * 
+     * <pre>
      * options = *( ';' option )
      * option = 1*keychar
      * keychar = 'a'-z' | 'A'-'Z' / '0'-'9' / '-'
+     * </pre>
+     * 
+     * @param str The parsed option
+     * @param pos The position in the parsed option string
+     * @exception ParseException The parsed option is invalid
      */
     private static void parseOptions( char[] str, Position pos ) throws ParseException
     {
@@ -198,9 +204,15 @@ public final class AttributeUtils
     /**
      * Parse attribute's options :
      * 
+     * <pre>
      * options = *( ';' option )
      * option = 1*keychar
      * keychar = 'a'-z' | 'A'-'Z' / '0'-'9' / '-'
+     * </pre>
+     * 
+     * @param bytes The parsed option
+     * @param pos The position in the parsed option bytes
+     * @exception ParseException The parsed option is invalid
      */
     private static void parseOptions( byte[] bytes, Position pos ) throws ParseException
     {
@@ -228,9 +240,13 @@ public final class AttributeUtils
     /**
      * Parse a number :
      * 
+     * <pre>
      * number = '0' | '1'..'9' digits
      * digits = '0'..'9'*
+     * </pre>
      * 
+     * @param filter The number in the filter
+     * @param pos The position in the parsed filter string
      * @return true if a number has been found
      */
     private static boolean parseNumber( char[] filter, Position pos )
@@ -270,14 +286,16 @@ public final class AttributeUtils
     }
 
 
-
-
     /**
      * Parse a number :
      * 
+     * <pre>
      * number = '0' | '1'..'9' digits
      * digits = '0'..'9'*
+     * </pre>
      * 
+     * @param bytes The parsed number
+     * @param pos The position in the parsed number string
      * @return true if a number has been found
      */
     private static boolean parseNumber( byte[] bytes, Position pos )
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultAttribute.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultAttribute.java
index 7404acb..0f8c44c 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultAttribute.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultAttribute.java
@@ -85,8 +85,15 @@ public class DefaultAttribute implements Attribute, Cloneable
 
 
     /**
-     * Create a new instance of a schema aware Attribute, without ID nor value.
-     * Used by the serializer
+     * Create a new instance of a schema aware Attribute.
+     * Used by the serializer.
+     * 
+     * @param attributeType The associated AttributeType
+     * @param upId The user provided ID
+     * @param normId the normalized ID
+     * @param isHR tells if the attributeType is human readable
+     * @param hashCode The Attribute pre-computed hashcode
+     * @param values The associated values
      */
     /* No protection*/DefaultAttribute( AttributeType attributeType, String upId, String normId, boolean isHR,
         int hashCode, Value... values )
@@ -560,7 +567,11 @@ public class DefaultAttribute implements Attribute, Cloneable
 
 
     /**
-     * Check that the upId is either a name or the OID of a given AT
+     * Check that the id is either a name or the OID of a given AT
+     * 
+     * @param id The ID to check
+     * @param attributeType The attributeType to verify
+     * @return <tt>true</tt> if the id is a name or an OID
      */
     private boolean areCompatible( String id, AttributeType attributeType )
     {
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java
index e35604c..676e926 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java
@@ -413,6 +413,9 @@ public final class DefaultEntry implements Entry
 
     /**
      * Get the trimmed and lower cased entry ID
+     * 
+     * @param upId The ID
+     * @return The retrieved ID
      */
     private String getId( String upId )
     {
@@ -434,6 +437,8 @@ public final class DefaultEntry implements Entry
      * Get the UpId if it is null.
      * 
      * @param upId The ID
+     * @param attributeType The AttributeType to retrieve
+     * @return the retrieved ID
      */
     private String getUpId( String upId, AttributeType attributeType )
     {
@@ -505,9 +510,10 @@ public final class DefaultEntry implements Entry
 
 
     /**
-     * normalizes the given Dn if it was not already normalized
+     * Normalizes the given Dn if it was not already normalized
      *
      * @param dn the Dn to be normalized
+     * @return The normalized Dn
      */
     private Dn normalizeDn( Dn dn )
     {
@@ -550,6 +556,11 @@ public final class DefaultEntry implements Entry
      * default to the AttributeType name.
      *
      * Updates the AttributeMap.
+     * 
+     * @param upId The user provided ID for the attribute to create
+     * @param attributeType The AttributeType to use
+     * @param values The values to add to this attribute
+     * @throws LdapInvalidAttributeValueException If one of the value is incorrect
      */
     protected void createAttribute( String upId, AttributeType attributeType, byte[]... values )
         throws LdapInvalidAttributeValueException
@@ -565,6 +576,11 @@ public final class DefaultEntry implements Entry
      * default to the AttributeType name.
      *
      * Updates the AttributeMap.
+     * 
+     * @param upId The user provided ID for the attribute to create
+     * @param attributeType The AttributeType to use
+     * @param values The values to add to this attribute
+     * @throws LdapInvalidAttributeValueException If one of the value is incorrect
      */
     protected void createAttribute( String upId, AttributeType attributeType, String... values )
         throws LdapInvalidAttributeValueException
@@ -580,6 +596,11 @@ public final class DefaultEntry implements Entry
      * default to the AttributeType name.
      *
      * Updates the AttributeMap.
+     * 
+     * @param upId The user provided ID for the attribute to create
+     * @param attributeType The AttributeType to use
+     * @param values The values to add to this attribute
+     * @throws LdapInvalidAttributeValueException If one of the value is incorrect
      */
     protected void createAttribute( String upId, AttributeType attributeType, Value... values )
         throws LdapInvalidAttributeValueException
@@ -592,6 +613,10 @@ public final class DefaultEntry implements Entry
 
     /**
      * Returns the attributeType from an Attribute ID.
+     * 
+     * @param upId The ID we are looking for
+     * @return The found attributeType
+     * @throws LdapException If the lookup failed
      */
     protected AttributeType getAttributeType( String upId ) throws LdapException
     {
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/Value.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/Value.java
index e5fb56e..1795598 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/Value.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/Value.java
@@ -235,7 +235,6 @@ public class Value implements Cloneable, Externalizable, Comparable<Value>
      * only to be used by deserializers.
      *
      * @param attributeType the schema type associated with this Value
-     * @param value the value to wrap
      */
     /* Package protected*/ Value( AttributeType attributeType )
     {
@@ -678,7 +677,6 @@ public class Value implements Cloneable, Externalizable, Comparable<Value>
      * that the comparator is extracted from.
      *
      * @return a comparator associated with the attributeType or null if one cannot be found
-     * @throws LdapException if resolution of schema entities fail
      */
     private LdapComparator<?> getLdapComparator()
     {
@@ -794,7 +792,6 @@ public class Value implements Cloneable, Externalizable, Comparable<Value>
      * @return A new Value instance
      * @throws IOException If the stream can't be read
      * @throws ClassNotFoundException If we can't instanciate a Value
-     * @throws LdapInvalidAttributeValueException If the value is invalid
      */
     public static Value deserialize( ObjectInput in ) throws IOException, ClassNotFoundException
     {
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapAuthenticationNotSupportedException.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapAuthenticationNotSupportedException.java
index e165240..3daae3d 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapAuthenticationNotSupportedException.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapAuthenticationNotSupportedException.java
@@ -67,11 +67,12 @@ public class LdapAuthenticationNotSupportedException extends LdapOperationExcept
      * Checks to make sure the resultCode value is right for this exception
      * type.
      * 
+     * @param resultCode the code to check
      * @throws IllegalArgumentException
      *             if the result code is not one of
-     *             {@link ResultCodeEnum#INAPPROPRIATEAUTHENTICATION},
-     *             {@link ResultCodeEnum#AUTHMETHODNOTSUPPORTED},
-     *             {@link ResultCodeEnum#CONFIDENTIALITYREQUIRED}.
+     *             {@link ResultCodeEnum#INAPPROPRIATE_AUTHENTICATION},
+     *             {@link ResultCodeEnum#AUTH_METHOD_NOT_SUPPORTED},
+     *             {@link ResultCodeEnum#CONFIDENTIALITY_REQUIRED}.
      */
     private void checkResultCode( ResultCodeEnum resultCode )
     {
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapInvalidAttributeValueException.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapInvalidAttributeValueException.java
index 626ef2a..e68b28f 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapInvalidAttributeValueException.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapInvalidAttributeValueException.java
@@ -82,6 +82,7 @@ public class LdapInvalidAttributeValueException extends LdapOperationException
      * Checks to make sure the resultCode value is right for this exception
      * type.
      * 
+     * @param resultCode the code to check
      * @throws IllegalArgumentException
      *             if the result code is not one of
      *             {@link org.apache.directory.api.ldap.model.message.ResultCodeEnum#CONSTRAINT_VIOLATION},
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapInvalidDnException.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapInvalidDnException.java
index 3a95442..1bd2597 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapInvalidDnException.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapInvalidDnException.java
@@ -105,6 +105,7 @@ public class LdapInvalidDnException extends LdapOperationException
      * Checks to make sure the resultCode value is right for this exception
      * type.
      * 
+     * @param resultCode the code to check
      * @throws IllegalArgumentException
      *             if the result code is not one of
      *             {@link ResultCodeEnum#INVALID_DN_SYNTAX},
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapSchemaViolationException.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapSchemaViolationException.java
index ea4f972..b8af84d 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapSchemaViolationException.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapSchemaViolationException.java
@@ -81,6 +81,7 @@ public class LdapSchemaViolationException extends LdapOperationException
      * Checks to make sure the resultCode value is right for this exception
      * type.
      * 
+     * @param resultCode the code to check
      * @throws IllegalArgumentException
      *             if the result code is not one of
      *             {@link ResultCodeEnum#OBJECT_CLASS_VIOLATION},
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapServiceUnavailableException.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapServiceUnavailableException.java
index bf36cf5..3169fc0 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapServiceUnavailableException.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapServiceUnavailableException.java
@@ -67,6 +67,7 @@ public class LdapServiceUnavailableException extends LdapOperationException
      * Checks to make sure the resultCode value is right for this exception
      * type.
      * 
+     * @param resultCode the code to check
      * @throws IllegalArgumentException
      *             if the result code is not one of
      *             {@link ResultCodeEnum#BUSY},
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapUnwillingToPerformException.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapUnwillingToPerformException.java
index 25e2871..c3b52d6 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapUnwillingToPerformException.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/exception/LdapUnwillingToPerformException.java
@@ -102,6 +102,7 @@ public class LdapUnwillingToPerformException extends LdapOperationException
      * Checks to make sure the resultCode value is right for this exception
      * type.
      *
+     * @param resultCode the code to check
      * @throws IllegalArgumentException
      *             if the result code is not one of
      *             {@link ResultCodeEnum#UNWILLING_TO_PERFORM},
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/filter/FilterParser.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/filter/FilterParser.java
index ef88989..5f517ac 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/filter/FilterParser.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/filter/FilterParser.java
@@ -94,8 +94,9 @@ public final class FilterParser
     
     /**
      * Skip the white spaces (0x20, 0x09, 0x0a and 0x0d)
-     * @param filter
-     * @param pos
+     * 
+     * @param filter The filter being parsed
+     * @param pos The current position in the filter
      */
     private static void skipWhiteSpaces( byte[] filter, Position pos )
     {
@@ -156,11 +157,20 @@ public final class FilterParser
     /**
      * Parse an extensible
      *
-     *<pre>>
+     *<pre>
      * extensible     = ( attr [":dn"] [':' oid] ":=" assertionvalue )
      *                  / ( [":dn"] ':' oid ":=" assertionvalue )
      * matchingrule   = ":" oid
      * </pre>
+     * 
+     * @param schemaManager The {@link SchemaManager}
+     * @param attribute The filter's attribute
+     * @param filterBytes The filter bytes to parse
+     * @param pos The position in the filter bytes
+     * @param relaxed If the filter is analyzed in relaxed mode or not
+     * @return the created {@link ExprNode}
+     * @throws ParseException If the Node can't be parsed
+     * @throws LdapException If we met an error while parsing a filter element
      */
     private static ExprNode parseExtensible( SchemaManager schemaManager, String attribute, byte[] filterBytes,
         Position pos, boolean relaxed ) throws LdapException, ParseException
@@ -327,7 +337,7 @@ public final class FilterParser
      * With the specific constraints (RFC 4515):
      * 
      * <pre>
-     *    "The <valueencoding> rule ensures that the entire filter string is a"
+     *    "The &lt;valueencoding&lt; rule ensures that the entire filter string is a"
      *    "valid UTF-8 string and provides that the octets that represent the"
      *    "ASCII characters "*" (ASCII 0x2a), "(" (ASCII 0x28), ")" (ASCII"
      *    "0x29), "\" (ASCII 0x5c), and NUL (ASCII 0x00) are represented as a"
@@ -347,7 +357,13 @@ public final class FilterParser
      * unicodeSubset     = %x01-27 / %x2B-5B / %x5D-FFFF
      * </pre>
      * 
-     * @throws LdapInvalidAttributeValueException 
+     * @param schemaManager The {@link SchemaManager}
+     * @param attribute The associated Attribute
+     * @param filterBytes The filter bytes to parse
+     * @param pos The position in the filter bytes
+     * @return The parsed value
+     * @throws ParseException If the value can't be parsed
+     * @throws LdapInvalidAttributeValueException If the value is invalid
      */
     private static Value parseAssertionValue( SchemaManager schemaManager, String attribute, byte[] filterBytes,
         Position pos ) throws ParseException, LdapInvalidAttributeValueException
@@ -478,7 +494,7 @@ public final class FilterParser
      * With the specific constraints (RFC 4515):
      * 
      * <pre>
-     *    "The <valueencoding> rule ensures that the entire filter string is a"
+     *    "The &lt;valueencoding&gt; rule ensures that the entire filter string is a"
      *    "valid UTF-8 string and provides that the octets that represent the"
      *    "ASCII characters "*" (ASCII 0x2a), "(" (ASCII 0x28), ")" (ASCII"
      *    "0x29), "\" (ASCII 0x5c), and NUL (ASCII 0x00) are represented as a"
@@ -497,6 +513,12 @@ public final class FilterParser
      * HEX            = '0'-'9' / 'A'-'F' / 'a'-'f'
      * unicodeSubset     = %x01-27 / %x2B-5B / %x5D-FFFF
      * </pre>
+     * 
+     * @param schemaManager The {@link SchemaManager}
+     * @param filterBytes The filter bytes to parse
+     * @param pos The position in the filter bytes
+     * @return The parsed value
+     * @throws ParseException If the value can't be parsed
      */
     private static Value parseAssertionValue( SchemaManager schemaManager, byte[] filterBytes, Position pos )
         throws ParseException
@@ -566,6 +588,15 @@ public final class FilterParser
 
     /**
      * Parse a substring
+     * 
+     * @param schemaManager The {@link SchemaManager}
+     * @param attribute The filter's attribute
+     * @param initial The filter's initial part
+     * @param filterBytes The filter bytes to parse
+     * @param pos The position in the filter bytes
+     * @return the created {@link ExprNode}
+     * @throws ParseException If the Node can't be parsed
+     * @throws LdapException If we met an error while parsing a filter element
      */
     private static ExprNode parseSubstring( SchemaManager schemaManager, String attribute, Value initial,
         byte[] filterBytes, Position pos ) throws ParseException, LdapException
@@ -670,13 +701,21 @@ public final class FilterParser
      * seen as a present or as a substring. As stated in the RFC :
      *
      * <pre>
-     * "Note that although both the <substring> and <present> productions in"
+     * "Note that although both the &lt;substring&gt; and &lt;present&gt; productions in"
      * "the grammar above can produce the "attr=*" construct, this construct"
      * "is used only to denote a presence filter." (RFC 4515, 3)
      * </pre>
      * 
      * We have also to consider the difference between a substring and the
      * equality node : this last node does not contain a '*'
+     * 
+     * @param schemaManager The {@link SchemaManager}
+     * @param attribute The filter's attribute
+     * @param filterBytes The filter bytes to parse
+     * @param pos The position in the filter bytes
+     * @return the created {@link ExprNode}
+     * @throws ParseException If the Node can't be parsed
+     * @throws LdapException If we met an error while parsing a filter element
      */
     private static ExprNode parsePresenceEqOrSubstring( SchemaManager schemaManager, String attribute, byte[] filterBytes,
         Position pos ) throws ParseException, LdapException
@@ -786,7 +825,7 @@ public final class FilterParser
      * <pre>
      * item           = simple / present / substring / extensible
      * simple         = attr WSP* filtertype WSP* assertionvalue
-     * filtertype     = '=' / '~=' / '>=' / '<='
+     * filtertype     = '=' / '~=' / '&gt;=' / '&lt;='
      * present        = attr WSP* '=' '*'
      * substring      = attr WSP* '=' WSP* [initial] any [final]
      * extensible     = ( attr [":dn"] [':' oid] ":=" assertionvalue )
@@ -794,6 +833,15 @@ public final class FilterParser
      * matchingrule   = ":" oid
      * </pre>
      * An item starts with an attribute or a colon.
+     * 
+     * @param schemaManager The {@link SchemaManager}
+     * @param filterBytes The filter bytes to parse
+     * @param pos The position in the filter bytes
+     * @param b The type of item
+     * @param relaxed If the filter is analyzed in relaxed mode or not
+     * @return the created {@link ExprNode}
+     * @throws ParseException If the Node can't be parsed
+     * @throws LdapException If we met an error while parsing a filter element
      */
     @SuppressWarnings({ "rawtypes", })
     private static ExprNode parseItem( SchemaManager schemaManager, byte[] filterBytes, Position pos, byte b,
@@ -946,11 +994,20 @@ public final class FilterParser
     /**
      * Parse AND, OR and NOT nodes :
      * <pre>
-     * and            = '&' filterlist
+     * and            = '&amp;' filterlist
      * or             = '|' filterlist
      * not            = '!' filter
      * filterlist     = 1*filter
      * </pre>
+     * 
+     * @param schemaManager The {@link SchemaManager}
+     * @param node The node to feed
+     * @param filterBytes The filter bytes to parse
+     * @param pos The position in the filter bytes
+     * @param relaxed If the filter is analyzed in relaxed mode or not
+     * @return the created {@link ExprNode}
+     * @throws ParseException If the Node can't be parsed
+     * @throws LdapException If we met an error while parsing a filter element
      */
     private static ExprNode parseBranchNode( SchemaManager schemaManager, ExprNode node, byte[] filterBytes, Position pos,
         boolean relaxed ) throws ParseException, LdapException
@@ -1007,7 +1064,7 @@ public final class FilterParser
     /**
      * <pre>
      * filtercomp     = and / or / not / item
-     * and            = '&' WSP* filterlist
+     * and            = '&amp;' WSP* filterlist
      * or             = '|' WSP* filterlist
      * not            = '!' WSP* filter
      * item           = simple / present / substring / extensible
@@ -1019,6 +1076,14 @@ public final class FilterParser
      *                    / ( [dnattrs]
      *                         matchingrule COLON EQUALS assertionvalue )
      * </pre>
+     * 
+     * @param schemaManager The {@link SchemaManager}
+     * @param filterBytes The filter bytes to parse
+     * @param pos The position in the filter bytes
+     * @param relaxed If the filter is analyzed in relaxed mode or not
+     * @return the created {@link ExprNode}
+     * @throws ParseException If the Node can't be parsed
+     * @throws LdapException If we met an error while parsing a filter element
      */
     private static ExprNode parseFilterComp( SchemaManager schemaManager, byte[] filterBytes, Position pos,
         boolean relaxed ) throws ParseException, LdapException
@@ -1082,6 +1147,14 @@ public final class FilterParser
      * <pre>
      * filter ::= WSP* '(' WSP* filterComp WSP* ')' WSP*
      * </pre>
+     * 
+     * @param schemaManager The {@link SchemaManager}
+     * @param filterBytes The filter bytes to parse
+     * @param pos The position in the filter bytes
+     * @param relaxed If the filter is analyzed in relaxed mode or not
+     * @return the created {@link ExprNode}
+     * @throws ParseException If the Node can't be parsed
+     * @throws LdapException If we met an error while parsing a filter element
      */
     private static ExprNode parseFilterInternal( SchemaManager schemaManager, byte[] filterBytes, Position pos,
         boolean relaxed ) throws ParseException, LdapException
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/filter/LeafNode.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/filter/LeafNode.java
index e126161..b139789 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/filter/LeafNode.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/filter/LeafNode.java
@@ -64,7 +64,7 @@ public abstract class LeafNode extends AbstractExprNode
     /**
      * Creates a leaf node.
      * 
-     * @param attributeType the attribute this node is based on
+     * @param attribute the attribute this node is based on
      * @param assertionType the type of this leaf node
      */
     protected LeafNode( String attribute, AssertionType assertionType )
@@ -171,6 +171,9 @@ public boolean isSchemaAware()
     
     /**
      * Escape a binary value into a String form that is accepted as a Filter
+     * 
+     * @param bytes The data to escape
+     * @return The escaped String
      */
     private static String escapeBytes( byte[] bytes )
     {
@@ -191,6 +194,9 @@ public boolean isSchemaAware()
     
     /**
      * Escape a String value into a String form that is accepted as a Filter
+     * 
+     * @param bytes The data to escape
+     * @return The escaped String
      */
     private static String escapeString( byte[] bytes )
     {
@@ -256,9 +262,10 @@ public boolean isSchemaAware()
      * Handles the escaping of special characters in LDAP search filter assertion values using the
      * &lt;valueencoding&gt; rule as described in
      * <a href="http://www.ietf.org/rfc/rfc4515.txt">RFC 4515</a>. Needed so that
-     * {@link ExprNode#printToBuffer(StringBuffer)} results in a valid filter string that can be parsed
+     * {@link ExprNode#printRefinementToBuffer(StringBuilder)} results in a valid filter string that can be parsed
      * again (as a way of cloning filters).
      *
+     * @param attributeType The associated {@link AttributeType}
      * @param value Right hand side of "attrId=value" assertion occurring in an LDAP search filter.
      * @return Escaped version of <code>value</code>
      */
@@ -309,7 +316,7 @@ public boolean isSchemaAware()
      * Handles the escaping of special characters in LDAP search filter assertion values using the
      * &lt;valueencoding&gt; rule as described in
      * <a href="http://www.ietf.org/rfc/rfc4515.txt">RFC 4515</a>. Needed so that
-     * {@link ExprNode#printToBuffer(StringBuffer)} results in a valid filter string that can be parsed
+     * {@link ExprNode#printRefinementToBuffer(StringBuilder)} results in a valid filter string that can be parsed
      * again (as a way of cloning filters).
      *
      * @param value Right hand side of "attrId=value" assertion occurring in an LDAP search filter.
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/ldif/LdifControl.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/ldif/LdifControl.java
index aab8170..5ccfc86 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/ldif/LdifControl.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/ldif/LdifControl.java
@@ -129,7 +129,7 @@ public class LdifControl implements Control, Externalizable
 
 
     /**
-     * @return <t>TRUE</t> if the control has a value
+     * @return <tt>TRUE</tt> if the control has a value
      */
     public boolean hasValue()
     {
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/ldif/LdifReader.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/ldif/LdifReader.java
index 9291347..f077648 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/ldif/LdifReader.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/ldif/LdifReader.java
@@ -786,13 +786,13 @@ public class LdifReader implements Iterable<LdifEntry>, Closeable
      * &lt;critical-e&gt; ::= &lt;spaces&gt; &lt;boolean&gt; | e
      * &lt;boolean&gt; ::= "true" | "false"
      * &lt;value-spec-e&gt; ::= &lt;value-spec&gt; | e
-     * &lt;value-spec&gt; ::= ":" &lt;fill&gt; &lt;SAFE-STRING-e&gt; | "::" &lt;fill&gt; &lt;BASE64-STRING&gt; | ":<" &lt;fill&gt; &lt;url&gt;
+     * &lt;value-spec&gt; ::= ":" &lt;fill&gt; &lt;SAFE-STRING-e&gt; | "::" &lt;fill&gt; &lt;BASE64-STRING&gt; | ":&lt;" &lt;fill&gt; &lt;url&gt;
      * </pre>
      *
      * It can be read as :
      * <pre>
      * "control:" &lt;fill&gt; &lt;ldap-oid&gt; [ " "+ ( "true" |
-     * "false") ] [ ":" &lt;fill&gt; &lt;SAFE-STRING-e&gt; | "::" &lt;fill&gt; &lt;BASE64-STRING&gt; | ":<"
+     * "false") ] [ ":" &lt;fill&gt; &lt;SAFE-STRING-e&gt; | "::" &lt;fill&gt; &lt;BASE64-STRING&gt; | ":&lt;"
      * &lt;fill&gt; &lt;url&gt; ]
      * </pre>
      *
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/message/controls/PersistentSearch.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/message/controls/PersistentSearch.java
index 81a2456..c70628b 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/message/controls/PersistentSearch.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/message/controls/PersistentSearch.java
@@ -89,7 +89,7 @@ public interface PersistentSearch extends Control
      * For each changeType, tells if the notification is enabled
      * 
      * @param changeType The ChnageType we are interested in
-     * @return <T>TRUE<T> if the notification is set for this ChangeType
+     * @return <tt>TRUE<tt> if the notification is set for this ChangeType
      */
     boolean isNotificationEnabled( ChangeType changeType );
 
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/name/FastDnParser.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/name/FastDnParser.java
index 713bda1..35679bc 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/name/FastDnParser.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/name/FastDnParser.java
@@ -34,7 +34,7 @@ import org.apache.directory.api.util.Strings;
 
 /**
  * A fast LDAP Dn parser that handles only simple DNs. If the Dn contains
- * any special character an {@link TooComplexException} is thrown.
+ * any special character an {@link LdapInvalidDnException} is thrown.
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
@@ -587,7 +587,7 @@ import org.apache.directory.api.util.Strings;
     /**
      * Matches the assertion value. This method only handles simple values.
      * If we find any special character (BACKSLASH, PLUS, SHARP or DQUOTE),
-     * a TooComplexException will be thrown.
+     * a LdapInvalidDnException will be thrown.
      * 
      * @param name the name
      * @param pos the pos
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/name/Rdn.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/name/Rdn.java
index e90ea63..64fc850 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/name/Rdn.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/name/Rdn.java
@@ -576,12 +576,10 @@ public class Rdn implements Cloneable, Externalizable, Iterable<Ava>, Comparable
     /**
      * Add an Ava to the current Rdn
      *
-     * @param upType The user provided type of the added Rdn.
-     * @param type The normalized provided type of the added Rdn.
-     * @param upValue The user provided value of the added Rdn
-     * @param value The normalized provided value of the added Rdn
-     * @throws LdapInvalidDnException
-     *             If the Rdn is invalid
+     * @param schemaManager The {@link SchemaManager}
+     * @param type The user provided type of the added Rdn.
+     * @param value The user provided provided value of the added Rdn
+     * @throws LdapInvalidDnException If the Rdn is invalid
      */
     private void addAVA( SchemaManager schemaManager, String type, Value value ) throws LdapInvalidDnException
     {
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/password/BCrypt.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/password/BCrypt.java
index a5ca53c..1081d5e 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/password/BCrypt.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/password/BCrypt.java
@@ -36,25 +36,25 @@ import org.apache.directory.api.i18n.I18n;
 * call the hashpw method with a random salt, like this:
 * <p>
 * <code>
-* String pw_hash = BCrypt.hashpw(plain_password, BCrypt.gensalt()); <br />
+* String pw_hash = BCrypt.hashpw(plain_password, BCrypt.gensalt()); <br>
 * </code>
 * <p>
 * To check whether a plaintext password matches one that has been
 * hashed previously, use the checkpw method:
 * <p>
 * <code>
-* if (BCrypt.checkpw(candidate_password, stored_hash))<br />
-* &nbsp;&nbsp;&nbsp;&nbsp;System.out.println("It matches");<br />
-* else<br />
-* &nbsp;&nbsp;&nbsp;&nbsp;System.out.println("It does not match");<br />
+* if (BCrypt.checkpw(candidate_password, stored_hash))<br>
+* &nbsp;&nbsp;&nbsp;&nbsp;System.out.println("It matches");<br>
+* else<br>
+* &nbsp;&nbsp;&nbsp;&nbsp;System.out.println("It does not match");<br>
 * </code>
 * <p>
 * The gensalt() method takes an optional parameter (log_rounds)
 * that determines the computational complexity of the hashing:
 * <p>
 * <code>
-* String strong_salt = BCrypt.gensalt(10)<br />
-* String stronger_salt = BCrypt.gensalt(12)<br />
+* String strong_salt = BCrypt.gensalt(10)<br>
+* String stronger_salt = BCrypt.gensalt(12)<br>
 * </code>
 * <p>
 * The amount of work increases exponentially (2**log_rounds), so 
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/parsers/OpenLdapSchemaParser.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/parsers/OpenLdapSchemaParser.java
index 49102c1..c010302 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/parsers/OpenLdapSchemaParser.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/schema/parsers/OpenLdapSchemaParser.java
@@ -39,7 +39,6 @@ import java.util.Map;
 import org.apache.directory.api.asn1.util.Oid;
 import org.apache.directory.api.i18n.I18n;
 import org.apache.directory.api.ldap.model.exception.LdapSchemaException;
-import org.apache.directory.api.ldap.model.ldif.LdapLdifException;
 import org.apache.directory.api.ldap.model.schema.AttributeType;
 import org.apache.directory.api.ldap.model.schema.DitContentRule;
 import org.apache.directory.api.ldap.model.schema.DitStructureRule;
@@ -478,8 +477,6 @@ public class OpenLdapSchemaParser
 
     /**
      * Creates a reusable instance of an OpenLdapSchemaParser.
-     *
-     * @throws IOException if the pipe cannot be formed
      */
     public OpenLdapSchemaParser()
     {
@@ -629,40 +626,37 @@ public class OpenLdapSchemaParser
     {
         String rawOidOrNameSuffix = macro.getRawOidOrNameSuffix();
 
-        if ( macro.isResolved() )
-        {
-            // finished
-            return;
-        }
-        else if ( rawOidOrNameSuffix.indexOf( COLON ) != -1 )
-        {
-            // resolve OID
-            String[] nameAndSuffix = rawOidOrNameSuffix.split( ":" );
-            
-            if ( objectIdentifierMacros.containsKey( nameAndSuffix[0] ) )
-            {
-                OpenLdapObjectIdentifierMacro parentMacro = objectIdentifierMacros.get( nameAndSuffix[0] );
-                resolveObjectIdentifierMacro( parentMacro );
-                macro.setResolvedOid( parentMacro.getResolvedOid() + "." + nameAndSuffix[1] );
-            }
-            else
-            {
-                throw new ParseException( I18n.err( I18n.ERR_13726_NO_OBJECT_IDENTIFIER_MACRO, nameAndSuffix[0] ), 0 );
-            }
-
-        }
-        else
+        if ( !macro.isResolved() )
         {
-            // no :suffix,
-            if ( objectIdentifierMacros.containsKey( rawOidOrNameSuffix ) )
+            if ( rawOidOrNameSuffix.indexOf( COLON ) != -1 )
             {
-                OpenLdapObjectIdentifierMacro parentMacro = objectIdentifierMacros.get( rawOidOrNameSuffix );
-                resolveObjectIdentifierMacro( parentMacro );
-                macro.setResolvedOid( parentMacro.getResolvedOid() );
+                // resolve OID
+                String[] nameAndSuffix = rawOidOrNameSuffix.split( ":" );
+                
+                if ( objectIdentifierMacros.containsKey( nameAndSuffix[0] ) )
+                {
+                    OpenLdapObjectIdentifierMacro parentMacro = objectIdentifierMacros.get( nameAndSuffix[0] );
+                    resolveObjectIdentifierMacro( parentMacro );
+                    macro.setResolvedOid( parentMacro.getResolvedOid() + "." + nameAndSuffix[1] );
+                }
+                else
+                {
+                    throw new ParseException( I18n.err( I18n.ERR_13726_NO_OBJECT_IDENTIFIER_MACRO, nameAndSuffix[0] ), 0 );
+                }
             }
             else
             {
-                macro.setResolvedOid( rawOidOrNameSuffix );
+                // no :suffix,
+                if ( objectIdentifierMacros.containsKey( rawOidOrNameSuffix ) )
+                {
+                    OpenLdapObjectIdentifierMacro parentMacro = objectIdentifierMacros.get( rawOidOrNameSuffix );
+                    resolveObjectIdentifierMacro( parentMacro );
+                    macro.setResolvedOid( parentMacro.getResolvedOid() );
+                }
+                else
+                {
+                    macro.setResolvedOid( rawOidOrNameSuffix );
+                }
             }
         }
     }
@@ -711,7 +705,9 @@ public class OpenLdapSchemaParser
      * Parses a stream of OpenLDAP schemaObject elements/objects. Default charset is used.
      *
      * @param schemaIn a stream of schema objects
-     * @throws Exception 
+     * @throws ParseException  If the schema can't be parsed
+     * @throws LdapSchemaException If there is an error in the schema
+     * @throws IOException If the stream can't be read
      */
     public void parse( InputStream schemaIn ) throws ParseException, LdapSchemaException, IOException
     {
@@ -1338,7 +1334,7 @@ public class OpenLdapSchemaParser
      * COLON        ::= %x3A                ; colon (":")
      * SEMI_COLON   ::= %x3B                ; semi-colon(";")
      * SHARP        ::= %x23                ; octothorpe (or sharp sign) ("#")
-     * </pre
+     * </pre>
      */
     private static String getDescrRelaxed( PosSchema pos ) throws LdapSchemaException
     {
@@ -2147,6 +2143,7 @@ public class OpenLdapSchemaParser
      * number ::= DIGIT | LDIGIT DIGIT+
      * DIGIT  ::= [0-9]
      * LDIGIT ::= [1-9]
+     * </pre>
      */
     private static int getRuleId( PosSchema pos ) throws LdapSchemaException
     {
@@ -2445,6 +2442,7 @@ public class OpenLdapSchemaParser
      * <pre>
      * FQCN ::= FQCN_IDENTIFIER ( '.' FQCN_IDENTIFIER )*
      * FQCN_IDENTIFIER ::= ( JavaLetter ( JavaLetterOrDigit )*
+     * </pre>
      */
     private static String getFqcn( PosSchema pos ) throws LdapSchemaException
     {
@@ -2515,6 +2513,7 @@ public class OpenLdapSchemaParser
      * A base64 string
      * <pre>
      * byteCode ::= ( [a-z] | [A-Z] | [0-9] | '+' | '/' | '=' )*
+     * </pre>
      */
     private static String getByteCode( PosSchema pos )
     {
@@ -6192,7 +6191,8 @@ public class OpenLdapSchemaParser
      *
      * The lines represent *one* entry.
      *
-     * @throws LdapLdifException If something went wrong
+     * @throws LdapSchemaException If something went wrong in the schema
+     * @throws IOException If something went wrong with the stream
      */
     public void parse( Reader reader ) throws LdapSchemaException, IOException
     {
@@ -6245,7 +6245,6 @@ public class OpenLdapSchemaParser
      * Parses a file of OpenLDAP schemaObject elements/objects. Default charset is used.
      *
      * @param schemaFile a file of schema objects
-     * @throws IOException If the schemaObject can't be transformed to a byteArrayInputStream
      * @throws ParseException If the schemaObject can't be parsed
      */
     public void parse( File schemaFile ) throws ParseException
diff --git a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/url/LdapUrl.java b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/url/LdapUrl.java
index 47701e2..20e9317 100644
--- a/ldap/model/src/main/java/org/apache/directory/api/ldap/model/url/LdapUrl.java
+++ b/ldap/model/src/main/java/org/apache/directory/api/ldap/model/url/LdapUrl.java
@@ -348,14 +348,11 @@ public class LdapUrl
      * <pre>
      * host        = IP-literal / IPv4address / reg-name
      * port        = *DIGIT
-     * <host> ::= <hostname> ':' <hostnumber><br>
-     * <hostname> ::= *[ <domainlabel> "." ] <toplabel><br>
-     * <domainlabel> ::= <alphadigit> | <alphadigit> *[
-     * <alphadigit> | "-" ] <alphadigit><br>
-     * <toplabel> ::= <alpha> | <alpha> *[ <alphadigit> |
-     * "-" ] <alphadigit><br>
-     * <hostnumber> ::= <digits> "." <digits> "."
-     * <digits> "." <digits>
+     * &lt;host&gt; ::= &lt;hostname&gt; ':' &lt;hostnumber&gt;
+     * &lt;hostname&gt; ::= *[ &lt;domainlabel&gt; "." ] &lt;toplabel&gt;
+     * &lt;domainlabel&gt; ::= &lt;alphadigit&gt; | &lt;alphadigit&gt; *[&lt;alphadigit&gt; | "-" ] &lt;alphadigit&gt;
+     * &lt;toplabel&gt; ::= &lt;alpha&gt; | &lt;alpha&gt; *[ &lt;alphadigit&gt; | "-" ] &lt;alphadigit&gt;
+     * &lt;hostnumber&gt; ::= &lt;digits&gt; "." &lt;digits&gt; "." &lt;digits&gt; "." &lt;digits&gt;
      * </pre>
      *
      * @param chars The buffer to parse
@@ -443,6 +440,7 @@ public class LdapUrl
      *               | [ *6( h16 ":" ) h16 ] "::"
      * h16         = 1*4HEXDIG
      * ls32        = ( h16 ":" h16 ) / IPv4address
+     * </pre>
      */
     private int parseIpLiteral( char[] chars, int pos )
     {
@@ -745,7 +743,7 @@ public class LdapUrl
      * reg-name    = *( unreserved / pct-encoded / sub-delims )
      * unreserved  = ALPHA / DIGIT / "-" / "." / "_" / "~"
      * pct-encoded = "%" HEXDIG HEXDIG
-     * sub-delims  = "!" | "$" | "&" | "'" | "(" | ")" | "*" | "+" | "," | ";" | "="
+     * sub-delims  = "!" | "$" | "&amp;" | "'" | "(" | ")" | "*" | "+" | "," | ";" | "="
      * HEXDIG      = DIGIT / A-F / a-f
      * </pre>
      */
@@ -930,8 +928,8 @@ public class LdapUrl
     /**
      * Parse this rule : <br>
      * <pre>
-     * <port> ::= <digit>+<br>
-     * <digit> ::= 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
+     * &lt;port&gt; ::= &lt;digit&gt;+
+     * &lt;digit&gt; ::= 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
      * </pre>
      * The port must be between 0 and 65535.
      *
@@ -971,7 +969,7 @@ public class LdapUrl
     /**
      * Parse this rule : <br>
      * <pre>
-     *   &lt;hostport> ::= &lt;host> [':' &lt;port>]
+     *   &lt;hostport&gt; ::= &lt;host&gt; [':' &lt;port&gt;]
      * </pre>
      *
      * @param chars The char array to parse
@@ -1149,6 +1147,7 @@ public class LdapUrl
      * keychar ::= [a-zA-Z0-0-]
      * numericOid ::= number 1*( DOT number )
      * number ::= 0 | [1-9][0-9]* 
+     * </pre>
      * 
      * @param attribute
      * @throws LdapURLEncodingException
diff --git a/ldap/model/src/test/java/org/apache/directory/api/ldap/model/ldif/LdifReaderTest.java b/ldap/model/src/test/java/org/apache/directory/api/ldap/model/ldif/LdifReaderTest.java
index ad88917..9eaa8ca 100644
--- a/ldap/model/src/test/java/org/apache/directory/api/ldap/model/ldif/LdifReaderTest.java
+++ b/ldap/model/src/test/java/org/apache/directory/api/ldap/model/ldif/LdifReaderTest.java
@@ -2344,7 +2344,7 @@ public class LdifReaderTest
         String ldif =
             "version:   1\n" +
                 "dn:\n" +
-                "cn: app1\n" +
+                "cn:: YXBwMQ==\n" +
                 "objectClass: top\n" +
                 "objectClass: apApplication\n" +
                 "displayName: app1   \n" +


Mime
View raw message