cancel
Showing results for 
Search instead for 
Did you mean: 

FSR error: SHA MessageDigest

junderwood
Champ in-the-making
Champ in-the-making
I couldn't find anythign on this error so far.

Running on AIX 5.3

I get the following error when starting deploy_start.sh

Feb 4, 2009 2:48:42 PM org.springframework.remoting.rmi.RmiServiceExporter getRegistry
INFO: Looking for RMI registry at port '44100'
Feb 4, 2009 2:48:42 PM org.springframework.remoting.rmi.RmiServiceExporter getRegistry
WARNING: Could not detect RMI registry - creating new one
Feb 4, 2009 2:48:42 PM org.springframework.beans.factory.support.DefaultSingletonBeanRegistry destroySingletons
INFO: Destroying singletons in {org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [sampleRunnable,sampleProgramRunnable,prop
erties,configuration,deploymentReceiverService,deploymentReceiverTransport,deploymentReceiverTransportRMI]; root of BeanFactory hierarchy}
Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'deploymentReceiverTransportRMI' defined in
file [/apps/alfresco/deploy/application-context.xml]: Invocation of init method failed; nested exception is java.lang.SecurityException: SHA MessageDigest not
available
Caused by: java.lang.SecurityException: SHA MessageDigest not available



Has anyone seen this?
5 REPLIES 5

mrogers
Star Contributor
Star Contributor
Some questions.
1) Which version of FSR are you using ?
2) Are you using any encryption for your FSR?    (Especially have you configured anything using the SHA algorithm.)
3) Are you using an IBM JVM and if so which one?
4) Have you added any additional libraries to your FSR's classpath?

junderwood
Champ in-the-making
Champ in-the-making
Thanks for the reply here are the answers ….

1) Which version of FSR are you using ? alfresco-labs-deployment-3a.1032
2) Are you using any encryption for your FSR? (Especially have you configured anything using the SHA algorithm.)  I have no idea, I just ran it as is.  I didn't configure anything special to use it.  at the bottom of this thread is my application-context.xml
3) Are you using an IBM JVM and if so which one?
java version "1.5.0"
Java(TM) 2 Runtime Environment, Standard Edition (build pap32devifx-20070725 (SR5a))
IBM J9 VM (build 2.3, J2RE 1.5.0 IBM J9 2.3 AIX ppc-32 j9vmap3223-20070426 (JIT enabled)
J9VM - 20070420_12448_bHdSMR
JIT  - 20070419_1806_r8
GC   - 200704_19)
JCL  - 20070725


4) Have you added any additional libraries to your FSR's classpath? No just the standard ones it comes with.

Thanks again for looking at this.

application-context.xml
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'http://www.springframework.org/dtd/spring-beans.dtd'>

<beans>
     <!– Sample FSDeploymentRunnable implementation - add others here –>
     <bean id="sampleRunnable" class="org.alfresco.deployment.SampleRunnable"/>
    
     <bean id="sampleProgramRunnable" class="org.alfresco.deployment.ProgramRunnable">
         <property name="program"><value>/bin/cp</value></property>
         <!– Arguments that get appended to the final command line –>
         <property name="arguments">
             <list>
                 <value>/Users/britt/dump.txt</value>
             </list>
         </property>
         <!– The directory that the program runs in. –>
         <property name="directory"><value>/</value></property>
     </bean>
 
     <bean id="properties"
          class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
        <property name="ignoreUnresolvablePlaceholders">
            <value>true</value>
        </property>
        <property name="locations">
            <list>
                <value>classpath:deployment.properties</value>
            </list>
        </property>
    </bean>   
   
    <bean id="configuration" class="org.alfresco.deployment.config.Configuration"
          init-method="init">
        <property name="dataDirectory">
            <value>${dep.datadir}</value>
        </property>
        <property name="logDirectory">
            <value>${dep.logdir}</value>
        </property>
        <property name="metaDataDirectory">
            <value>${dep.metadatadir}</value>
        </property>
        <!– Target Configuration. Modify for your site. –>
        <property name="targetData">
            <map>
               <entry key="mktContent">
                   <map>
                     <entry key="root"><value>/apps/alfresco/deploy/mktContentStage</value></entry>
                     <entry key="user"><value>admin</value></entry>
                     <entry key="password"><value>admin</value></entry>
                   </map>
               </entry>
            </map>
        </property>
    </bean>
   
    <bean id="deploymentReceiverService" class="org.alfresco.deployment.impl.server.DeploymentReceiverServiceImpl"
          init-method="init">
        <property name="configuration">
            <ref bean="configuration"/>
        </property>
    </bean>
   
    <bean id="deploymentReceiverTransport" class="org.alfresco.deployment.impl.server.DeploymentReceiverTransportImpl">
           <property name="deploymentReceiverService">
               <ref bean="deploymentReceiverService"/>
           </property>
    </bean>
   
       <bean id="deploymentReceiverTransportRMI" class="org.springframework.remoting.rmi.RmiServiceExporter">
              <property name="service">
                     <ref bean="deploymentReceiverTransport"/>
              </property>
              <property name="serviceInterface">
                     <value>org.alfresco.deployment.DeploymentReceiverTransport</value>
              </property>
              <property name="serviceName">
                     <value>deployment</value>
              </property>
              <property name="registryPort">
                     <value>${dep.rmi.port}</value>
              </property>
       </bean>
</beans>


mrogers
Star Contributor
Star Contributor
An internet search shows lots of different products are having similar problem with IBM's JVMs.

One thread (http://www.applettalk.com/sha-message-digest-algo-not-supported-by-ibm-jdk-vt89524.html) suggests adding the "bouncy castle" JCE provider JAR. http://www.bouncycastle.org/java.html

You would need to add this Jar to the FSR's classpath.

junderwood
Champ in-the-making
Champ in-the-making
Thanks, I saw that , I just never heard of bouncy castle and was hoping it was an easy fix.

Thanks for your time.

pumpernickel
Champ in-the-making
Champ in-the-making
To complete the posts, here's the solution step by step:

1. Copy Bouncy Castle (bcprov-jdk15-143.jar) into your JavaHome/jre/lib/ext/

2. edit java.security in JavaHome/jre/lib/secutrity/
#
# List of providers and their preference orders (see above):
#
security.provider.1=com.ibm.jsse2.IBMJSSEProvider2
security.provider.2=com.ibm.crypto.provider.IBMJCE
security.provider.3=com.ibm.security.jgss.IBMJGSSProvider
security.provider.4=com.ibm.security.cert.IBMCertPath
security.provider.5=com.ibm.security.sasl.IBMSASL
security.provider.6=org.bouncycastle.jce.provider.BouncyCastleProvider

3. modify deploy_start.sh
nohup java -server -cp alfresco-core.jar:alfresco-deployment.jar:commons-logging-1.1.jar:jug-lgpl-2.0.0.jar:log4j-1.2.15.jar:spring-2.0.6.jar:. org.alfresco.deployment.Main application-context.xml
(Somehow there is a class loader problem that fails loading the property file or jars, so you have to replace the -Dext.java.dirs mechanism with -cp …)

Thomas