Deploying Websphere on localhost via SOAP connector with SSL enabled
Hi folks,
I want to deploy my EAR into my local Websphere Application Server (I'm using the Ultimate Edition (incl. the Websphere Plugin) for this). Problem is that IntelliJ fails to establish a proper SSL encrypted connection with the SOAP connector of the server.
I tried injecting JVM properties (containing key/trust store) into IntelliJ's JVM, but this does not work either:
-Dis.secured=true
-Dtrust.store.path=C:\...\trust.p12
-Dtrust.store.password=WebAS
-Dkey.store.path=C:\...\key.p12
-Dkey.store.password=WebAS
Due to security restrictions I am not allowed to disable the security of my WAS.
I recognize this due to the following exception:
2016-12-24 15:10:43,192 [ 444916] WARN - erver.JavaeeServerInstanceImpl - com.ibm.websphere.management.exception.ConnectorException: ADMC0016E: The system cannot create a SOAP connector to connect to host localhost at port 8880. Root cause: [SOAPException: faultCode=SOAP-ENV:Client; msg=Error opening socket: javax.net.ssl.SSLException: SSLSocketFactory is null. This can occur if javax.net.ssl.SSLSocketFactory.getDefault() is called to create a socket and javax.net.ssl.* properties are not set.; targetException=java.lang.IllegalArgumentException: Error opening socket: javax.net.ssl.SSLException: SSLSocketFactory is null. This can occur if javax.net.ssl.SSLSocketFactory.getDefault() is called to create a socket and javax.net.ssl.* properties are not set.]
com.ibm.websphere.management.exception.ConnectorException: ADMC0016E: The system cannot create a SOAP connector to connect to host localhost at port 8880. Root cause: [SOAPException: faultCode=SOAP-ENV:Client; msg=Error opening socket: javax.net.ssl.SSLException: SSLSocketFactory is null. This can occur if javax.net.ssl.SSLSocketFactory.getDefault() is called to create a socket and javax.net.ssl.* properties are not set.; targetException=java.lang.IllegalArgumentException: Error opening socket: javax.net.ssl.SSLException: SSLSocketFactory is null. This can occur if javax.net.ssl.SSLSocketFactory.getDefault() is called to create a socket and javax.net.ssl.* properties are not set.]
at com.intellij.j2ee.webSphere.client.WebSphereClientFactoryImpl.createAdminClient(WebSphereClientFactoryImpl.java:62)
at com.intellij.j2ee.webSphere.agent.WebSphereAgent.createClient(WebSphereAgent.java:86)
at com.intellij.j2ee.webSphere.agent.WebSphereAgent.connect(WebSphereAgent.java:58)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
at java.lang.reflect.Method.invoke(Method.java:611)
at com.intellij.javaee.process.common.MethodInvocator.invoke(MethodInvocator.java:45)
at com.intellij.javaee.oss.process.JavaeeProcess.processRequest(JavaeeProcess.java:116)
at com.intellij.javaee.oss.process.JavaeeProcess.run(JavaeeProcess.java:56)
at com.intellij.javaee.oss.process.JavaeeProcess.main(JavaeeProcess.java:35)
Caused by: com.ibm.websphere.management.exception.ConnectorException: ADMC0016E: The system cannot create a SOAP connector to connect to host localhost at port 8880.
at com.ibm.websphere.management.AdminClientFactory.createAdminClientPrivileged(AdminClientFactory.java:635)
at com.ibm.websphere.management.AdminClientFactory.access$000(AdminClientFactory.java:127)
at com.ibm.websphere.management.AdminClientFactory$1.run(AdminClientFactory.java:210)
at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:63)
at com.ibm.websphere.management.AdminClientFactory.createAdminClient(AdminClientFactory.java:206)
at com.intellij.j2ee.webSphere.client.WebSphereClientFactoryImpl.createAdminClient(WebSphereClientFactoryImpl.java:58)
... 10 more
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:56)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:39)
at java.lang.reflect.Constructor.newInstance(Constructor.java:527)
at com.ibm.websphere.management.AdminClientFactory.createAdminClientPrivileged(AdminClientFactory.java:457)
... 15 more
Caused by: com.ibm.websphere.management.exception.ConnectorNotAvailableException: [SOAPException: faultCode=SOAP-ENV:Client; msg=Error opening socket: javax.net.ssl.SSLException: SSLSocketFactory is null. This can occur if javax.net.ssl.SSLSocketFactory.getDefault() is called to create a socket and javax.net.ssl.* properties are not set.; targetException=java.lang.IllegalArgumentException: Error opening socket: javax.net.ssl.SSLException: SSLSocketFactory is null. This can occur if javax.net.ssl.SSLSocketFactory.getDefault() is called to create a socket and javax.net.ssl.* properties are not set.]
at com.ibm.ws.management.connector.soap.SOAPConnectorClient.reconnect(SOAPConnectorClient.java:429)
at com.ibm.ws.management.connector.soap.SOAPConnectorClient.<init>(SOAPConnectorClient.java:228)
... 20 more
Caused by: [SOAPException: faultCode=SOAP-ENV:Client; msg=Error opening socket: javax.net.ssl.SSLException: SSLSocketFactory is null. This can occur if javax.net.ssl.SSLSocketFactory.getDefault() is called to create a socket and javax.net.ssl.* properties are not set.; targetException=java.lang.IllegalArgumentException: Error opening socket: javax.net.ssl.SSLException: SSLSocketFactory is null. This can occur if javax.net.ssl.SSLSocketFactory.getDefault() is called to create a socket and javax.net.ssl.* properties are not set.]
at org.apache.soap.transport.http.SOAPHTTPConnection.send(SOAPHTTPConnection.java:475)
at org.apache.soap.rpc.Call.WASinvoke(Call.java:510)
at com.ibm.ws.management.connector.soap.SOAPConnectorClient$4.run(SOAPConnectorClient.java:387)
at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:118)
at com.ibm.ws.management.connector.soap.SOAPConnectorClient.reconnect(SOAPConnectorClient.java:372)
... 21 more
Please sign in to leave a comment.
See https://youtrack.jetbrains.com/issue/IDEA-126156#comment=27-760045.