com.sptci.auth
Class DatabaseLoginModule
java.lang.Object
com.sptci.auth.AbstractLoginModule
com.sptci.auth.DatabaseLoginModule
- All Implemented Interfaces:
- LoginModule
public class DatabaseLoginModule
- extends AbstractLoginModule
JAAS login module for user authentication through user information
stored in a database table.
© Copyright 2007 Sans Pareil Technologies, Inc.
- Version:
- $Id: DatabaseLoginModule.java 4553 2008-12-24 10:34:16Z rakesh $
- Author:
- Nikhil 2007-08-02
|
Method Summary |
protected boolean |
checkPassword(String userName,
char[] password,
char[] key)
Check the specified credentials against the data store. |
boolean |
login()
Attempts to authenticate the subject against data stored in a
database (JDO compliant relational or object data stores). |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DatabaseLoginModule
public DatabaseLoginModule()
login
public boolean login()
throws LoginException
- Attempts to authenticate the subject against data stored in a
database (JDO compliant relational or object data stores).
- Throws:
LoginException- See Also:
LoginModule.login()
checkPassword
protected boolean checkPassword(String userName,
char[] password,
char[] key)
throws LoginException
- Check the specified credentials against the data store.
- Parameters:
userName - The user/login name to check.password - The password to check.key - The key to use to decrypt the stored password.
- Returns:
- Return
true if the specified credentials match.
- Throws:
LoginException - If errors are encountered while fetching the
data from the data store.