org.apache.ftpserver.ssl.impl
Class DefaultSslConfiguration

java.lang.Object
  extended by org.apache.ftpserver.ssl.impl.DefaultSslConfiguration
All Implemented Interfaces:
SslConfiguration

public class DefaultSslConfiguration
extends java.lang.Object
implements SslConfiguration

Internal class, do not use directly. Used to configure the SSL settings for the control channel or the data channel. Internal class, do not use directly.

Version:
$Rev: 711534 $, $Date: 2008-11-05 09:48:47 +0100 (Wed, 05 Nov 2008) $
Author:
The Apache MINA Project (dev@mina.apache.org)

Constructor Summary
DefaultSslConfiguration(javax.net.ssl.KeyManagerFactory keyManagerFactory, javax.net.ssl.TrustManagerFactory trustManagerFactory, ClientAuth clientAuthReqd, java.lang.String sslProtocol, java.lang.String[] enabledCipherSuites, java.lang.String keyAlias)
          Internal constructor, do not use directly.
 
Method Summary
 ClientAuth getClientAuth()
          Return the required client authentication setting
 java.lang.String[] getEnabledCipherSuites()
          Returns the cipher suites that should be enabled for this connection.
 javax.net.ssl.SSLContext getSSLContext()
          Return the SSL context for this configuration
 javax.net.ssl.SSLContext getSSLContext(java.lang.String protocol)
          Return the SSL context for this configuration given the specified protocol
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultSslConfiguration

public DefaultSslConfiguration(javax.net.ssl.KeyManagerFactory keyManagerFactory,
                               javax.net.ssl.TrustManagerFactory trustManagerFactory,
                               ClientAuth clientAuthReqd,
                               java.lang.String sslProtocol,
                               java.lang.String[] enabledCipherSuites,
                               java.lang.String keyAlias)
Internal constructor, do not use directly. Instead, use SslConfigurationFactory

Method Detail

getSSLContext

public javax.net.ssl.SSLContext getSSLContext(java.lang.String protocol)
                                       throws java.security.GeneralSecurityException
Description copied from interface: SslConfiguration
Return the SSL context for this configuration given the specified protocol

Specified by:
getSSLContext in interface SslConfiguration
Parameters:
protocol - The protocol, SSL or TLS must be supported
Returns:
The SSLContext
Throws:
java.security.GeneralSecurityException
See Also:
SslConfiguration.getSSLContext(String)

getClientAuth

public ClientAuth getClientAuth()
Description copied from interface: SslConfiguration
Return the required client authentication setting

Specified by:
getClientAuth in interface SslConfiguration
Returns:
ClientAuth.NEED if client authentication is required, ClientAuth.WANT is client authentication is wanted or ClientAuth.NONE if no client authentication is the be performed
See Also:
SslConfiguration.getClientAuth()

getSSLContext

public javax.net.ssl.SSLContext getSSLContext()
                                       throws java.security.GeneralSecurityException
Description copied from interface: SslConfiguration
Return the SSL context for this configuration

Specified by:
getSSLContext in interface SslConfiguration
Returns:
The SSLContext
Throws:
java.security.GeneralSecurityException
See Also:
SslConfiguration.getSSLContext()

getEnabledCipherSuites

public java.lang.String[] getEnabledCipherSuites()
Description copied from interface: SslConfiguration
Returns the cipher suites that should be enabled for this connection. Must return null if the default (as decided by the JVM) cipher suites should be used.

Specified by:
getEnabledCipherSuites in interface SslConfiguration
Returns:
An array of cipher suites, or null.
See Also:
SslConfiguration.getEnabledCipherSuites()


Copyright © 2003-2011 Apache Software Foundation. All Rights Reserved.