|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.ftpserver.ssl.DefaultSslConfiguration
public class DefaultSslConfiguration
Used to configure the SSL settings for the control channel or the data channel.
Constructor Summary | |
---|---|
DefaultSslConfiguration()
|
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. |
java.lang.String |
getKeyAlias()
Get the server key alias to be used for SSL communication |
java.lang.String |
getKeyPassword()
The password used to load the key |
java.lang.String |
getKeystoreAlgorithm()
The algorithm used to open the key store. |
java.io.File |
getKeystoreFile()
The key store file used by this configuration |
java.lang.String |
getKeystorePassword()
The password used to load the key store |
java.lang.String |
getKeystoreType()
The key store type, defaults to @see KeyStore.getDefaultType() |
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 |
java.lang.String |
getSslProtocol()
The SSL protocol used for this channel. |
java.lang.String |
getTruststoreAlgorithm()
The algorithm used to open the trust store. |
java.io.File |
getTruststoreFile()
|
java.lang.String |
getTruststorePassword()
The password used to load the trust store |
java.lang.String |
getTruststoreType()
The trust store type, defaults to @see KeyStore.getDefaultType() |
void |
init()
Configure secure server related properties. |
void |
setClientAuthentication(java.lang.String clientAuthReqd)
Set what client authentication level to use, supported values are "yes" or "true" for required authentication, "want" for wanted authentication and "false" or "none" for no authentication. |
void |
setEnabledCipherSuites(java.lang.String[] enabledCipherSuites)
Set the allowed cipher suites, note that the exact list of supported cipher suites differs between JRE implementations. |
void |
setKeyAlias(java.lang.String keyAlias)
Set the alias for the key to be used for SSL communication. |
void |
setKeyPassword(java.lang.String keyPass)
Set the password used to load the key |
void |
setKeystoreAlgorithm(java.lang.String keystoreAlgorithm)
Override the key store algorithm used to open the key store |
void |
setKeystoreFile(java.io.File keyStoreFile)
Set the key store file to be used by this configuration |
void |
setKeystorePassword(java.lang.String keystorePass)
Set the password used to load the key store |
void |
setKeystoreType(java.lang.String keystoreType)
Set the key store type |
void |
setSslProtocol(java.lang.String sslProtocol)
Set the SSL protocol used for this channel. |
void |
setTruststoreAlgorithm(java.lang.String trustStoreAlgorithm)
Override the trust store algorithm used to open the trust store |
void |
setTruststoreFile(java.io.File trustStoreFile)
Set the password used to load the trust store |
void |
setTruststorePassword(java.lang.String trustStorePass)
Set the password used to load the trust store |
void |
setTruststoreType(java.lang.String trustStoreType)
Set the trust store type |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefaultSslConfiguration()
Method Detail |
---|
public java.io.File getKeystoreFile()
public void setKeystoreFile(java.io.File keyStoreFile)
keyStoreFile
- A path to an existing key store filepublic java.lang.String getKeystorePassword()
public void setKeystorePassword(java.lang.String keystorePass)
keystorePass
- The passwordpublic java.lang.String getKeystoreType()
KeyStore.getDefaultType()
public void setKeystoreType(java.lang.String keystoreType)
keystoreType
- The key store typepublic java.lang.String getKeystoreAlgorithm()
public void setKeystoreAlgorithm(java.lang.String keystoreAlgorithm)
keystoreAlgorithm
- The key store algorithmpublic java.lang.String getSslProtocol()
public void setSslProtocol(java.lang.String sslProtocol)
sslProtocol
- The SSL protocolpublic void setClientAuthentication(java.lang.String clientAuthReqd)
clientAuthReqd
- The desired authentication levelpublic java.lang.String getKeyPassword()
public void setKeyPassword(java.lang.String keyPass)
keyPass
- The passwordpublic java.io.File getTruststoreFile()
public void setTruststoreFile(java.io.File trustStoreFile)
trustStoreFile
- The passwordpublic java.lang.String getTruststorePassword()
public void setTruststorePassword(java.lang.String trustStorePass)
trustStorePass
- The passwordpublic java.lang.String getTruststoreType()
KeyStore.getDefaultType()
public void setTruststoreType(java.lang.String trustStoreType)
keystoreType
- The trust store typepublic java.lang.String getTruststoreAlgorithm()
public void setTruststoreAlgorithm(java.lang.String trustStoreAlgorithm)
trustStoreAlgorithm
- The trust store algorithmpublic void init()
public javax.net.ssl.SSLContext getSSLContext(java.lang.String protocol) throws java.security.GeneralSecurityException
SslConfiguration
getSSLContext
in interface SslConfiguration
protocol
- The protocol, SSL or TLS must be supported
SSLContext
java.security.GeneralSecurityException
SslConfiguration.getSSLContext(String)
public ClientAuth getClientAuth()
SslConfiguration
getClientAuth
in interface SslConfiguration
ClientAuth.NEED
if client authentication is required,
ClientAuth.WANT
is client authentication is wanted or
ClientAuth.NONE
if no client authentication is the be performedSslConfiguration.getClientAuth()
public javax.net.ssl.SSLContext getSSLContext() throws java.security.GeneralSecurityException
SslConfiguration
getSSLContext
in interface SslConfiguration
SSLContext
java.security.GeneralSecurityException
SslConfiguration.getSSLContext()
public java.lang.String[] getEnabledCipherSuites()
SslConfiguration
getEnabledCipherSuites
in interface SslConfiguration
SslConfiguration.getEnabledCipherSuites()
public void setEnabledCipherSuites(java.lang.String[] enabledCipherSuites)
enabledCipherSuites
- public java.lang.String getKeyAlias()
public void setKeyAlias(java.lang.String keyAlias)
keyAlias
- The alias to use, or null if JSSE should
be allowed to choose the key.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |