mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
RM-972 (RM is not backwards compatible with the Community version)
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/modules/recordsmanagement/HEAD@55439 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -65,7 +65,7 @@
|
|||||||
<!-- Note: ff the context evaluates to null (e.g. doing an exists test on a node -->
|
<!-- Note: ff the context evaluates to null (e.g. doing an exists test on a node -->
|
||||||
<!-- that does not exist) then access will be allowed. -->
|
<!-- that does not exist) then access will be allowed. -->
|
||||||
|
|
||||||
<bean id="aclEntryVoter" class="org.alfresco.repo.security.permissions.impl.acegi.ACLEntryVoter" abstract="false" singleton="true" lazy-init="default" autowire="default" dependency-check="default">
|
<bean id="aclEntryVoter" class="org.alfresco.repo.security.permissions.impl.acegi.RMACLEntryVoter" abstract="false" singleton="true" lazy-init="default" autowire="default" dependency-check="default">
|
||||||
<property name="permissionService">
|
<property name="permissionService">
|
||||||
<ref bean="permissionService"></ref>
|
<ref bean="permissionService"></ref>
|
||||||
</property>
|
</property>
|
||||||
|
@@ -0,0 +1,51 @@
|
|||||||
|
/*
|
||||||
|
* Copyright (C) 2005-2012 Alfresco Software Limited.
|
||||||
|
*
|
||||||
|
* This file is part of Alfresco
|
||||||
|
*
|
||||||
|
* Alfresco is free software: you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU Lesser General Public License as published by
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* Alfresco is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU Lesser General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU Lesser General Public License
|
||||||
|
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
package org.alfresco.repo.security.permissions.impl.acegi;
|
||||||
|
|
||||||
|
import java.lang.reflect.Method;
|
||||||
|
|
||||||
|
import org.alfresco.service.cmr.security.OwnableService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This is a workaround to make RM 2.1 backwards compatible with the Community version 4.2.d.
|
||||||
|
* This class will be removed after Community 4.2.e has been released.
|
||||||
|
*
|
||||||
|
* @author Tuna Aksoy
|
||||||
|
* @since 2.1
|
||||||
|
*/
|
||||||
|
public class RMACLEntryVoter extends ACLEntryVoter
|
||||||
|
{
|
||||||
|
public void setOwnableService(OwnableService ownableService)
|
||||||
|
{
|
||||||
|
boolean exists = false;
|
||||||
|
Method[] declaredMethods = ACLEntryVoter.class.getDeclaredMethods();
|
||||||
|
for (Method method : declaredMethods)
|
||||||
|
{
|
||||||
|
if (method.getName().equals("setOwnableService"))
|
||||||
|
{
|
||||||
|
exists = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (exists)
|
||||||
|
{
|
||||||
|
super.setOwnableService(ownableService);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Reference in New Issue
Block a user