certificate_unknown

 常见问题 > 错误 > 异常 > certificate_unknown

如果您遇到类似这样的错误…

javax.jms.JMSException: start failed: Received fatal alert: certificate_unknown
       at org.activemq.transport.tcp.TcpTransportChannel.start(TcpTransportChannel.java:200)
       at org.activemq.broker.impl.BrokerConnectorImpl.addClient(BrokerConnectorImpl.java:308)
       at org.activemq.transport.TransportServerChannelSupport.addClient(TransportServerChannelSupp
       at org.activemq.transport.tcp.TcpTransportServerChannel.run(TcpTransportServerChannel.java:1
       at java.lang.Thread.run(Unknown Source)
Caused by: javax.net.ssl.SSLHandshakeException: Received fatal alert: certificate_unknown
       at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Unknown Source)
       at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Unknown Source)
       at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(Unknown Source)
       at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(Unknown Source)
       at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source)
       at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(Unknown Source)
       at com.sun.net.ssl.internal.ssl.AppInputStream.read(Unknown Source)
       at java.io.BufferedInputStream.fill(Unknown Source) 

当您尝试使用 SSL 连接到 ActiveMQ Classic 时,如果客户端不信任代理的证书,代理上就会显示“certificate_unknown”错误。在客户端上,我也会看到一个错误:“未找到可信证书”。

解决方法

确保您导出了代理的证书(如何使用 SSL 中的步骤 2),并将它导入到客户端的信任库中(步骤 4)。如果您已经完成了这些步骤,您在启动客户端 VM 时是否指定了 javax.net.ssl.trustStore 系统属性?

Apache、ActiveMQ、Apache ActiveMQ、Apache 羽毛标志和 Apache ActiveMQ 项目标志是 Apache 软件基金会的商标。版权所有 © 2024,Apache 软件基金会。根据 Apache 许可证 2.0 授权。