Forum Discussion
SSLException when use iControl java api to access old soap based f5 LB service
I used latest iControl java library (11.4) to access our LB data which has f5 soap based service. But met the following exception:
javax.net.ssl.SSLException: hostname in certificate didn't match: !=
at org.apache.axis.AxisFault.makeFault(AxisFault.java:101)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:154)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at iControl.SystemSystemInfoBindingStub.get_version(SystemSystemInfoBindingStub.java:1968)
I searched this issue in the community and found https://devcentral.f5.com/questions/handling-self-signed-certs-with-java-and-icontrol, so I switched to use axis1 v1.2 but didn't resolve the problem. Could anyone guide me how to fix it? And where can I find latest java api reference document? Thanks a lot!
5 Replies
- cricket_176901
Nimbostratus
Btw, I used JDK 1.7
Hmm, that's odd. The iControl library for Java includes the XTrustProvider code I wrote a long time ago to hook into the systems security settings to allow the issue when there is a hostname mismatch in the cert. I'll have to test out the latest build of the java libs to see if I can reproduce.
BTW, the latest build for the iControl Library for Java is 11.6 and can be downloaded from here: https://devcentral.f5.com/d/icontrol-library-for-java
- Micron_61407
Nimbostratus
I ran into the exact same issue after I updated to the latest version of the iControl JAR. I had to replace the axis.jar that was bundled with iControl with an older version of Axis (version 1.4 1855 April 22 2006) and that resolved the issue.
- sdkarthik1991_2
Nimbostratus
I am also having the same problem. I am getting the following exceptions -- faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException faultSubcode: faultString: java.net.UnknownHostException: Example faultActor: faultNode: faultDetail: {http://xml.apache.org/axis/}stackTrace:java.net.UnknownHostException: Example
Looks like it is assuming the client hostname as the remote F5 hos that it want to connect.
Can someone please help me?
- Are you using the latest iControl library for Java? This issue was addressed with the XTrustProvider code that's included in that client library. https://devcentral.f5.com/s/articles/iControl-Library-For-Java-With-Source
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
