Java 在Websphere App Server和Websphere MQ之间配置SSL
我尝试从WebSphereAppServer上启动的简单web服务连接到WMQ 在WMQ上,我有带SSL的通道。我现在使用自签名证书 对于glassfish,我只需将此证书添加到域中的密钥存储中,所有证书都可以正常工作(因为我配置了MQQueueConnectionFactory) 但在WebSphere上,此技巧不起作用:Java 在Websphere App Server和Websphere MQ之间配置SSL,java,spring,ssl,websphere,ibm-mq,Java,Spring,Ssl,Websphere,Ibm Mq,我尝试从WebSphereAppServer上启动的简单web服务连接到WMQ 在WMQ上,我有带SSL的通道。我现在使用自签名证书 对于glassfish,我只需将此证书添加到域中的密钥存储中,所有证书都可以正常工作(因为我配置了MQQueueConnectionFactory) 但在WebSphere上,此技巧不起作用: [5/13/13 14:00:25:058 FET] 00000060 SystemOut O %% Invalidated: [Session-94, SSL_
[5/13/13 14:00:25:058 FET] 00000060 SystemOut O %% Invalidated: [Session-94, SSL_RSA_EXPORT_WITH_RC4_40_MD5]
[5/13/13 14:00:25:058 FET] 00000060 SystemOut O jmsContainer-1, SEND SSLv3 ALERT: fatal, description = certificate_unknown
[5/13/13 14:00:25:058 FET] 00000060 SystemOut O jmsContainer-1, WRITE: SSLv3 Alert, length = 2
[5/13/13 14:00:25:058 FET] 00000060 SystemOut O [Raw write]: length = 7
[5/13/13 14:00:25:058 FET] 00000060 SystemOut O 0000: 15 03 00 00 02 02 2e .......
[5/13/13 14:00:25:058 FET] 00000060 SystemOut O jmsContainer-1, called closeSocket()
[5/13/13 14:00:25:058 FET] 00000060 SystemOut O jmsContainer-1, handling exception: javax.net.ssl.SSLHandshakeException: com.ibm.jsse2.util.j: PKIX path building failed: java.security.cert.CertPathBuilderException: unable to find valid certification path to requested target
[5/13/13 14:00:25:058 FET] 00000060 DefaultMessag E org.springframework.jms.listener.DefaultMessageListenerContainer refreshConnectionUntilSuccessful Could not refresh JMS Connection for destination 'fromESB' - retrying in 5000 ms. Cause: JMSWMQ0018: Failed to connect to queue manager 'qm1' with connection mode 'Client' and host name '192.168.56.101(1414)'.; nested exception is com.ibm.mq.MQException: JMSCMQ0001: WebSphere MQ call failed with compcode '2' ('MQCC_FAILED') reason '2397' ('MQRC_JSSE_ERROR').
如何配置WebSphere app server以使用ssl(如何将服务器(WMQ)证书添加到信任存储?或者信任存储在哪里?确定。我自己解决这个问题 配置WMQ:
<bean id="mqConnectionFactory" class="com.ibm.mq.jms.MQQueueConnectionFactory">
<property name="hostName" value="${queue_hostname}"/>
<property name="port" value="${queue_port}"/>
<property name="queueManager" value="${queue_manager}"/>
<property name="transportType" value="1"/>
<property name="SSLCipherSuite" value="SSL_RSA_EXPORT_WITH_RC4_40_MD5"/>
<property name="channel" value="ssl_channel"/>
</bean>
<bean id="mqConnectionFactory" class="com.ibm.mq.jms.MQQueueConnectionFactory">
<property name="hostName" value="${queue_hostname}"/>
<property name="port" value="${queue_port}"/>
<property name="queueManager" value="${queue_manager}"/>
<property name="transportType" value="1"/>
<property name="SSLCipherSuite" value="SSL_RSA_EXPORT_WITH_RC4_40_MD5"/>
<property name="channel" value="ssl_channel"/>
</bean>
将SSL设置为打开状态