Override Clearspace SSLProtocolSocketFactory

We are using Openfire 3.6.4 with Jive SBS Employee 4.5.4. We deploy a 2-way SSL X.509 certificate authentication plugin on Jive. The problem now is getting Openfire to establish a 2-way SSL connection as a client to Jive in order to call the REST web services.

After looking at the code, I see that ClearspaceManager instantiates a custom SSLProtocolSocketFactory which only utilizes a TrustManager when registering a protocol for “https”. I would like to override/extend SSLProtocolSocketFactory, but that doesn’t seem possible unless I hack the Openfire code.

Would it work if I created an Openfire plugin which basically replaced the “https” protocol handler by overriding it with my own, e.g.,

Protocol easyhttps = new Protocol(“https”, (ProtocolSocketFactory) new SSLProtocolSocketFactory(this), 443);

Protocol.registerProtocol(“https”, easyhttps);

Protocol myHttps = new Protocol(“https”, (ProtocolSocketFactory) new MySSLProtocolSocketFactory(this), 443);

Protocol.registerProtocol(“https”, myHttps);


Mike Rohan