This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
Rob Spoor wrote:The example with SSLContext and SSLServerSocketFactory can be easily adapted to use a SSLSocketFactory instead of a SSLServerSocketFactory. Using that SSLSocketFactory you can then create (SSL) sockets.
I figured.. But the problem is that the code does not even compile.
For example: KeyStore keyStore = new KeyStore();
You cannot do because the constructor is protected. You need to do getInstance and I don't know what "type" to provide....
I am looking for some code that has been ran at least.