incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From i..@apache.org
Subject svn commit: r897050 - /sling/trunk/bundles/jcr/jackrabbit-server/src/main/java/org/apache/sling/jcr/jackrabbit/server/impl/security/PluggableDefaultAccessManager.java
Date Thu, 07 Jan 2010 23:16:12 GMT
Author: ieb
Date: Thu Jan  7 23:16:11 2010
New Revision: 897050

URL: http://svn.apache.org/viewvc?rev=897050&view=rev
Log:
SLING-1263 Patch to make the PulggableDefaultAccessManager use the checks in the DefaultAccessManager
for certain permissions. The method is deprecated, but still used.

Modified:
    sling/trunk/bundles/jcr/jackrabbit-server/src/main/java/org/apache/sling/jcr/jackrabbit/server/impl/security/PluggableDefaultAccessManager.java

Modified: sling/trunk/bundles/jcr/jackrabbit-server/src/main/java/org/apache/sling/jcr/jackrabbit/server/impl/security/PluggableDefaultAccessManager.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/jcr/jackrabbit-server/src/main/java/org/apache/sling/jcr/jackrabbit/server/impl/security/PluggableDefaultAccessManager.java?rev=897050&r1=897049&r2=897050&view=diff
==============================================================================
--- sling/trunk/bundles/jcr/jackrabbit-server/src/main/java/org/apache/sling/jcr/jackrabbit/server/impl/security/PluggableDefaultAccessManager.java
(original)
+++ sling/trunk/bundles/jcr/jackrabbit-server/src/main/java/org/apache/sling/jcr/jackrabbit/server/impl/security/PluggableDefaultAccessManager.java
Thu Jan  7 23:16:11 2010
@@ -23,7 +23,6 @@
 import javax.jcr.Session;
 import javax.security.auth.Subject;
 
-import org.apache.jackrabbit.core.HierarchyManager;
 import org.apache.jackrabbit.core.ItemId;
 import org.apache.jackrabbit.core.security.AMContext;
 import org.apache.jackrabbit.core.security.DefaultAccessManager;
@@ -56,10 +55,9 @@
  */
 public class PluggableDefaultAccessManager extends DefaultAccessManager {
 
-    /** @scr.reference */ @SuppressWarnings({"UnusedDeclaration"})
+    /** @scr.reference */ 
     private AccessManagerPlugin accessManagerPlugin;
     private NamePathResolver namePathResolver;
-    private HierarchyManager hierarchyManager;
     private static final Logger log = LoggerFactory.getLogger(PluggableDefaultAccessManager.class);
     protected AccessManagerPluginFactory accessManagerFactory;
     protected AccessManagerFactoryTracker accessManagerFactoryTracker;
@@ -88,7 +86,6 @@
         this.sanityCheck();
         super.init(context, acProvider, wspAccessMgr);
         this.namePathResolver = context.getNamePathResolver();
-        this.hierarchyManager = context.getHierarchyManager();
         if (this.accessManagerPlugin != null) {
             this.accessManagerPlugin.init(context.getSubject(), context.getSession());
         }
@@ -117,7 +114,7 @@
     }
 
     public boolean isGranted(ItemId id, int permissions) throws ItemNotFoundException, RepositoryException
{
-        return this.isGranted(this.hierarchyManager.getPath(id), permissions);
+        return super.isGranted(id, permissions);
     }
 
     public boolean isGranted(Path absPath, int permissions) throws RepositoryException {



Mime
View raw message