SSLUnitTestCase failures with the IBM JVM
mwringe Aug 28, 2006 9:07 PMHi,
I opened a bug about the test failures for the org.jboss.test.web.test.ssl.SSLUnitTestCase failures when an IBM JVM is used(JBAS-3570), but looking into it more, I am wondering that the failures may be more of a configuration issue.
Initially, all org.jboss.test.web.test.ssl.SSLUnitTestCase test fail, giving a Connection Refused error:
java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:336)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:201)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:188)
Looking at the logs, this is failing due to the server trying to use the SunX509 algorithm. The IBM JVM uses the Ibmx509 algorithm instead.
The algorithm can be changed in the server.xml of the jbossweb-tomcat55.sar, but then the server gives the following errors:
Testcase: testHttps took 0.017 sec
Caused an ERROR
protocol version
javax.net.ssl.SSLHandshakeException: protocol version
at com.ibm.jsse.bv.a(Unknown Source)
at com.ibm.jsse.b.a(Unknown Source)
at com.ibm.jsse.b.write(Unknown Source)
at org.apache.commons.httpclient.HttpConnection$WrappedOutputStream.write(HttpConnection.java:1360)
at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:86)
at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:144)
at org.apache.commons.httpclient.HttpConnection.flushRequestOutputStream(HttpConnection.java:790)
at org.apache.commons.httpclient.HttpMethodBase.writeRequest(HttpMethodBase.java:2271)
at org.apache.commons.httpclient.HttpMethodBase.processRequest(HttpMethodBase.java:2651)
at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1087)
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:643)
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:497)
at org.jboss.test.web.test.ssl.SSLUnitTestCase.doHttps(SSLUnitTestCase.java:117)
at org.jboss.test.web.test.ssl.SSLUnitTestCase.testHttps(SSLUnitTestCase.java:77)
at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22)
at junit.extensions.TestSetup$1.protect(TestSetup.java:19)
at junit.extensions.TestSetup.run(TestSetup.java:23)
Any ideas on how to get these tests to pass with the IBM JVM?