org.apache.qpid.server.security.auth.sasl
Class UsernamePasswordInitialiser

java.lang.Object
  extended by org.apache.qpid.server.security.auth.sasl.UsernamePasswordInitialiser
All Implemented Interfaces:
AuthenticationProviderInitialiser
Direct Known Subclasses:
AmqPlainInitialiser, AnonymousInitialiser, CRAMMD5HashedInitialiser, CRAMMD5HexInitialiser, CRAMMD5Initialiser, PlainInitialiser

public abstract class UsernamePasswordInitialiser
extends Object
implements AuthenticationProviderInitialiser


Field Summary
protected static org.apache.log4j.Logger _logger
           
 
Constructor Summary
UsernamePasswordInitialiser()
           
 
Method Summary
 CallbackHandler getCallbackHandler()
           
 Map<String,?> getProperties()
          Get the properties that must be passed in to the Sasl.createSaslServer method.
 void initialise(PrincipalDatabase db)
          Initialise the authentication provider.
 void initialise(String baseConfigPath, Configuration configuration, Map<String,PrincipalDatabase> principalDatabases)
          Initialise the authentication provider.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.qpid.server.security.auth.sasl.AuthenticationProviderInitialiser
getMechanismName, getServerFactoryClassForJCARegistration
 

Field Detail

_logger

protected static final org.apache.log4j.Logger _logger
Constructor Detail

UsernamePasswordInitialiser

public UsernamePasswordInitialiser()
Method Detail

initialise

public void initialise(String baseConfigPath,
                       Configuration configuration,
                       Map<String,PrincipalDatabase> principalDatabases)
                throws Exception
Description copied from interface: AuthenticationProviderInitialiser
Initialise the authentication provider.

Specified by:
initialise in interface AuthenticationProviderInitialiser
Parameters:
baseConfigPath - the path in the config file that points to any config options for this provider. Each provider can have its own set of configuration options
configuration - the Apache Commons Configuration instance used to configure this provider
principalDatabases - the set of principal databases that are available
Throws:
Exception - needs refined Exception is too broad.

initialise

public void initialise(PrincipalDatabase db)
Description copied from interface: AuthenticationProviderInitialiser
Initialise the authentication provider.

Specified by:
initialise in interface AuthenticationProviderInitialiser
Parameters:
db - The principal database to initialise with

getCallbackHandler

public CallbackHandler getCallbackHandler()
Specified by:
getCallbackHandler in interface AuthenticationProviderInitialiser
Returns:
the callback handler that should be used to process authentication requests for this mechanism. This will be called after initialise and will be stored by the authentication manager. The callback handler must be fully threadsafe.

getProperties

public Map<String,?> getProperties()
Description copied from interface: AuthenticationProviderInitialiser
Get the properties that must be passed in to the Sasl.createSaslServer method.

Specified by:
getProperties in interface AuthenticationProviderInitialiser
Returns:
the properties, which may be null


Licensed to the Apache Software Foundation