0
我正在開發一個使用入站https端點的mule中的休息web服務。我已經使用tls-key-store和tls-server配置了https連接器(使用keytool生成了相同的連接器)。mule https入站端點
下面是配置文件:
<https:connector name="httpsConnector" doc:name="HTTP\HTTPS" validateConnections="true">
<https:tls-key-store path="keystore.jks" keyPassword="welcome" storePassword="welcome"/>
<https:tls-server path="truststore.jks" storePassword="welcome"/>
</https:connector>
<flow name="RESTFlow1" doc:name="RESTFlow1">
<https:inbound-endpoint exchange-pattern="request-response" host="0.0.0.0" port="8082" connector-ref="httpsConnector" doc:name="HTTPS"/>
<jersey:resources doc:name="REST">
<component class="com.thinxtream.rest.restWebservices"/>
</jersey:resources>
</flow>
客戶端是連接到這個騾子休息web服務,它讓下面的錯誤Flex應用程序:
httpsConnector.receiver.02] org.mule.exception.DefaultSystemExceptionStrategy: Caught exception in Exception Strategy: Received fatal alert: bad_certificate
javax.net.ssl.SSLHandshakeException: Received fatal alert: bad_certificate
at sun.security.ssl.Alerts.getSSLException(Unknown Source)
at sun.security.ssl.Alerts.getSSLException(Unknown Source)
at sun.security.ssl.SSLSocketImpl.recvAlert(Unknown Source)
at sun.security.ssl.SSLSocketImpl.readRecord(Unknown Source)
at sun.security.ssl.SSLSocketImpl.readDataRecord(Unknown Source)
at sun.security.ssl.AppInputStream.read(Unknown Source)
at sun.security.ssl.AppInputStream.read(Unknown Source)
at org.apache.commons.httpclient.HttpParser.readRawLine(HttpParser.java:78)
at org.apache.commons.httpclient.HttpParser.readLine(HttpParser.java:106)
at org.mule.transport.http.HttpServerConnection.readLine(HttpServerConnection.java:219)
at org.mule.transport.http.HttpServerConnection.readRequest(HttpServerConnection.java:185)
at org.mule.transport.http.HttpMessageReceiver$HttpWorker.run(HttpMessageReceiver.java:155)
at org.mule.work.WorkerContext.run(WorkerContext.java:311)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
它在任何配置flex應用程序也是?
是的,服務器端證書是自簽名的。我想我需要將服務器證書導入Flash Builder。 – user1787772
它的工作原理是,我在https連接器中刪除了tls-server路徑,並且只使用了tls-keystore.Since它是一個flex web應用程序,向瀏覽器添加證書,可以訪問web服務。 – user1787772