public abstract class AuthLoginModule extends Object
Constructor and Description |
---|
AuthLoginModule() |
Modifier and Type | Method and Description |
---|---|
String |
getAuthenticatingUserName()
|
CallbackHandler |
getCallbackHandler()
Returns the CallbackHandler object for the module.
|
javax.servlet.http.HttpServletRequest |
getHttpServletRequest()
Returns the HttpServletRequest object that initiated the call to this module.
|
javax.servlet.http.HttpServletResponse |
getHttpServletResponse()
Returns the HttpServletResponse object for the servlet request that initiated the call to this module.
|
abstract Principal |
getPrincipal()
Abstract method must be implemented by each login module to get the user Principal.
|
String |
getRequestOrg()
Returns the organization DN for this authentication session.
|
abstract void |
init(Subject subject,
Map sharedState,
Map options)
Initialize this AuthLoginModule.
|
abstract int |
process(Callback[] callbacks,
int state)
Abstract method must be implemented by each login module to control the flow of the login process.
|
void |
setAMLoginModule(AMLoginModuleBinder amLoginModuleBinder)
Constructs an instance of the AuthLoginModule.
|
void |
setAuthenticatingUserName(String userName)
|
void |
setUserSessionProperty(String name,
String value)
Sets a property in the user session.
|
public void setAMLoginModule(AMLoginModuleBinder amLoginModuleBinder)
amLoginModuleBinder
- An instance of the AMLoginModuleBinder.public abstract void init(Subject subject, Map sharedState, Map options)
This is an abstract method, must be implemented by user's Login Module to initialize this AuthLoginModule with the relevant information. If this AuthLoginModule does not understand any of the data stored in sharedState or options parameters, they can be ignored.
subject
- The Subject to be authenticated.sharedState
- The state shared with other configured LoginModules.options
- The options specified in the login Configuration for this particular AuthLoginModule. It contains
all the global and organization attribute configuration for this module. The key of the map is the
attribute name (e.g. iplanet-am-auth-ldap-server
) as String, the value is the value
of the corresponding attribute as Set.public abstract int process(Callback[] callbacks, int state) throws LoginException
This method takes an array of submitted Callback, process them and decide the order of next state to go. Return -1 if the login is successful, return 0 if the AuthLoginModule should be ignored.
callbacks
- The array of Callbacks for this Login state.state
- The order of state. State order starts with 1.LoginException
- If the login process fails.public abstract Principal getPrincipal()
public CallbackHandler getCallbackHandler()
public javax.servlet.http.HttpServletRequest getHttpServletRequest()
public javax.servlet.http.HttpServletResponse getHttpServletResponse()
public String getRequestOrg()
public void setUserSessionProperty(String name, String value) throws AuthLoginException
name
- The property name.value
- The property value.AuthLoginException
- If the user session is invalid.public void setAuthenticatingUserName(String userName)
public String getAuthenticatingUserName()
Copyright © 2010–2025 Open Identity Platform Community. All rights reserved.