The EPI:AM enables the development for custom authentication method plug-ins. The following UML diagram shows the classes that is used in the development of custom authentication methods:
All authentication method plug-ins must implement the AuthenticationMechanismInterface
.
This interface contains four methods:
init()
- Initializes the authentication method plug-in to prepare it for accepting authentication requests. The method takes anAuthenticationMechanismConfiguration
and anAuthenticationMechanismHandler
instance which contain information that can be used to perform the initialization. This method is called when the Policy Service is started and when a new configuration is published.authenticate()
- Executes the authentication request. This method takes anAuthenticationRequest
instance and returns anAuthenticationReply
instance.getName()
- Returns the name of the authentication method. This is the name that will be shown in the Administration Interface.exit()
- Performs cleanup tasks, such as deallocating resources. This method is called when the Policy Service is closed down and when a new configuration is published (just beforeinit()
is called). It is also called when theinit()
call fails.
The UsernamePasswordMechanism
class is a convenience class that
can be sub-classed to create authentication method plug-ins that implement a
simple username/password authentication.
The MechanismServer
class holds information about an Authentication Server
for an authentication method. A list of MechanismServer
instances is provided in the AuthenticationMechanismConfiguration
object sent to the init() method. Each MechanismServer
object holds
a list of MechanismConfiguration
instances
The MechanismConfiguration
class holds key and value pairs for an
authentication method. A list of MechanismConfiguration
instances is provided in the AuthenticationMechanismConfiguration
object sent to the init() method.
The MechanismReply
class holds the reply state for an
authentication method. A list of MechanismReply
instances is provided in the AuthenticationMechanismConfiguration
object sent to the init() method.