mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Exported AuthenticationService via RMI. Insecure for now but we can switch over
to using SSL when needed. Restructured exports of AVM specific apis to authenticate remotely and pass the ticket with each remote service call. These required some changes to jndi-client and even to the web-client which uses the AVM remote interface within the Alfresco server. Oh, the point of this is that since I'm writing some CLTs, I might as well do them correctly; we'll need the option of security sooner rather than later. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@4489 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -3,24 +3,36 @@
|
||||
|
||||
<beans>
|
||||
<!-- Remote AVM interface -->
|
||||
<bean id="avmRemote" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
|
||||
<bean id="avmRemote" class="org.alfresco.repo.avm.clt.AVMRemoteImpl">
|
||||
<property name="avmRemoteTransport">
|
||||
<ref bean="avmRemoteTransport"/>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="avmRemoteTransport" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
|
||||
<property name="serviceUrl">
|
||||
<value>rmi://localhost:1313/avm</value>
|
||||
</property>
|
||||
<property name="serviceInterface">
|
||||
<value>org.alfresco.repo.avm.AVMRemote</value>
|
||||
<value>org.alfresco.repo.avm.AVMRemoteTransport</value>
|
||||
</property>
|
||||
<property name="refreshStubOnConnectFailure">
|
||||
<value>true</value>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="avmSyncService" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
|
||||
<bean id="avmSyncService" class="org.alfresco.repo.avm.clt.AVMSyncServiceClient">
|
||||
<property name="avmSyncServiceTransport">
|
||||
<ref bean="avmSyncServiceTransport"/>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="avmSyncServiceTransport" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
|
||||
<property name="serviceUrl">
|
||||
<value>rmi://localhost:1313/avmsync</value>
|
||||
</property>
|
||||
<property name="serviceInterface">
|
||||
<value>org.alfresco.service.cmr.avmsync.AVMSyncService</value>
|
||||
<value>org.alfresco.service.cmr.avmsync.AVMSyncServiceTransport</value>
|
||||
</property>
|
||||
<property name="refreshStubOnConnectFailure">
|
||||
<value>true</value>
|
||||
|
@@ -177,9 +177,16 @@
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- A Local implementation of the Remote AVM interface. -->
|
||||
<bean id="avmRemote" class="org.alfresco.repo.avm.AVMRemoteLocal">
|
||||
<property name="avmService">
|
||||
<ref bean="AVMService"/>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- The remote interface implementation. -->
|
||||
|
||||
<bean id="avmRemote" class="org.alfresco.repo.avm.AVMRemoteImpl"
|
||||
<bean id="avmRemoteTransport" class="org.alfresco.repo.avm.AVMRemoteTransportService"
|
||||
init-method="init" destroy-method="shutDown">
|
||||
<property name="idleTimeout">
|
||||
<value>${avm.remote.idlestream.timeout}</value>
|
||||
@@ -187,16 +194,19 @@
|
||||
<property name="avmService">
|
||||
<ref bean="AVMService"/>
|
||||
</property>
|
||||
<property name="authenticationService">
|
||||
<ref bean="AuthenticationService"/>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- The RMI wrapper around the AVM remote interface. -->
|
||||
|
||||
<bean id="avmRemoteService" class="org.springframework.remoting.rmi.RmiServiceExporter">
|
||||
<property name="service">
|
||||
<ref bean="avmRemote"/>
|
||||
<ref bean="avmRemoteTransport"/>
|
||||
</property>
|
||||
<property name="serviceInterface">
|
||||
<value>org.alfresco.repo.avm.AVMRemote</value>
|
||||
<value>org.alfresco.repo.avm.AVMRemoteTransport</value>
|
||||
</property>
|
||||
<property name="serviceName">
|
||||
<value>avm</value>
|
||||
@@ -206,12 +216,21 @@
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="avmRemoteSyncService" class="org.springframework.remoting.rmi.RmiServiceExporter">
|
||||
<property name="service">
|
||||
<bean id="avmSyncServiceTransport" class="org.alfresco.repo.avm.AVMSyncServiceTransportImpl">
|
||||
<property name="authenticationService">
|
||||
<ref bean="AuthenticationService"/>
|
||||
</property>
|
||||
<property name="avmSyncService">
|
||||
<ref bean="AVMSyncService"/>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="avmSyncServiceTransportRMI" class="org.springframework.remoting.rmi.RmiServiceExporter">
|
||||
<property name="service">
|
||||
<ref bean="avmSyncServiceTransport"/>
|
||||
</property>
|
||||
<property name="serviceInterface">
|
||||
<value>org.alfresco.service.cmr.avmsync.AVMSyncService</value>
|
||||
<value>org.alfresco.service.cmr.avmsync.AVMSyncServiceTransport</value>
|
||||
</property>
|
||||
<property name="serviceName">
|
||||
<value>avmsync</value>
|
||||
|
@@ -1099,14 +1099,14 @@
|
||||
</bean>
|
||||
|
||||
<bean id="AVMSyncService" class="org.springframework.aop.framework.ProxyFactoryBean">
|
||||
<property name="proxyInterfaces">
|
||||
<property name="proxyInterfaces">
|
||||
<value>org.alfresco.service.cmr.avmsync.AVMSyncService</value>
|
||||
</property>
|
||||
<property name="target">
|
||||
<ref bean="avmSyncService"/>
|
||||
<ref bean="avmSyncService"/>
|
||||
</property>
|
||||
<property name="interceptorNames">
|
||||
<list>
|
||||
<list>
|
||||
<idref local="AVMSyncService_transaction"/>
|
||||
<idref local="AVMSyncService_descriptor"/>
|
||||
</list>
|
||||
|
@@ -3,33 +3,54 @@
|
||||
"http://www.springframework.org/dtd/spring-beans.dtd">
|
||||
|
||||
<beans>
|
||||
<!-- Remote authentication service. -->
|
||||
<bean id="authenticationService" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
|
||||
<property name="serviceUrl">
|
||||
<value>rmi://localhost:1313/authentication</value>
|
||||
</property>
|
||||
<property name="serviceInterface">
|
||||
<value>org.alfresco.service.cmr.security.AuthenticationService</value>
|
||||
</property>
|
||||
<property name="refreshStubOnConnectFailure">
|
||||
<value>true</value>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- RMI Proxy bean for avmRemote -->
|
||||
|
||||
<bean id="avmRemote" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
|
||||
<!-- Remote interface for AVM. -->
|
||||
<bean id="avmRemote" class="org.alfresco.repo.avm.clt.AVMRemoteImpl">
|
||||
<property name="avmRemoteTransport">
|
||||
<ref bean="avmRemoteTransport"/>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- RMI Proxy bean for avmRemoteTransport -->
|
||||
<bean id="avmRemoteTransport" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
|
||||
<property name="serviceUrl">
|
||||
<value>rmi://localhost:1313/avm</value>
|
||||
</property>
|
||||
<property name="serviceInterface">
|
||||
<value>org.alfresco.repo.avm.AVMRemote</value>
|
||||
<value>org.alfresco.repo.avm.AVMRemoteTransport</value>
|
||||
</property>
|
||||
<property name="refreshStubOnConnectFailure">
|
||||
<value>true</value>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<!-- RMI Proxy bean for avmSync -->
|
||||
|
||||
<bean id="avmSync" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
|
||||
<property name="serviceUrl">
|
||||
<value>rmi://localhost:1313/avmsync</value>
|
||||
</property>
|
||||
<property name="serviceInterface">
|
||||
<value>org.alfresco.service.cmr.avmsync.AVMSyncService</value>
|
||||
</property>
|
||||
<property name="refreshStubOnConnectFailure">
|
||||
<value>true</value>
|
||||
<bean id="avmSyncService" class="org.alfresco.repo.avm.clt.AVMSyncServiceClient">
|
||||
<property name="avmSyncServiceTransport">
|
||||
<ref bean="avmSyncServiceTransport"/>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="avmSyncServiceTransport" class="org.springframework.remoting.rmi.RmiProxyFactoryBean">
|
||||
<property name="serviceUrl">
|
||||
<value>rmi://localhost:1313/avmsync</value>
|
||||
</property>
|
||||
<property name="serviceInterface">
|
||||
<value>org.alfresco.service.cmr.avmsync.AVMSyncServiceTransport</value>
|
||||
</property>
|
||||
<property name="refreshStubOnConnectFailure">
|
||||
<value>true</value>
|
||||
</property>
|
||||
</bean>
|
||||
</beans>
|
||||
|
Reference in New Issue
Block a user