eu.emi.client.security
Interface IAuthenticationConfiguration

All Superinterfaces:
Cloneable, ISecurityConfiguration
All Known Subinterfaces:
IClientProperties, ISecurityProperties
All Known Implementing Classes:
AbstractSecurityConfigurationImpl, ClientSecurityProperties

public interface IAuthenticationConfiguration
extends ISecurityConfiguration

Implementation of this interface provides data necessary for setting up transport level security and HTTP authentication. SSL can be set up in two ways: either by providing ready to use SSLContext or by providing all the keystore and truststore details which are needed to create a new SSLContext.

Author:
K. Benedyczak

Method Summary
 IAuthenticationConfiguration clone()
          Cloning support is mandatory
 boolean doHttpAuthn()
          Returns true if HTTP BASIC Auth should be used.
 boolean doSSLAuthn()
          Returns true if the client-side TLS authentication should be done.
 String getHttpPassword()
          Returns HTTP BASIC Auth user's password.
 String getHttpUser()
          Returns HTTP BASIC Auth user.
 SSLContext getSSLContext()
          This method can return initialized SSLContext or null.
 String getTruststore()
          Returns truststore location.
 String getTruststorePassword()
          Returns truststore password.
 String getTruststoreType()
          Returns truststore type.
 
Methods inherited from interface eu.emi.client.security.ISecurityConfiguration
getKeystore, getKeystoreAlias, getKeystoreKeyPassword, getKeystorePassword, getKeystoreType
 

Method Detail

getSSLContext

SSLContext getSSLContext()
This method can return initialized SSLContext or null. If null is returned then SSLContext will be created by this library itself using the data from the other methods defined in this interface. If this method returns non-null value then most of the methods in this interface are not used (only HTTP related are still used).

Returns:
initialized SSL context.

doSSLAuthn

boolean doSSLAuthn()
Returns true if the client-side TLS authentication should be done. If false then all (inherited from the super interface ISecurityConfiguration) getKeystore* methods are not used at all.

Returns:

getTruststore

String getTruststore()
Returns truststore location. If this method returns null then (for SSL connections) client will trust ANY server certificate.

Returns:

getTruststorePassword

String getTruststorePassword()
Returns truststore password.

Returns:

getTruststoreType

String getTruststoreType()
Returns truststore type.

Returns:

doHttpAuthn

boolean doHttpAuthn()
Returns true if HTTP BASIC Auth should be used.

Returns:

getHttpUser

String getHttpUser()
Returns HTTP BASIC Auth user. Required if doHttpAuthn is true.

Returns:

getHttpPassword

String getHttpPassword()
Returns HTTP BASIC Auth user's password. Required if doHttpAuthn is true.

Returns:

clone

IAuthenticationConfiguration clone()
Cloning support is mandatory

Specified by:
clone in interface ISecurityConfiguration


Copyright © 2012 EMI. All Rights Reserved.