commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Simon Roberts <>
Subject Re: [httpclient] Volunteering to make SSL socket factory more flexible
Date Wed, 03 Jul 2002 02:08:49 GMT
> At the moment the SSL socket is created with a call to
> SSLSocketFactory.getDefault().createSocket(host,port) in HttpConnection.
> Unfortunately this is not flexible enough when you want to use
> implementations different from Sun's JSSE (which is subject to export
> restrictions and does not allow instatiation of other implementations
> with the getDefault() method). As our company uses SSLava
> ( we need a solution that allows to specify the
> SSLSocketFactory to use.
> We would like to make the following changes:
> - HttpConnection: add setSSLSocketFactory(SSLSocketFactory)
> An SSL connection will use the specified factory or the
> SSLFactory.getDefault() otherwise. The factory must be set before open()
> is called.
> - HttpClient: add setSSLSocketFactory(SSLSocketFactory)
> Acts as a facade to the underlying HttpConnection. The factory must be
> set before startSession(...) is called.
> These changes are compatible with existing applications.
> Please let us know if you would like to incorporate the changes. We will
> provide the patches within a couple of days.

Yup!  I've done my own fugly patch to achieve that, but your solution looks

I would request that you also apply the change to HttpMultiClient and
HttpConnectionManager, so that it stores the socket factory, then applies
the setSSLSocketFactory to HttpConnections as they are created - see

Unless you were talking about statics?

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message