directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r414767 - in /directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core: ./ authz/ enumeration/ event/ exception/ normalization/ operational/ partition/ partition/impl/btree/ partition/impl/btree/jdbm/ ref...
Date Fri, 16 Jun 2006 07:37:26 GMT
Author: elecharny
Date: Fri Jun 16 00:37:25 2006
New Revision: 414767

URL: http://svn.apache.org/viewvc?rev=414767&view=rev
Log:
Get rid of OIDS_MAP and replaced it with a parameter received from the server
(Was JIRA DIRSERVER-647)

Modified:
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/DefaultAuthorizationService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/enumeration/ReferralHandlingEnumeration.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/event/EventService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/exception/ExceptionService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/normalization/NormalizationService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/operational/OperationalAttributeService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/AbstractDirectoryPartition.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/DirectoryPartitionNexus.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreeDirectoryPartition.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmDirectoryPartition.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/referral/ReferralService.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnComparator.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnNormalizer.java
    directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/subtree/SubentryService.java

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java Fri Jun 16 00:37:25 2006
@@ -19,6 +19,7 @@
 
 import java.util.Hashtable;
 import java.util.Iterator;
+import java.util.Map;
 import java.util.Set;
 import java.util.HashSet;
 
@@ -448,8 +449,9 @@
         // create system users area
         // -------------------------------------------------------------------
 
+        Map oidsMap = configuration.getGlobalRegistries().getAttributeTypeRegistry().getNormalizerMapping();
         LdapDN userDn = new LdapDN( "ou=users,ou=system" );
-        userDn.normalize();
+        userDn.normalize( oidsMap );
         
         if ( !partitionNexus.hasEntry( userDn ) )
         {
@@ -473,7 +475,7 @@
         // -------------------------------------------------------------------
 
         LdapDN groupDn = new LdapDN( "ou=groups,ou=system" );
-        groupDn.normalize();
+        groupDn.normalize( oidsMap );
         
         if ( !partitionNexus.hasEntry( groupDn ) )
         {
@@ -498,7 +500,7 @@
 
         String upName = "cn=Administrators,ou=groups,ou=system";
         LdapDN normName = new LdapDN( "cn=administrators,ou=groups,ou=system" );
-        normName.normalize();
+        normName.normalize( oidsMap );
         
         if ( !partitionNexus.hasEntry( normName ) )
         {
@@ -524,7 +526,7 @@
         // -------------------------------------------------------------------
 
         LdapDN configurationDn = new LdapDN( "ou=configuration,ou=system" );
-        configurationDn.normalize();
+        configurationDn.normalize( oidsMap );
         
         if ( !partitionNexus.hasEntry( configurationDn ) )
         {
@@ -548,7 +550,7 @@
         // -------------------------------------------------------------------
 
         LdapDN partitionsDn = new LdapDN( "ou=partitions,ou=configuration,ou=system" );
-        partitionsDn.normalize();
+        partitionsDn.normalize( oidsMap );
         
         if ( !partitionNexus.hasEntry( partitionsDn ) ) 
         {
@@ -572,7 +574,7 @@
         // -------------------------------------------------------------------
 
         LdapDN servicesDn = new LdapDN( "ou=services,ou=configuration,ou=system" );
-        servicesDn.normalize();
+        servicesDn.normalize( oidsMap );
         
         if ( !partitionNexus.hasEntry( servicesDn ) )
         {
@@ -596,7 +598,7 @@
         // -------------------------------------------------------------------
 
         LdapDN interceptorsDn = new LdapDN( "ou=interceptors,ou=configuration,ou=system" );
-        interceptorsDn.normalize();
+        interceptorsDn.normalize( oidsMap );
         
         if ( !partitionNexus.hasEntry( interceptorsDn ) )
         {
@@ -620,7 +622,7 @@
         // -------------------------------------------------------------------
 
         LdapDN sysPrefRootDn = new LdapDN( "prefNodeName=sysPrefRoot,ou=system");
-        sysPrefRootDn.normalize();
+        sysPrefRootDn.normalize( oidsMap );
         
         if ( !partitionNexus.hasEntry( sysPrefRootDn ) )
         {
@@ -653,7 +655,7 @@
         boolean needToChangeAdminPassword = false;
 
         LdapDN adminDn = new LdapDN( DirectoryPartitionNexus.ADMIN_PRINCIPAL );
-        adminDn.normalize();
+        adminDn.normalize( configuration.getGlobalRegistries().getAttributeTypeRegistry().getNormalizerMapping() );
         
         Attributes adminEntry = partitionNexus.lookup( adminDn );
         Object userPassword = adminEntry.get( "userPassword" ).get();

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/AuthorizationService.java Fri Jun 16 00:37:25 2006
@@ -175,7 +175,7 @@
         objectClassType = attrRegistry.lookup( objectClassOid );
         acSubentryType = attrRegistry.lookup( acSubentryOid );
         
-        aciParser = new ACIItemParser( new ConcreteNameComponentNormalizer( attrRegistry, oidRegistry ) );
+        aciParser = new ACIItemParser( new ConcreteNameComponentNormalizer( attrRegistry, oidRegistry ), attrRegistry.getNormalizerMapping() );
         engine = new ACDFEngine( factoryCfg.getGlobalRegistries().getOidRegistry(), attrRegistry );
         chain = factoryCfg.getInterceptorChain();
         enabled = factoryCfg.getStartupConfiguration().isAccessControlEnabled();
@@ -184,7 +184,7 @@
         String subschemaSubentry = ( String ) factoryCfg.getPartitionNexus().getRootDSE().get( "subschemaSubentry" )
             .get();
         LdapDN subschemaSubentryDnName = new LdapDN( subschemaSubentry );
-        subschemaSubentryDnName.normalize();
+        subschemaSubentryDnName.normalize( attrRegistry.getNormalizerMapping() );
         subschemaSubentryDn = subschemaSubentryDnName.toNormName();
     }
 
@@ -192,7 +192,7 @@
     private LdapDN parseNormalized( String name ) throws NamingException
     {
         LdapDN dn = new LdapDN( name );
-        dn.normalize();
+        dn.normalize( attrRegistry.getNormalizerMapping() );
         return dn;
     }
 
@@ -675,7 +675,7 @@
         Attributes entry = proxy.lookup( dn, DirectoryPartitionNexusProxy.LOOKUP_BYPASS );
         LdapPrincipal principal = ( ( ServerContext ) invocation.getCaller() ).getPrincipal();
         LdapDN principalDn = new LdapDN( principal.getName() );
-        principalDn.normalize();
+        principalDn.normalize( attrRegistry.getNormalizerMapping() );
         
         if ( principalDn.toNormName().equalsIgnoreCase( DirectoryPartitionNexus.ADMIN_PRINCIPAL_NORMALIZED ) || !enabled )
         {
@@ -927,7 +927,7 @@
         ServerLdapContext ctx = ( ServerLdapContext ) invocation.getCaller();
         LdapPrincipal user = ctx.getPrincipal();
         LdapDN principalDn = new LdapDN( user.getName() );
-        principalDn.normalize();
+        principalDn.normalize( attrRegistry.getNormalizerMapping() );
         
         NamingEnumeration e = next.search( base, env, filter, searchCtls );
 

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/DefaultAuthorizationService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/DefaultAuthorizationService.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/DefaultAuthorizationService.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/DefaultAuthorizationService.java Fri Jun 16 00:37:25 2006
@@ -40,6 +40,7 @@
 import org.apache.directory.server.core.invocation.InvocationStack;
 import org.apache.directory.server.core.jndi.ServerContext;
 import org.apache.directory.server.core.partition.DirectoryPartitionNexus;
+import org.apache.directory.server.core.schema.AttributeTypeRegistry;
 import org.apache.directory.shared.ldap.exception.LdapNoPermissionException;
 import org.apache.directory.shared.ldap.filter.ExprNode;
 import org.apache.directory.shared.ldap.name.LdapDN;
@@ -76,8 +77,10 @@
     /**
      * the name parser used by this service
      */
-    //private DnParser dnParser;
     private boolean enabled = true;
+    
+    private Map oidsMap;
+    
 
 
     /**
@@ -90,7 +93,7 @@
 
     public void init( DirectoryServiceConfiguration factoryCfg, InterceptorConfiguration cfg ) throws NamingException
     {
-        //AttributeTypeRegistry atr = factoryCfg.getGlobalRegistries().getAttributeTypeRegistry();
+        oidsMap = factoryCfg.getGlobalRegistries().getAttributeTypeRegistry().getNormalizerMapping();
         //dnParser = new DnParser( new ConcreteNameComponentNormalizer( atr ) );
 
         // disable this static module if basic access control mechanisms are enabled
@@ -98,10 +101,10 @@
         ADMIN_DN = DirectoryPartitionNexus.getAdminName(); 
         
         USER_BASE_DN = DirectoryPartitionNexus.getUsersBaseName();
-        USER_BASE_DN_NORMALIZED = LdapDN.normalize( USER_BASE_DN );
+        USER_BASE_DN_NORMALIZED = LdapDN.normalize( USER_BASE_DN, oidsMap );
         
         GROUP_BASE_DN = DirectoryPartitionNexus.getGroupsBaseName();
-        GROUP_BASE_DN_NORMALIZED = LdapDN.normalize( GROUP_BASE_DN );
+        GROUP_BASE_DN_NORMALIZED = LdapDN.normalize( GROUP_BASE_DN, oidsMap );
     }
 
 
@@ -206,7 +209,7 @@
     private void protectModifyAlterations( LdapDN dn ) throws NamingException
     {
         LdapDN principalDn = new LdapDN( getPrincipal().getJndiName() );
-        principalDn.normalize();
+        principalDn.normalize( oidsMap );
 
         if ( dn.size() == 0 )
         {
@@ -354,7 +357,7 @@
     {
         LdapContext ctx = ( LdapContext ) InvocationStack.getInstance().peek().getCaller();
         LdapDN principalDn = new LdapDN( ( ( ServerContext ) ctx ).getPrincipal().getJndiName() );
-        principalDn.normalize();
+        principalDn.normalize( oidsMap );
 
         if ( !principalDn.equals( ADMIN_DN ) )
         {
@@ -451,11 +454,11 @@
     private boolean isSearchable( Invocation invocation, SearchResult result ) throws NamingException
     {
         LdapDN principalDn = ( LdapDN ) ( ( ServerContext ) invocation.getCaller() ).getPrincipal().getJndiName();
-        principalDn.normalize();
+        principalDn.normalize( oidsMap );
 
         LdapDN dn;
         dn = new LdapDN( result.getName() );
-        dn.normalize();
+        dn.normalize( oidsMap );
 
         boolean isAdmin = principalDn.toNormName().equals( DirectoryPartitionNexus.ADMIN_PRINCIPAL_NORMALIZED );
         

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/GroupCache.java Fri Jun 16 00:37:25 2006
@@ -60,7 +60,11 @@
     /** the env to use for searching */
     private final Hashtable env;
 
-
+    /**
+     * The OIDs normalizer map
+     */
+    private Map normalizerMap;
+    
     /**
      * Creates a static group cache.
      *
@@ -68,6 +72,7 @@
      */
     public GroupCache(DirectoryServiceConfiguration factoryCfg) throws NamingException
     {
+    	normalizerMap = factoryCfg.getGlobalRegistries().getAttributeTypeRegistry().getNormalizerMapping();
         this.nexus = factoryCfg.getPartitionNexus();
         this.env = ( Hashtable ) factoryCfg.getEnvironment().clone();
         initialize();
@@ -77,7 +82,7 @@
     private LdapDN parseNormalized( String name ) throws NamingException
     {
         LdapDN dn = new LdapDN( name );
-        dn.normalize();
+        dn.normalize( normalizerMap );
         return dn;
     }
 

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java Fri Jun 16 00:37:25 2006
@@ -75,6 +75,10 @@
     /** a normalizing ACIItem parser */
     private final ACIItemParser aciParser;
 
+    /**
+     * The OIDs normalizer map
+     */
+    private Map normalizerMap;
 
     /**
      * Creates a ACITuple cache.
@@ -83,11 +87,12 @@
      */
     public TupleCache(DirectoryServiceConfiguration factoryCfg) throws NamingException
     {
+    	normalizerMap = factoryCfg.getGlobalRegistries().getAttributeTypeRegistry().getNormalizerMapping();
         this.nexus = factoryCfg.getPartitionNexus();
         AttributeTypeRegistry attributeRegistry = factoryCfg.getGlobalRegistries().getAttributeTypeRegistry();
         OidRegistry oidRegistry = factoryCfg.getGlobalRegistries().getOidRegistry();
         NameComponentNormalizer ncn = new ConcreteNameComponentNormalizer( attributeRegistry, oidRegistry );
-        aciParser = new ACIItemParser( ncn );
+        aciParser = new ACIItemParser( ncn, normalizerMap );
         env = ( Hashtable ) factoryCfg.getEnvironment().clone();
         initialize();
     }
@@ -96,7 +101,7 @@
     private LdapDN parseNormalized( String name ) throws NamingException
     {
         LdapDN dn = new LdapDN( name );
-        dn.normalize();
+        dn.normalize( normalizerMap );
         return dn;
     }
 

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/enumeration/ReferralHandlingEnumeration.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/enumeration/ReferralHandlingEnumeration.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/enumeration/ReferralHandlingEnumeration.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/enumeration/ReferralHandlingEnumeration.java Fri Jun 16 00:37:25 2006
@@ -19,6 +19,7 @@
 
 import java.util.ArrayList;
 import java.util.List;
+import java.util.Map;
 import java.util.NoSuchElementException;
 
 import javax.naming.NamingEnumeration;
@@ -58,10 +59,15 @@
     private SearchResult prefetched;
     private int refIndex = -1;
 
+    /**
+     * The OIDs normalizer map
+     */
+    private Map normalizerMap;
 
     public ReferralHandlingEnumeration( NamingEnumeration underlying, ReferralLut lut, AttributeTypeRegistry registry,
         DirectoryPartitionNexus nexus, int scope, boolean doThrow ) throws NamingException
     {
+    	normalizerMap = registry.getNormalizerMapping();
         this.underlying = underlying;
         this.doThrow = doThrow;
         this.lut = lut;
@@ -77,7 +83,7 @@
         {
             SearchResult result = ( SearchResult ) underlying.next();
             LdapDN dn = new LdapDN( result.getName() );
-            dn.normalize();
+            dn.normalize( normalizerMap );
             
             if ( lut.isReferral( dn ) )
             {
@@ -165,7 +171,7 @@
         if ( refs == null )
         {
             LdapDN prefetchedDn = new LdapDN( prefetched.getName() );
-            prefetchedDn.normalize();
+            prefetchedDn.normalize( normalizerMap );
             refs = nexus.lookup( prefetchedDn ).get( REF_ATTR );
         }
 

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/event/EventService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/event/EventService.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/event/EventService.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/event/EventService.java Fri Jun 16 00:37:25 2006
@@ -95,7 +95,7 @@
         NamingListener namingListener ) throws NamingException
     {
         LdapDN normalizedBaseDn = new LdapDN( name );
-        normalizedBaseDn.normalize();
+        normalizedBaseDn.normalize( attributeRegistry.getNormalizerMapping() );
         
         // -------------------------------------------------------------------
         // must normalize the filter here: need to handle special cases
@@ -354,7 +354,7 @@
         LdapDN newName = ( LdapDN ) name.clone();
         newName.remove( newName.size() - 1 );
         newName.add( newRn );
-        newName.normalize();
+        newName.normalize( attributeRegistry.getNormalizerMapping() );
         notifyOnNameChange( name, newName );
     }
 

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/exception/ExceptionService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/exception/ExceptionService.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/exception/ExceptionService.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/exception/ExceptionService.java Fri Jun 16 00:37:25 2006
@@ -51,6 +51,10 @@
 {
     private DirectoryPartitionNexus nexus;
 
+    /**
+     * The OIDs normalizer map
+     */
+    private Map normalizerMap;
 
     /**
      * Creates an interceptor that is also the exception handling service.
@@ -60,9 +64,10 @@
     }
 
 
-    public void init( DirectoryServiceConfiguration factoryCfg, InterceptorConfiguration cfg )
+    public void init( DirectoryServiceConfiguration factoryCfg, InterceptorConfiguration cfg ) throws NamingException
     {
         nexus = factoryCfg.getPartitionNexus();
+        normalizerMap = factoryCfg.getGlobalRegistries().getAttributeTypeRegistry().getNormalizerMapping();
     }
 
 
@@ -271,7 +276,7 @@
         LdapDN newDn = ( LdapDN ) dn.clone();
         newDn.remove( dn.size() - 1 );
         newDn.add( newRn );
-        newDn.normalize();
+        newDn.normalize( normalizerMap );
         if ( nextInterceptor.hasEntry( newDn ) )
         {
             LdapNameAlreadyBoundException e;
@@ -337,7 +342,7 @@
         // check to see if target entry exists
         LdapDN target = ( LdapDN ) newParentName.clone();
         target.add( newRn );
-        target.normalize();
+        target.normalize( normalizerMap );
         if ( nextInterceptor.hasEntry( target ) )
         {
             // we must calculate the resolved name using the user provided Rdn value

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/normalization/NormalizationService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/normalization/NormalizationService.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/normalization/NormalizationService.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/normalization/NormalizationService.java Fri Jun 16 00:37:25 2006
@@ -86,14 +86,14 @@
     public void add(NextInterceptor nextInterceptor, LdapDN name, Attributes attrs)
         throws NamingException
     {
-        LdapDN normalized = LdapDN.normalize( name );
+        LdapDN normalized = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         nextInterceptor.add( normalized, attrs );
     }
 
 
     public void delete( NextInterceptor nextInterceptor, LdapDN name ) throws NamingException
     {
-        LdapDN normalized = LdapDN.normalize( name );
+        LdapDN normalized = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         nextInterceptor.delete( normalized );
     }
 
@@ -101,14 +101,14 @@
     public void modify( NextInterceptor nextInterceptor, LdapDN name, int modOp, Attributes attrs )
         throws NamingException
     {
-        LdapDN normalized = LdapDN.normalize( name );
+        LdapDN normalized = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         nextInterceptor.modify( normalized, modOp, attrs );
     }
 
 
     public void modify( NextInterceptor nextInterceptor, LdapDN name, ModificationItem[] items ) throws NamingException
     {
-        LdapDN normalized = LdapDN.normalize( name );
+        LdapDN normalized = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         nextInterceptor.modify( normalized, items );
     }
 
@@ -116,15 +116,15 @@
     public void modifyRn( NextInterceptor nextInterceptor, LdapDN name, String newRn, boolean deleteOldRn )
         throws NamingException
     {
-        LdapDN normalized = LdapDN.normalize( name );
+        LdapDN normalized = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         nextInterceptor.modifyRn( normalized, newRn, deleteOldRn );
     }
 
 
     public void move( NextInterceptor nextInterceptor, LdapDN name, LdapDN newParentName ) throws NamingException
     {
-        LdapDN normalized = LdapDN.normalize( name );
-        newParentName.normalize();
+        LdapDN normalized = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
+        newParentName.normalize( attributeRegistry.getNormalizerMapping());
         nextInterceptor.move( normalized, newParentName );
     }
 
@@ -132,8 +132,8 @@
     public void move( NextInterceptor nextInterceptor, LdapDN name, LdapDN newParentName, String newRn, boolean deleteOldRn )
         throws NamingException
     {
-        LdapDN normalized = LdapDN.normalize( name );
-        newParentName.normalize();
+        LdapDN normalized = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
+        newParentName.normalize( attributeRegistry.getNormalizerMapping());
         nextInterceptor.move( normalized, newParentName, newRn, deleteOldRn );
     }
 
@@ -141,7 +141,7 @@
     public NamingEnumeration search( NextInterceptor nextInterceptor, LdapDN base, Map env, ExprNode filter,
         SearchControls searchCtls ) throws NamingException
     {
-        base.normalize();
+        base.normalize( attributeRegistry.getNormalizerMapping());
 
         if ( filter.isLeaf() )
         {
@@ -229,35 +229,35 @@
 
     public boolean hasEntry( NextInterceptor nextInterceptor, LdapDN name ) throws NamingException
     {
-        name = LdapDN.normalize( name );
+        name = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         return nextInterceptor.hasEntry( name );
     }
 
 
     public boolean isSuffix( NextInterceptor nextInterceptor, LdapDN name ) throws NamingException
     {
-        name = LdapDN.normalize( name );
+        name = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         return nextInterceptor.isSuffix( name );
     }
 
 
     public NamingEnumeration list( NextInterceptor nextInterceptor, LdapDN base ) throws NamingException
     {
-        base = LdapDN.normalize( base );
+        base = LdapDN.normalize( base, attributeRegistry.getNormalizerMapping() );
         return nextInterceptor.list( base );
     }
 
 
     public Attributes lookup( NextInterceptor nextInterceptor, LdapDN name ) throws NamingException
     {
-        name = LdapDN.normalize( name );
+        name = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         return nextInterceptor.lookup( name );
     }
 
 
     public Attributes lookup( NextInterceptor nextInterceptor, LdapDN name, String[] attrIds ) throws NamingException
     {
-        name = LdapDN.normalize( name );
+        name = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         return nextInterceptor.lookup( name, attrIds );
     }
 
@@ -268,21 +268,21 @@
 
     public LdapDN getMatchedName ( NextInterceptor nextInterceptor, LdapDN name ) throws NamingException
     {
-        name = LdapDN.normalize( name );
+        name = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         return nextInterceptor.getMatchedName( name );
     }
 
 
     public LdapDN getSuffix ( NextInterceptor nextInterceptor, LdapDN name ) throws NamingException
     {
-        name = LdapDN.normalize( name );
+        name = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         return nextInterceptor.getSuffix( name );
     }
 
 
     public boolean compare( NextInterceptor next, LdapDN name, String oid, Object value ) throws NamingException
     {
-        name = LdapDN.normalize( name );
+        name = LdapDN.normalize( name, attributeRegistry.getNormalizerMapping() );
         return next.compare( name, oid, value );
     }
 
@@ -295,7 +295,7 @@
 
     public void removeContextPartition( NextInterceptor next, LdapDN suffix ) throws NamingException
     {
-        suffix = LdapDN.normalize( suffix );
+        suffix = LdapDN.normalize( suffix, attributeRegistry.getNormalizerMapping() );
         next.removeContextPartition( suffix );
     }
 }

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/operational/OperationalAttributeService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/operational/OperationalAttributeService.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/operational/OperationalAttributeService.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/operational/OperationalAttributeService.java Fri Jun 16 00:37:25 2006
@@ -180,7 +180,7 @@
         LdapDN newDn = ( LdapDN ) name.clone();
         newDn.remove( name.size() - 1 );
         newDn.add( newRn );
-        newDn.normalize();
+        newDn.normalize( registry.getNormalizerMapping() );
         nexus.modify( newDn, DirContext.REPLACE_ATTRIBUTE, attributes );
     }
 

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/AbstractDirectoryPartition.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/AbstractDirectoryPartition.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/AbstractDirectoryPartition.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/AbstractDirectoryPartition.java Fri Jun 16 00:37:25 2006
@@ -167,7 +167,7 @@
         if ( suffixDn == null )
         {
             suffixDn = new LdapDN( cfg.getSuffix() );
-            suffixDn.normalize();
+            suffixDn.normalize( factoryCfg.getGlobalRegistries().getAttributeTypeRegistry().getNormalizerMapping() );
         }
 
         return suffixDn;

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/DirectoryPartitionNexus.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/DirectoryPartitionNexus.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/DirectoryPartitionNexus.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/DirectoryPartitionNexus.java Fri Jun 16 00:37:25 2006
@@ -17,7 +17,9 @@
 package org.apache.directory.server.core.partition;
 
 
+import java.util.HashMap;
 import java.util.Iterator;
+import java.util.Map;
 import java.util.Set;
 
 import javax.naming.InvalidNameException;
@@ -27,6 +29,8 @@
 
 import org.apache.directory.server.core.configuration.DirectoryPartitionConfiguration;
 import org.apache.directory.shared.ldap.name.LdapDN;
+import org.apache.directory.shared.ldap.schema.NoOpNormalizer;
+import org.apache.directory.shared.ldap.schema.OidNormalizer;
 
 
 /**
@@ -53,6 +57,16 @@
     /** the base dn under which all groups reside */
     public final static String GROUPS_BASE_NAME = "ou=groups,ou=system";
 
+    /** UID attribute name and OID */
+    private static final String UID_ATTRIBUTE = "uid";
+    private static final String UID_ATTRIBUTE_ALIAS = "userid";
+    private static final String UID_ATTRIBUTE_OID = "0.9.2342.19200300.100.1.1";
+    
+    /** OU attribute names and OID **/
+    private static final String OU_ATTRIBUTE = "ou";
+    private static final String OU_ATTRIBUTE_ALIAS = "organizationalUnitName";
+    private static final String OU_ATTRIBUTE_OID = "2.5.4.11";
+
     /**
      * System partition suffix constant.  Should be kept down to a single Dn name 
      * component or the default constructor will have to parse it instead of 
@@ -81,7 +95,17 @@
         
         try
         {
-            adminDn.normalize();
+        	Map oidsMap = new HashMap();
+        	
+        	oidsMap.put( UID_ATTRIBUTE, new OidNormalizer( UID_ATTRIBUTE_OID, new NoOpNormalizer() ) );
+        	oidsMap.put( UID_ATTRIBUTE_ALIAS, new OidNormalizer( UID_ATTRIBUTE_OID, new NoOpNormalizer() ) );
+        	oidsMap.put( UID_ATTRIBUTE_OID, new OidNormalizer( UID_ATTRIBUTE_OID, new NoOpNormalizer() ) );
+        	
+        	oidsMap.put( OU_ATTRIBUTE, new OidNormalizer( OU_ATTRIBUTE_OID, new NoOpNormalizer()  ) );
+        	oidsMap.put( OU_ATTRIBUTE_ALIAS, new OidNormalizer( OU_ATTRIBUTE_OID, new NoOpNormalizer()  ) );
+        	oidsMap.put( OU_ATTRIBUTE_OID, new OidNormalizer( OU_ATTRIBUTE_OID, new NoOpNormalizer()  ) );
+
+            adminDn.normalize( oidsMap );
         }
         catch ( InvalidNameException ine )
         {

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreeDirectoryPartition.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreeDirectoryPartition.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreeDirectoryPartition.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/BTreeDirectoryPartition.java Fri Jun 16 00:37:25 2006
@@ -182,7 +182,7 @@
         if ( suffixOnDisk == null )
         {
             LdapDN suffix = new LdapDN( cfg.getSuffix() );
-            LdapDN normalizedSuffix = LdapDN.normalize( suffix );
+            LdapDN normalizedSuffix = LdapDN.normalize( suffix, attributeTypeRegistry.getNormalizerMapping() );
             add( normalizedSuffix, cfg.getContextEntry() );
         }
     }

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmDirectoryPartition.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmDirectoryPartition.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmDirectoryPartition.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/partition/impl/btree/jdbm/JdbmDirectoryPartition.java Fri Jun 16 00:37:25 2006
@@ -130,10 +130,8 @@
     {
         oidRegistry = factoryCfg.getGlobalRegistries().getOidRegistry();
         attrRegistry = factoryCfg.getGlobalRegistries().getAttributeTypeRegistry();
-        Map oids = factoryCfg.getGlobalRegistries().getAttributeTypeRegistry().getNormalizerMapping();
-        LdapDN.setOidsMap( oids );
         this.upSuffix = new LdapDN( cfg.getSuffix() );
-        this.normSuffix = LdapDN.normalize( upSuffix );
+        this.normSuffix = LdapDN.normalize( upSuffix, attrRegistry.getNormalizerMapping() );
 
         File workingDirectory = new File( factoryCfg.getStartupConfiguration().getWorkingDirectory().getPath()
             + File.separator + cfg.getName() );
@@ -648,7 +646,7 @@
 
         // Access aliasedObjectName, normalize it and generate the Name 
         normalizedAliasTargetDn = new LdapDN( aliasTarget );
-        normalizedAliasTargetDn.normalize();
+        normalizedAliasTargetDn.normalize( attrRegistry.getNormalizerMapping() );
 
         /*
          * Check For Cycles
@@ -1410,7 +1408,7 @@
         // Now we can handle the appropriate name indices for all cases
         ndnIdx.drop( id );
         
-        LdapDN normalizedDn = LdapDN.normalize( updn );
+        LdapDN normalizedDn = LdapDN.normalize( updn, attrRegistry.getNormalizerMapping() );
         ndnIdx.add( ndnIdx.getNormalized( normalizedDn.toNormName() ), id );
 
         updnIdx.drop( id );

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/referral/ReferralService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/referral/ReferralService.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/referral/ReferralService.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/referral/ReferralService.java Fri Jun 16 00:37:25 2006
@@ -201,7 +201,7 @@
             }
 
             LdapDN urlDn = new LdapDN( ldapUrl.getDn().toNormName() );
-            urlDn.normalize();
+            urlDn.normalize( attrRegistry.getNormalizerMapping() );
             if ( urlDn.equals( farthest ) )
             {
                 // according to the protocol there is no need for the dn since it is the same as this request
@@ -538,7 +538,7 @@
         newName.remove( oldName.size() - 1 );
 
         LdapDN newRdnName = new LdapDN( newRdn );
-        newRdnName.normalize();
+        newRdnName.normalize( attrRegistry.getNormalizerMapping() );
         newName.add( newRdnName.toNormName() );
 
         // handle a normal modify without following referrals
@@ -850,7 +850,7 @@
             LdapDN referral = null;
             LdapDN result = new LdapDN( r.getName() );
             //result = LdapDN.normalize( result, registry.getNormalizerMapping() );
-            result.normalize();
+            result.normalize( attrRegistry.getNormalizerMapping() );
             
             if ( r.isRelative() )
             {
@@ -872,7 +872,7 @@
             SearchResult r = ( SearchResult ) referrals.next();
             LdapDN referral = null;
             LdapDN result = new LdapDN( r.getName() );
-            result.normalize();
+            result.normalize( attrRegistry.getNormalizerMapping() );
 
             if ( r.isRelative() )
             {
@@ -1056,7 +1056,7 @@
             }
 
             LdapDN urlDn = new LdapDN( ldapUrl.getDn().toNormName() );
-            urlDn.normalize();
+            urlDn.normalize( attrRegistry.getNormalizerMapping() );
             int diff = targetUpdn.size() - farthest.size();
             LdapDN extra = new LdapDN();
             for ( int jj = 0; jj < diff; jj++ )
@@ -1106,7 +1106,7 @@
         }
 
         LdapDN dn = new LdapDN( name );
-        dn.normalize();
+        dn.normalize( attrRegistry.getNormalizerMapping() );
 
         if ( lut.isReferral( dn ) )
         {

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnComparator.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnComparator.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnComparator.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnComparator.java Fri Jun 16 00:37:25 2006
@@ -67,17 +67,17 @@
         LdapDN dn = null;
         if ( obj instanceof LdapDN )
         {
-            dn = LdapDN.normalize( ( LdapDN ) obj );
+            dn = LdapDN.normalize( ( LdapDN ) obj, attrRegistry.getNormalizerMapping() );
         }
         else if ( obj instanceof Name )
         {
             dn = new LdapDN( ( Name ) obj );
-            dn.normalize();
+            dn.normalize( attrRegistry.getNormalizerMapping() );
         }
         else if ( obj instanceof String )
         {
             dn = new LdapDN( ( String ) obj );
-            dn.normalize();
+            dn.normalize( attrRegistry.getNormalizerMapping() );
         }
         else
         {

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnNormalizer.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnNormalizer.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnNormalizer.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/schema/DnNormalizer.java Fri Jun 16 00:37:25 2006
@@ -58,7 +58,7 @@
             dn = new LdapDN( ( String ) value );
         }
         
-        dn.normalize();
+        dn.normalize( attrRegistry.getNormalizerMapping() );
         return dn;
     }
 }

Modified: directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/subtree/SubentryService.java
URL: http://svn.apache.org/viewvc/directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/subtree/SubentryService.java?rev=414767&r1=414766&r2=414767&view=diff
==============================================================================
--- directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/subtree/SubentryService.java (original)
+++ directory/branches/apacheds/optimization/core/src/main/java/org/apache/directory/server/core/subtree/SubentryService.java Fri Jun 16 00:37:25 2006
@@ -127,7 +127,7 @@
             {
                 return attrRegistry.getNormalizerMapping();
             }
-        });
+        }, attrRegistry.getNormalizerMapping() );
         evaluator = new SubtreeEvaluator( factoryCfg.getGlobalRegistries().getOidRegistry() );
 
         // prepare to find all subentries in all namingContexts
@@ -143,7 +143,7 @@
         {
             LdapDN suffix = new LdapDN( ( String ) suffixes.next() );
             //suffix = LdapDN.normalize( suffix, registry.getNormalizerMapping() );
-            suffix.normalize();
+            suffix.normalize( attrRegistry.getNormalizerMapping() );
             NamingEnumeration subentries = nexus.search( suffix, factoryCfg.getEnvironment(), filter, controls );
             while ( subentries.hasMore() )
             {
@@ -165,7 +165,7 @@
 
                 LdapDN dnName = new LdapDN( dn );
                 //dnName = LdapDN.normalize( dnName, registry.getNormalizerMapping() );
-                dnName.normalize();
+                dnName.normalize( attrRegistry.getNormalizerMapping() );
                 subtrees.put( dnName.toString(), ss );
             }
         }
@@ -414,7 +414,7 @@
                 SearchResult result = ( SearchResult ) subentries.next();
                 Attributes candidate = result.getAttributes();
                 LdapDN dn = new LdapDN( result.getName() );
-                dn.normalize();
+                dn.normalize( attrRegistry.getNormalizerMapping() );
 
                 if ( evaluator.evaluate( ss, apName, dn, candidate.get( "objectClass" ) ) )
                 {
@@ -541,7 +541,7 @@
                 SearchResult result = ( SearchResult ) subentries.next();
                 Attributes candidate = result.getAttributes();
                 LdapDN dn = new LdapDN( result.getName() );
-                dn.normalize();
+                dn.normalize( attrRegistry.getNormalizerMapping() );
 
                 if ( evaluator.evaluate( ss, apName, dn, ServerUtils.getAttribute( objectClassType, candidate ) ) )
                 {
@@ -676,8 +676,8 @@
 
             LdapDN rdn = new LdapDN( newRn );
             newName.addAll( rdn );
-            rdn.normalize();
-            newName.normalize();
+            rdn.normalize( attrRegistry.getNormalizerMapping() );
+            newName.normalize( attrRegistry.getNormalizerMapping() );
 
             subtrees.put( newName.toNormName(), ss );
             next.modifyRn( name, newRn, deleteOldRn );
@@ -694,7 +694,7 @@
                 SearchResult result = ( SearchResult ) subentries.next();
                 Attributes candidate = result.getAttributes();
                 LdapDN dn = new LdapDN( result.getName() );
-                dn.normalize();
+                dn.normalize( attrRegistry.getNormalizerMapping() );
 
                 if ( evaluator.evaluate( ss, apName, dn, ServerUtils.getAttribute( objectClassType, candidate ) ) )
                 {
@@ -717,7 +717,7 @@
             LdapDN newName = ( LdapDN ) name.clone();
             newName.remove( newName.size() - 1 );
             newName.add( newRn );
-            newName.normalize();
+            newName.normalize( attrRegistry.getNormalizerMapping() );
             ModificationItem[] mods = getModsOnEntryRdnChange( name, newName, entry );
 
             if ( mods.length > 0 )
@@ -746,8 +746,8 @@
 
             LdapDN rdn = new LdapDN( newRn );
             newName.addAll( rdn );
-            rdn.normalize();
-            newName.normalize();
+            rdn.normalize( attrRegistry.getNormalizerMapping() );
+            newName.normalize( attrRegistry.getNormalizerMapping() );
             
             subtrees.put( newName.toNormName(), ss );
             next.move( oriChildName, newParentName, newRn, deleteOldRn );
@@ -765,7 +765,7 @@
                 SearchResult result = ( SearchResult ) subentries.next();
                 Attributes candidate = result.getAttributes();
                 LdapDN dn = new LdapDN( result.getName() );
-                dn.normalize();
+                dn.normalize( attrRegistry.getNormalizerMapping() );
 
                 if ( evaluator.evaluate( ss, apName, dn, ServerUtils.getAttribute( objectClassType, candidate ) ) )
                 {
@@ -788,7 +788,7 @@
             // attributes contained within this regular entry with name changes
             LdapDN newName = ( LdapDN ) newParentName.clone();
             newName.add( newRn );
-            newName.normalize();
+            newName.normalize( attrRegistry.getNormalizerMapping() );
             ModificationItem[] mods = getModsOnEntryRdnChange( oriChildName, newName, entry );
 
             if ( mods.length > 0 )
@@ -832,7 +832,7 @@
                 SearchResult result = ( SearchResult ) subentries.next();
                 Attributes candidate = result.getAttributes();
                 LdapDN dn = new LdapDN( result.getName() );
-                dn.normalize();
+                dn.normalize( attrRegistry.getNormalizerMapping() );
 
                 if ( evaluator.evaluate( ss, apName, dn, candidate.get( "objectClass" ) ) )
                 {
@@ -909,7 +909,7 @@
                 SearchResult result = ( SearchResult ) subentries.next();
                 Attributes candidate = result.getAttributes();
                 LdapDN dn = new LdapDN( result.getName() );
-                dn.normalize();
+                dn.normalize( attrRegistry.getNormalizerMapping() );
 
                 if ( evaluator.evaluate( ssOld, apName, dn, ServerUtils.getAttribute( objectClassType, candidate ) ) )
                 {
@@ -929,7 +929,7 @@
                 SearchResult result = ( SearchResult ) subentries.next();
                 Attributes candidate = result.getAttributes();
                 LdapDN dn = new LdapDN( result.getName() );
-                dn.normalize();
+                dn.normalize( attrRegistry.getNormalizerMapping() );
 
                 if ( evaluator.evaluate( ssNew, apName, dn, ServerUtils.getAttribute( objectClassType, candidate ) ) )
                 {
@@ -995,7 +995,7 @@
                 SearchResult result = ( SearchResult ) subentries.next();
                 Attributes candidate = result.getAttributes();
                 LdapDN dn = new LdapDN( result.getName() );
-                dn.normalize();
+                dn.normalize( attrRegistry.getNormalizerMapping() );
 
                 if ( evaluator.evaluate( ssOld, apName, dn, candidate.get( "objectClass" ) ) )
                 {
@@ -1015,7 +1015,7 @@
                 SearchResult result = ( SearchResult ) subentries.next();
                 Attributes candidate = result.getAttributes();
                 LdapDN dn = new LdapDN( result.getName() );
-                dn.normalize();
+                dn.normalize( attrRegistry.getNormalizerMapping() );
 
                 if ( evaluator.evaluate( ssNew, apName, dn, candidate.get( "objectClass" ) ) )
                 {
@@ -1327,16 +1327,16 @@
             if ( !result.isRelative() )
             {
                 LdapDN ndn = new LdapDN( dn );
-                ndn.normalize();
+                ndn.normalize( attrRegistry.getNormalizerMapping() );
                 String normalizedDn = ndn.toString();
                 return !subtrees.containsKey( normalizedDn );
             }
 
             LdapDN name = new LdapDN( invocation.getCaller().getNameInNamespace() );
-            name.normalize();
+            name.normalize( attrRegistry.getNormalizerMapping() );
 
             LdapDN rest = new LdapDN( result.getName() );
-            rest.normalize();
+            rest.normalize( attrRegistry.getNormalizerMapping() );
             name.addAll( rest );
             return !subtrees.containsKey( name.toString() );
         }
@@ -1388,15 +1388,15 @@
             if ( !result.isRelative() )
             {
                 LdapDN ndn = new LdapDN( dn );
-                ndn.normalize();
+                ndn.normalize( attrRegistry.getNormalizerMapping() );
                 return subtrees.containsKey( ndn.toNormName() );
             }
 
             LdapDN name = new LdapDN( invocation.getCaller().getNameInNamespace() );
-            name.normalize();
+            name.normalize( attrRegistry.getNormalizerMapping() );
 
             LdapDN rest = new LdapDN( result.getName() );
-            rest.normalize();
+            rest.normalize( attrRegistry.getNormalizerMapping() );
             name.addAll( rest );
             return subtrees.containsKey( name.toNormName() );
         }



Mime
View raw message