Code example for SSLServerSocketFactory

Methods: createServerSocket

0
			int port = Integer.parseInt(p);
			 
			SSLServerSocketFactory sslserversocketfactory =
                (SSLServerSocketFactory) SSLServerSocketFactory.getDefault();
			 sslserversocket =
                (SSLServerSocket) sslserversocketfactory.createServerSocket(port);
			final String[] enabledCipherSuites = { "SSL_DH_anon_WITH_RC4_128_MD5" };
			sslserversocket.setEnabledCipherSuites(enabledCipherSuites);
 
			 
		} catch (IOException e) {
			e.printStackTrace();
			throw new OpenAS2Exception(e);
		} catch (NumberFormatException e) {
			e.printStackTrace();
			throw new OpenAS2Exception("error converting portid parameter " + e);
		} 
		userid = (String) parameters.get("userid");
		if (userid == null || userid.length() < 1)
			throw new OpenAS2Exception("missing userid parameter");