com.noelios.restlet.ext.ssl
Class PkixSslContextFactory

java.lang.Object
  extended by com.noelios.restlet.util.SslContextFactory
      extended by com.noelios.restlet.ext.ssl.PkixSslContextFactory

public class PkixSslContextFactory
extends SslContextFactory

This SslContextFactory uses PKIXSSLContextFactory from jSSLutils and can be configured via parameters.

Author:
Bruno Harbulot (Bruno.Harbulot@manchester.ac.uk)

Constructor Summary
PkixSslContextFactory()
           
 
Method Summary
protected  DefaultSslContextFactory clone()
          This class is likely to contain sensitive information; cloning is therefore not allowed.
 javax.net.ssl.SSLContext createSslContext()
          Creates a configured and initialised SSLContext by delegating the call to the PKIXSSLContextFactory with has been initialised using 'init'.
 void init(Series<Parameter> parameters)
          Sets the following options according to parameters that may have been set up directly in the HttpsServerHelper parameters.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PkixSslContextFactory

public PkixSslContextFactory()
Method Detail

createSslContext

public javax.net.ssl.SSLContext createSslContext()
                                          throws java.lang.Exception
Creates a configured and initialised SSLContext by delegating the call to the PKIXSSLContextFactory with has been initialised using 'init'.

Specified by:
createSslContext in class SslContextFactory
Throws:
java.lang.Exception
See Also:
DefaultSSLContextFactory.buildSSLContext()

init

public void init(Series<Parameter> parameters)
Sets the following options according to parameters that may have been set up directly in the HttpsServerHelper parameters.
Parameter name Value type Default value Description
keystorePath String javax.net.ssl.keyStore system property SSL keystore path.
keystorePassword String javax.net.ssl.keyStorePassword system property SSL keystore password.
keystoreType String javax.net.ssl.keyStoreType system property, otherwise default type SSL keystore type
keystoreProvider String javax.net.ssl.keyStoreProvider system property, otherwise default provider SSL keystore provider
keyPassword String SSL key password.
truststorePath String javax.net.ssl.trustStore system property SSL truststore path.
truststorePassword String javax.net.ssl.trustStorePassword system property SSL truststore password.
truststoreType String javax.net.ssl.trustStoreType system property, otherwise default type SSL truststore type
truststoreProvider String javax.net.ssl.trustStoreProvider system property, otherwise default provider SSL truststore provider
sslServerAlias String alias to use on the server side
sslProtocol String: TLS/SSLv3 TLS SSL protocol
disableCrl String (true/false) false Set to true if you want not to use the CRLs
crlUrl String (URL) URL of CRL to load (there can be multiple occurrences of this parameter).

Specified by:
init in class SslContextFactory
Parameters:
parameters - Typically, the parameters that would have been obtained from HttpsServerHelper.getParameters()

clone

protected final DefaultSslContextFactory clone()
                                        throws java.lang.CloneNotSupportedException
This class is likely to contain sensitive information; cloning is therefore not allowed.

Overrides:
clone in class java.lang.Object
Throws:
java.lang.CloneNotSupportedException


Copyright © 2005-2008 Noelios Technologies.