if (sslPolicy != null) {
listener = new SslListener(new InetAddrPort(port));
SslListener secureListener = (SslListener)listener;
JettySslListenerConfigurer secureListenerConfigurer =
new JettySslListenerConfigurer(config, sslPolicy, secureListener);
secureListenerConfigurer.configure();
} else {
listener = new SocketListener(new InetAddrPort(port));
}