Class Application

  • All Implemented Interfaces:
    LoginModule

    public class Application
    extends AMLoginModule
    Application login module. This is used to authenticate agents and users of ssoadm.

    Use IDToken0 to specify application name and IDToken1 to specify secret. (Old usage : Login.Token0 to specify application name and Login.Token1 to specify secret.) For example:

     "module=Application&IDToken0=UrlAccessAgent&IDToken1=secret"
     
    OR
     "module=Application&IDToken0=&IDToken1=
         "
     
    Old usage:
     "module=Application&Login.Token0=UrlAccessAgent&Login.Token1=secret"
     
    • Constructor Detail

      • Application

        public Application()
    • Method Detail

      • init

        public void init​(Subject subject,
                         Map sharedState,
                         Map options)
        Description copied from class: AMLoginModule
        Initialize 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:
        init in class AMLoginModule
        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 of AMLoginModule abstract method. Refer to AMLoginModule for method syntax.
        Specified by:
        process in class AMLoginModule
        Parameters:
        callbacks - Callback[] for this Login state
        state - 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:
        getPrincipal in class AMLoginModule
        Returns:
        Principal for the authenticated user or null if authentication did not succeed.
      • destroyModuleState

        public void destroyModuleState()
        Description copied from class: AMLoginModule
        This method should be overridden by each login module to destroy dispensable state fields.
        Overrides:
        destroyModuleState in class AMLoginModule
      • nullifyUsedVars

        public void nullifyUsedVars()
        Description copied from class: AMLoginModule
        This 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:
        nullifyUsedVars in class AMLoginModule