org.jboss.security.auth.spi
Class MemoryUsersRolesLoginModule

java.lang.Object
  extended by org.jboss.security.auth.spi.AbstractServerLoginModule
      extended by org.jboss.security.auth.spi.UsernamePasswordLoginModule
          extended by org.jboss.security.auth.spi.UsersRolesLoginModule
              extended by org.jboss.security.auth.spi.MemoryUsersRolesLoginModule
All Implemented Interfaces:
LoginModule

public class MemoryUsersRolesLoginModule
extends UsersRolesLoginModule

A subclass of UsersRolesLoginModule that uses a singleton instance and memory based users/roles Properties maps to manage user/password and user/role mappings. These maps need to be specified via the login module options.

Version:
$Revision: 1.1.2.1 $
Author:
Scott.Stark@jboss.org

Field Summary
 
Fields inherited from class org.jboss.security.auth.spi.AbstractServerLoginModule
callbackHandler, log, loginOk, options, principalClassName, sharedState, subject, unauthenticatedIdentity, useFirstPass
 
Constructor Summary
MemoryUsersRolesLoginModule()
           
 
Method Summary
protected  Properties createRoles(Map options)
          Provide the users map obtained during initialize
protected  Properties createUsers(Map options)
          Provide the users map obtained during initialize
 void initialize(Subject subject, CallbackHandler callbackHandler, Map sharedState, Map options)
          Override the UsersRolesLoginModule initialize to look for a users and roles options specifying the
 
Methods inherited from class org.jboss.security.auth.spi.UsersRolesLoginModule
getRoleSets, getUsersPassword, loadRoles, loadUsers, login, parseGroupMembers
 
Methods inherited from class org.jboss.security.auth.spi.UsernamePasswordLoginModule
createPasswordHash, getCredentials, getIdentity, getUnauthenticatedIdentity, getUsername, getUsernameAndPassword, getValidateError, setValidateError, validatePassword
 
Methods inherited from class org.jboss.security.auth.spi.AbstractServerLoginModule
abort, commit, createGroup, createIdentity, getUseFirstPass, logout
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MemoryUsersRolesLoginModule

public MemoryUsersRolesLoginModule()
Method Detail

initialize

public void initialize(Subject subject,
                       CallbackHandler callbackHandler,
                       Map sharedState,
                       Map options)
Override the UsersRolesLoginModule initialize to look for a users and roles options specifying the

Specified by:
initialize in interface LoginModule
Overrides:
initialize in class UsersRolesLoginModule
Parameters:
subject -
callbackHandler -
sharedState -
options -

createUsers

protected Properties createUsers(Map options)
Provide the users map obtained during initialize

Overrides:
createUsers in class UsersRolesLoginModule
Parameters:
options - - the login module options passed to initialize
Returns:
the users login module option value

createRoles

protected Properties createRoles(Map options)
                          throws IOException
Provide the users map obtained during initialize

Overrides:
createRoles in class UsersRolesLoginModule
Parameters:
options - - the login module options passed to initialize
Returns:
the users login module option value
Throws:
IOException - - thrown on failure to load the properties


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.