directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r959913 - in /directory/apacheds/trunk/core/src: main/java/org/apache/directory/server/core/authz/ main/java/org/apache/directory/server/core/authz/support/ main/java/org/apache/directory/server/core/event/ main/java/org/apache/directory/se...
Date Fri, 02 Jul 2010 08:09:52 GMT
Author: elecharny
Date: Fri Jul  2 08:09:51 2010
New Revision: 959913

URL: http://svn.apache.org/viewvc?rev=959913&view=rev
Log:
o Removed the OidRegistry parameter when the SchemaManager is already a parameter
o Removed useless global variables

Modified:
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/AciAuthorizationInterceptor.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/EventInterceptor.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/ExpressionEvaluator.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubentryInterceptor.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubtreeEvaluator.java
    directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java
    directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java
    directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/AciAuthorizationInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/AciAuthorizationInterceptor.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/AciAuthorizationInterceptor.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/AciAuthorizationInterceptor.java
Fri Jul  2 08:09:51 2010
@@ -90,12 +90,6 @@ public class AciAuthorizationInterceptor
     /** the logger for this class */
     private static final Logger LOG = LoggerFactory.getLogger( AciAuthorizationInterceptor.class
);
 
-    /**
-     * the multivalued op attr used to track the prescriptive access control
-     * subentries that apply to an entry.
-     */
-    private static final String AC_SUBENTRY_ATTR = "accessControlSubentries";
-
     private static final Collection<MicroOperation> ADD_PERMS;
     private static final Collection<MicroOperation> READ_PERMS;
     private static final Collection<MicroOperation> COMPARE_PERMS;
@@ -169,8 +163,6 @@ public class AciAuthorizationInterceptor
     private AttributeType objectClassType;
     private AttributeType acSubentryType;
 
-    private String subentryOid;
-
     /** A storage for the entryACI attributeType */
     private AttributeType entryAciType;
 
@@ -182,7 +174,7 @@ public class AciAuthorizationInterceptor
 
     /**
      * Initializes this interceptor based service by getting a handle on the nexus, setting
up
-     * the tupe and group membership caches and the ACIItem parser and the ACDF engine.
+     * the tuple and group membership caches, the ACIItem parser and the ACDF engine.
      *
      * @param directoryService the directory service core
      * @throws Exception if there are problems during initialization
@@ -191,7 +183,7 @@ public class AciAuthorizationInterceptor
     {
         super.init( directoryService );
 
-        DN adminDn = new DN( ServerDNConstants.ADMIN_SYSTEM_DN_NORMALIZED );
+        DN adminDn = new DN( ServerDNConstants.ADMIN_SYSTEM_DN );
         adminDn.normalize( directoryService.getSchemaManager().getNormalizerMapping() );
         CoreSession adminSession = new DefaultCoreSession( new LdapPrincipal( adminDn, AuthenticationLevel.STRONG
),
             directoryService );
@@ -199,19 +191,15 @@ public class AciAuthorizationInterceptor
         tupleCache = new TupleCache( adminSession );
         groupCache = new GroupCache( adminSession );
         schemaManager = directoryService.getSchemaManager();
-        //ocRegistry = registries.getObjectClassRegistry();
 
         // look up some constant information
-        String objectClassOid = schemaManager.getAttributeTypeRegistry().getOidByName( SchemaConstants.OBJECT_CLASS_AT
);
-        subentryOid = schemaManager.getObjectClassRegistry().getOidByName( SchemaConstants.SUBENTRY_OC
);
-        String acSubentryOid = schemaManager.getAttributeTypeRegistry().getOidByName( AC_SUBENTRY_ATTR
);
-        objectClassType = schemaManager.lookupAttributeTypeRegistry( objectClassOid );
-        acSubentryType = schemaManager.lookupAttributeTypeRegistry( acSubentryOid );
+        objectClassType = schemaManager.lookupAttributeTypeRegistry( SchemaConstants.OBJECT_CLASS_AT
);
+        acSubentryType = schemaManager.lookupAttributeTypeRegistry( SchemaConstants.ACCESS_CONTROL_SUBENTRIES_AT
);
         entryAciType = schemaManager.lookupAttributeTypeRegistry( SchemaConstants.ENTRY_ACI_AT_OID
);
         subentryAciType = schemaManager.lookupAttributeTypeRegistry( SchemaConstants.SUBENTRY_ACI_AT_OID
);
 
         aciParser = new ACIItemParser( new ConcreteNameComponentNormalizer( schemaManager
), schemaManager );
-        engine = new ACDFEngine( schemaManager.getGlobalOidRegistry(), schemaManager );
+        engine = new ACDFEngine( schemaManager );
         chain = directoryService.getInterceptorChain();
 
         // stuff for dealing with subentries (garbage for now)
@@ -280,7 +268,7 @@ public class AciAuthorizationInterceptor
          * to be in the same naming context as their access point so the subentries
          * effecting their parent entry applies to them as well.
          */
-        if ( oc.contains( SchemaConstants.SUBENTRY_OC ) || oc.contains( subentryOid ) )
+        if ( oc.contains( SchemaConstants.SUBENTRY_OC ) )
         {
             DN parentDn = ( DN ) dn.clone();
             parentDn.remove( dn.size() - 1 );
@@ -422,11 +410,10 @@ public class AciAuthorizationInterceptor
         DN principalDn = principal.getDN();
 
         Entry serverEntry = addContext.getEntry();
-        //Attributes entry = ServerEntryUtils.toAttributesImpl( serverEntry );
 
-        DN name = addContext.getDn();
+        DN dn = addContext.getDn();
 
-        // bypass authz code if we are disabled
+        // bypass authz code if it was disabled
         if ( !addContext.getSession().getDirectoryService().isAccessControlEnabled() )
         {
             next.add( addContext );
@@ -437,15 +424,15 @@ public class AciAuthorizationInterceptor
         if ( isPrincipalAnAdministrator( principalDn ) )
         {
             next.add( addContext );
-            tupleCache.subentryAdded( name, serverEntry );
-            groupCache.groupAdded( name, serverEntry );
+            tupleCache.subentryAdded( dn, serverEntry );
+            groupCache.groupAdded( dn, serverEntry );
             return;
         }
 
         // perform checks below here for all non-admin users
         SubentryInterceptor subentryInterceptor = ( SubentryInterceptor ) chain.get( SubentryInterceptor.class
             .getName() );
-        Entry subentryAttrs = subentryInterceptor.getSubentryAttributes( name, serverEntry
);
+        Entry subentryAttrs = subentryInterceptor.getSubentryAttributes( dn, serverEntry
);
 
         for ( EntryAttribute attribute : serverEntry )
         {
@@ -458,12 +445,12 @@ public class AciAuthorizationInterceptor
 
         // Build the total collection of tuples to be considered for add rights
         // NOTE: entryACI are NOT considered in adds (it would be a security breech)
-        addPerscriptiveAciTuples( addContext, tuples, name, subentryAttrs );
-        addSubentryAciTuples( addContext, tuples, name, subentryAttrs );
+        addPerscriptiveAciTuples( addContext, tuples, dn, subentryAttrs );
+        addSubentryAciTuples( addContext, tuples, dn, subentryAttrs );
 
         // check if entry scope permission is granted
         engine.checkPermission( schemaManager, addContext, userGroups, principalDn, principal.getAuthenticationLevel(),
-            name, null, null, ADD_PERMS, tuples, subentryAttrs, null );
+            dn, null, null, ADD_PERMS, tuples, subentryAttrs, null );
 
         // now we must check if attribute type and value scope permission is granted
         for ( EntryAttribute attribute : serverEntry )
@@ -471,7 +458,7 @@ public class AciAuthorizationInterceptor
             for ( Value<?> value : attribute )
             {
                 engine.checkPermission( schemaManager, addContext, userGroups, principalDn,
principal
-                    .getAuthenticationLevel(), name, attribute.getAttributeType(), value,
ADD_PERMS, tuples, serverEntry, null );
+                    .getAuthenticationLevel(), dn, attribute.getAttributeType(), value, ADD_PERMS,
tuples, serverEntry, null );
             }
         }
 
@@ -480,8 +467,8 @@ public class AciAuthorizationInterceptor
 
         // if the entry added is a subentry or a groupOf[Unique]Names we must
         // update the ACITuple cache and the groups cache to keep them in sync
-        tupleCache.subentryAdded( name, serverEntry );
-        groupCache.groupAdded( name, serverEntry );
+        tupleCache.subentryAdded( dn, serverEntry );
+        groupCache.groupAdded( dn, serverEntry );
     }
 
 

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/TupleCache.java
Fri Jul  2 08:09:51 2010
@@ -84,6 +84,9 @@ public class TupleCache
     /** A storage for the PrescriptiveACI attributeType */
     private AttributeType prescriptiveAciAT;
 
+    /** A storage for the ObjectClass attributeType */
+    private static AttributeType OBJECT_CLASS_AT;
+
 
     /**
      * Creates a ACITuple cache.
@@ -98,6 +101,7 @@ public class TupleCache
         NameComponentNormalizer ncn = new ConcreteNameComponentNormalizer( schemaManager
);
         aciParser = new ACIItemParser( ncn, schemaManager );
         prescriptiveAciAT = schemaManager.lookupAttributeTypeRegistry( SchemaConstants.PRESCRIPTIVE_ACI_AT
);
+        OBJECT_CLASS_AT = schemaManager.lookupAttributeTypeRegistry( SchemaConstants.OBJECT_CLASS_AT
);
         initialize( session );
     }
 
@@ -160,6 +164,9 @@ public class TupleCache
     }
 
 
+    /** 
+     * Check if the Entry contains a prescriptiveACI 
+     */
     private boolean hasPrescriptiveACI( Entry entry ) throws LdapException
     {
         // only do something if the entry contains prescriptiveACI
@@ -167,8 +174,7 @@ public class TupleCache
 
         if ( aci == null )
         {
-            if ( entry.contains( SchemaConstants.OBJECT_CLASS_AT, SchemaConstants.ACCESS_CONTROL_SUBENTRY_OC
)
-                || entry.contains( SchemaConstants.OBJECT_CLASS_AT, SchemaConstants.ACCESS_CONTROL_SUBENTRY_OC_OID
) )
+            if ( entry.contains( OBJECT_CLASS_AT, SchemaConstants.ACCESS_CONTROL_SUBENTRY_OC
) )
             {
                 // should not be necessary because of schema interceptor but schema checking
                 // can be turned off and in this case we must protect against being able
to
@@ -185,19 +191,22 @@ public class TupleCache
     }
 
 
-    public void subentryAdded( DN normName, Entry entry ) throws LdapException
+    public void subentryAdded( DN dn, Entry entry ) throws LdapException
     {
-        // only do something if the entry contains prescriptiveACI
-        EntryAttribute aciAttr = entry.get( prescriptiveAciAT );
-
+        // only do something if the entry contains a prescriptiveACI
         if ( !hasPrescriptiveACI( entry ) )
         {
             return;
         }
 
+        // Get the prescriptiveACI
+        EntryAttribute prescriptiveAci = entry.get( prescriptiveAciAT );
+
         List<ACITuple> entryTuples = new ArrayList<ACITuple>();
 
-        for ( Value<?> value : aciAttr )
+        // Loop on all the ACI, parse each of them and
+        // store the associated tuples into the cache
+        for ( Value<?> value : prescriptiveAci )
         {
             String aci = value.getString();
             ACIItem item = null;
@@ -217,7 +226,7 @@ public class TupleCache
             }
         }
 
-        tuples.put( normName.getNormName(), entryTuples );
+        tuples.put( dn.getNormName(), entryTuples );
     }
 
 

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/ACDFEngine.java
Fri Jul  2 08:09:51 2010
@@ -50,7 +50,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.name.DN;
 import org.apache.directory.shared.ldap.schema.AttributeType;
 import org.apache.directory.shared.ldap.schema.SchemaManager;
-import org.apache.directory.shared.ldap.schema.registries.OidRegistry;
 
 
 /**
@@ -88,15 +87,15 @@ public class ACDFEngine
      * 
      * @throws LdapException if failed to initialize internal components
      */
-    public ACDFEngine( OidRegistry oidRegistry, SchemaManager schemaManager ) throws LdapException
+    public ACDFEngine( SchemaManager schemaManager ) throws LdapException
     {
-        Evaluator entryEvaluator = new ExpressionEvaluator( oidRegistry, schemaManager );
-        SubtreeEvaluator subtreeEvaluator = new SubtreeEvaluator( oidRegistry, schemaManager
);
-        RefinementEvaluator refinementEvaluator = new RefinementEvaluator( new RefinementLeafEvaluator(
oidRegistry ) );
+        Evaluator entryEvaluator = new ExpressionEvaluator( schemaManager );
+        SubtreeEvaluator subtreeEvaluator = new SubtreeEvaluator( schemaManager );
+        RefinementEvaluator refinementEvaluator = new RefinementEvaluator( new RefinementLeafEvaluator(
schemaManager.getGlobalOidRegistry() ) );
 
         filters = new ACITupleFilter[] {
             new RelatedUserClassFilter( subtreeEvaluator ),
-            new RelatedProtectedItemFilter( refinementEvaluator, entryEvaluator, oidRegistry,
schemaManager ),
+            new RelatedProtectedItemFilter( refinementEvaluator, entryEvaluator, schemaManager
),
             new MaxValueCountFilter(),
             new MaxImmSubFilter(),
             new RestrictedByFilter(),

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilter.java
Fri Jul  2 08:09:51 2010
@@ -50,7 +50,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.name.DN;
 import org.apache.directory.shared.ldap.schema.AttributeType;
 import org.apache.directory.shared.ldap.schema.SchemaManager;
-import org.apache.directory.shared.ldap.schema.registries.OidRegistry;
 
 
 /**
@@ -66,8 +65,7 @@ public class RelatedProtectedItemFilter 
     private final SchemaManager schemaManager;
 
 
-    public RelatedProtectedItemFilter( RefinementEvaluator refinementEvaluator, Evaluator
entryEvaluator, 
-        OidRegistry oidRegistry, SchemaManager schemaManager )
+    public RelatedProtectedItemFilter( RefinementEvaluator refinementEvaluator, Evaluator
entryEvaluator, SchemaManager schemaManager )
     {
         this.refinementEvaluator = refinementEvaluator;
         this.entryEvaluator = entryEvaluator;

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/EventInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/EventInterceptor.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/EventInterceptor.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/EventInterceptor.java
Fri Jul  2 08:09:51 2010
@@ -49,7 +49,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.name.NameComponentNormalizer;
 import org.apache.directory.shared.ldap.schema.SchemaManager;
 import org.apache.directory.shared.ldap.schema.normalizers.ConcreteNameComponentNormalizer;
-import org.apache.directory.shared.ldap.schema.registries.OidRegistry;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -78,11 +77,10 @@ public class EventInterceptor extends Ba
         super.init( ds );
 
         this.ds = ds;
-        OidRegistry oidRegistry = ds.getSchemaManager().getGlobalOidRegistry();
         SchemaManager schemaManager = ds.getSchemaManager();
         NameComponentNormalizer ncn = new ConcreteNameComponentNormalizer( schemaManager
);
         filterNormalizer = new FilterNormalizingVisitor( ncn, schemaManager );
-        evaluator = new ExpressionEvaluator( oidRegistry, schemaManager );
+        evaluator = new ExpressionEvaluator( schemaManager );
         executor = new ThreadPoolExecutor( 1, 10, 1000, TimeUnit.MILLISECONDS, new ArrayBlockingQueue<Runnable>(
100 ) );
 
         this.ds.setEventService( new DefaultEventService() );

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/ExpressionEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/ExpressionEvaluator.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/ExpressionEvaluator.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/event/ExpressionEvaluator.java
Fri Jul  2 08:09:51 2010
@@ -31,7 +31,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.filter.OrNode;
 import org.apache.directory.shared.ldap.name.DN;
 import org.apache.directory.shared.ldap.schema.SchemaManager;
-import org.apache.directory.shared.ldap.schema.registries.OidRegistry;
 
 
 
@@ -69,7 +68,7 @@ public class ExpressionEvaluator impleme
      * @param oidRegistry the oid reg used for attrID to oid resolution
      * @param attributeTypeRegistry the attribtype reg used for value comparison
      */
-    public ExpressionEvaluator( OidRegistry oidRegistry, SchemaManager schemaManager )
+    public ExpressionEvaluator( SchemaManager schemaManager )
     {
         SubstringEvaluator substringEvaluator = null;
         substringEvaluator = new SubstringEvaluator( schemaManager );

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubentryInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubentryInterceptor.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubentryInterceptor.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubentryInterceptor.java
Fri Jul  2 08:09:51 2010
@@ -82,7 +82,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.schema.NormalizerMappingResolver;
 import org.apache.directory.shared.ldap.schema.SchemaManager;
 import org.apache.directory.shared.ldap.schema.normalizers.OidNormalizer;
-import org.apache.directory.shared.ldap.schema.registries.OidRegistry;
 import org.apache.directory.shared.ldap.subtree.SubtreeSpecification;
 import org.apache.directory.shared.ldap.subtree.SubtreeSpecificationParser;
 import org.slf4j.Logger;
@@ -127,9 +126,6 @@ public class SubentryInterceptor extends
     /** The global registries */
     private SchemaManager schemaManager;
 
-    /** The OID registry */
-    private OidRegistry oidRegistry;
-
     private AttributeType objectClassType;
 
 
@@ -138,7 +134,6 @@ public class SubentryInterceptor extends
         super.init( directoryService );
         nexus = directoryService.getPartitionNexus();
         schemaManager = directoryService.getSchemaManager();
-        oidRegistry = schemaManager.getGlobalOidRegistry();
 
         // setup various attribute type values
         objectClassType = schemaManager.lookupAttributeTypeRegistry( schemaManager.getAttributeTypeRegistry()
@@ -151,7 +146,7 @@ public class SubentryInterceptor extends
                 return schemaManager.getNormalizerMapping();
             }
         }, schemaManager.getNormalizerMapping() );
-        evaluator = new SubtreeEvaluator( oidRegistry, schemaManager );
+        evaluator = new SubtreeEvaluator( schemaManager );
 
         // prepare to find all subentries in all namingContexts
         Set<String> suffixes = nexus.listSuffixes();

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubtreeEvaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubtreeEvaluator.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubtreeEvaluator.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/subtree/SubtreeEvaluator.java
Fri Jul  2 08:09:51 2010
@@ -28,7 +28,6 @@ import org.apache.directory.shared.ldap.
 import org.apache.directory.shared.ldap.exception.LdapException;
 import org.apache.directory.shared.ldap.name.DN;
 import org.apache.directory.shared.ldap.schema.SchemaManager;
-import org.apache.directory.shared.ldap.schema.registries.OidRegistry;
 import org.apache.directory.shared.ldap.subtree.SubtreeSpecification;
 import org.apache.directory.shared.ldap.util.NamespaceTools;
 
@@ -52,9 +51,9 @@ public class SubtreeEvaluator
      * @param oidRegistry a registry used to lookup objectClass names for OIDs
      * @param attrRegistry registry to be looked up
      */
-    public SubtreeEvaluator( OidRegistry oidRegistry, SchemaManager schemaManager )
+    public SubtreeEvaluator( SchemaManager schemaManager )
     {
-        evaluator = new ExpressionEvaluator( oidRegistry, schemaManager );
+        evaluator = new ExpressionEvaluator( schemaManager );
     }
 
 

Modified: directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java
(original)
+++ directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedProtectedItemFilterTest.java
Fri Jul  2 08:09:51 2010
@@ -121,10 +121,10 @@ public class RelatedProtectedItemFilterT
         USER_NAME = new DN( "ou=test, ou=users, ou=system" );
         
         filterA = new RelatedProtectedItemFilter( new RefinementEvaluator( new RefinementLeafEvaluator(
-            OID_REGISTRY ) ), new ExpressionEvaluator( OID_REGISTRY, schemaManager ), OID_REGISTRY,
schemaManager );
+            OID_REGISTRY ) ), new ExpressionEvaluator( schemaManager ), schemaManager );
 
         filterB = new RelatedProtectedItemFilter( new RefinementEvaluator( new RefinementLeafEvaluator(
-            OID_REGISTRY ) ), new ExpressionEvaluator( OID_REGISTRY, schemaManager ), OID_REGISTRY,
schemaManager );
+            OID_REGISTRY ) ), new ExpressionEvaluator( schemaManager ), schemaManager );
 
         USER_NAMES.add( USER_NAME );
         GROUP_NAMES.add( GROUP_NAME );

Modified: directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java
(original)
+++ directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/authz/support/RelatedUserClassFilterTest.java
Fri Jul  2 08:09:51 2010
@@ -70,7 +70,7 @@ public class RelatedUserClassFilterTest
     @BeforeClass
     public static void init() throws Exception
     {
-        SUBTREE_EVALUATOR = new SubtreeEvaluator( new DummyOidRegistry(), new DefaultSchemaManager(
null ) );
+        SUBTREE_EVALUATOR = new SubtreeEvaluator( new DefaultSchemaManager( null ) );
         filter = new RelatedUserClassFilter( SUBTREE_EVALUATOR );
         
         try

Modified: directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java?rev=959913&r1=959912&r2=959913&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java
(original)
+++ directory/apacheds/trunk/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java
Fri Jul  2 08:09:51 2010
@@ -94,7 +94,7 @@ public class SubtreeEvaluatorTest
         ncn = new ConcreteNameComponentNormalizer( schemaManager );
 
         visitor = new FilterNormalizingVisitor( ncn, schemaManager );
-        evaluator = new SubtreeEvaluator( schemaManager.getGlobalOidRegistry(), schemaManager
);
+        evaluator = new SubtreeEvaluator( schemaManager );
     }
 
 



Mime
View raw message