if (sslInfo == null) {
throw new IOException(getFormatMessage(
"iiop.invalid_sslserverport",
new Object[] { iport }));
}
SSLServerSocketFactory ssf = sslInfo.getContext().getServerSocketFactory();
String[] ssl3TlsCiphers = sslInfo.getSsl3TlsCiphers();
String[] ssl2Ciphers = sslInfo.getSsl2Ciphers();
String[] ciphers = null;
if (ssl3TlsCiphers != null || ssl2Ciphers != null) {
String[] socketCiphers = ssf.getDefaultCipherSuites();
ciphers = mergeCiphers(socketCiphers, ssl3TlsCiphers, ssl2Ciphers);
}
String cs[] = null;
if(_logger.isLoggable(Level.FINE)) {
cs = ssf.getSupportedCipherSuites();
for(int i=0; i < cs.length; ++i) {
_logger.log(Level.FINE,"Cipher Suite: " + cs[i]);
}
}
ServerSocket ss = null;
try{
// bugfix for 6349541
// specify the ip address to bind to, 50 is the default used
// by the ssf implementation when only the port is specified
ss = ssf.createServerSocket(port, BACKLOG, inetSocketAddress.getAddress());
if (ciphers != null) {
((SSLServerSocket)ss).setEnabledCipherSuites(ciphers);
}
} catch(IOException e) {
_logger.log(Level.SEVERE, "iiop.createsocket_exception",