Class Application
- java.lang.Object
-
- com.sun.identity.authentication.spi.AMLoginModule
-
- com.sun.identity.authentication.modules.application.Application
-
- All Implemented Interfaces:
LoginModule
public class Application extends AMLoginModule
Application login module. This is used to authenticate agents and users of ssoadm.Use
IDToken0to specify application name andIDToken1to specify secret. (Old usage :Login.Token0to specify application name andLogin.Token1to specify secret.) For example:"module=Application&IDToken0=UrlAccessAgent&IDToken1=secret"
OR"module=Application&IDToken0=
Old usage:&IDToken1= " "module=Application&Login.Token0=UrlAccessAgent&Login.Token1=secret"
-
-
Field Summary
-
Fields inherited from class com.sun.identity.authentication.spi.AMLoginModule
amCache, auditor, currentState
-
-
Constructor Summary
Constructors Constructor Description Application()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddestroyModuleState()This method should be overridden by each login module to destroy dispensable state fields.PrincipalgetPrincipal()Returns Principal for the authenticated user.voidinit(Subject subject, Map sharedState, Map options)Initialize this LoginModule.voidnullifyUsedVars()This method should be overridden by each login module to do some garbage collection work after the module process is done.intprocess(Callback[] callbacks, int state)Implementation ofAMLoginModuleabstract method.-
Methods inherited from class com.sun.identity.authentication.spi.AMLoginModule
abort, clearInfoText, commit, createIdentity, forceCallbacksInit, getAMIdentityRepository, getAttribute, getAuditEntryDetail, getAuthenticatedPrincipals, getAuthLevel, getCallback, getCallback, getCallbackHandler, getCurrentState, getFailCount, getHttpServletRequest, getHttpServletResponse, getInfoText, getLocale, getLoginLocale, getLoginState, getMaximumFailCount, getNewUserIDs, getNumberOfStates, getOrgProfile, getOrgServiceTemplate, getPwdKey, getRequestOrg, getServiceConfig, getSessionId, getSSOSession, getUserAliasList, getUserKey, getUserProfile, getUserSessionProperty, getUserSessions, incrementFailCount, initialize, isAccountLocked, isDynamicProfileCreationEnabled, isRequired, isSessionQuotaReached, isSharedStateEnabled, isSuperAdmin, isUseFirstPassEnabled, isValidUserEntry, login, logout, replaceCallback, replaceHeader, resetCallback, resetCurrentState, setAuthLevel, setFailureID, setForceCallbacksRead, setLoginFailureURL, setLoginSuccessURL, setModuleErrorTemplate, setOrg, setSharedStateEnabled, setUserAttributes, setUserSessionProperty, storeUsername, storeUsernamePasswd, substituteHeader, substituteInfoText, validatePassword, validateUserName
-
-
-
-
Method Detail
-
init
public void init(Subject subject, Map sharedState, Map options)
Description copied from class:AMLoginModuleInitialize this LoginModule.This is an abstract method, must be implemented by user's Login Module to initialize this LoginModule with the relevant information. If this LoginModule does not understand any of the data stored in sharedState or options parameters, they can be ignored.
- Specified by:
initin classAMLoginModule- Parameters:
subject- - the Subject to be authenticated.sharedState- - state shared with other configured LoginModules.options- - options specified in the login Configuration for this particular LoginModule. 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.
-
process
public int process(Callback[] callbacks, int state) throws AuthLoginException
Implementation ofAMLoginModuleabstract method. Refer toAMLoginModulefor method syntax.- Specified by:
processin classAMLoginModule- Parameters:
callbacks- Callback[] for this Login statestate- Order of state. State order starts with 1.- Returns:
- order of next state. return -1 if authentication is successful, return 0 if the LoginModule should be ignored.
- Throws:
AuthLoginException
-
getPrincipal
public Principal getPrincipal()
Returns Principal for the authenticated user.- Specified by:
getPrincipalin classAMLoginModule- Returns:
- Principal for the authenticated user or null if authentication did not succeed.
-
destroyModuleState
public void destroyModuleState()
Description copied from class:AMLoginModuleThis method should be overridden by each login module to destroy dispensable state fields.- Overrides:
destroyModuleStatein classAMLoginModule
-
nullifyUsedVars
public void nullifyUsedVars()
Description copied from class:AMLoginModuleThis method should be overridden by each login module to do some garbage collection work after the module process is done. Typically those class wide global variables that will not be used again until a logout call should be nullified.- Overrides:
nullifyUsedVarsin classAMLoginModule
-
-