public class JDBCLoginModule extends AbstractDatabaseLoginModule
JAAS LoginModule to retrieve user information from a database and authenticate the user.
This version uses plain old JDBC connections NOT Datasources.
AbstractLoginModule.JAASUserInfo
Constructor and Description |
---|
JDBCLoginModule() |
Modifier and Type | Method and Description |
---|---|
Connection |
getConnection()
Get a connection from the DriverManager
|
void |
initialize(Subject subject,
CallbackHandler callbackHandler,
Map<String,?> sharedState,
Map<String,?> options)
Init LoginModule.
|
getUserInfo
abort, commit, configureCallbacks, getCallbackHandler, getCurrentUser, getSubject, isAuthenticated, isCommitted, isIgnored, login, logout, setAuthenticated, setCallbackHandler, setCommitted, setCurrentUser, setSubject
public Connection getConnection() throws Exception
getConnection
in class AbstractDatabaseLoginModule
Exception
AbstractDatabaseLoginModule.getConnection()
public void initialize(Subject subject, CallbackHandler callbackHandler, Map<String,?> sharedState, Map<String,?> options)
initialize
in interface LoginModule
initialize
in class AbstractDatabaseLoginModule
subject
- callbackHandler
- sharedState
- options
- LoginModule.initialize(javax.security.auth.Subject, javax.security.auth.callback.CallbackHandler, java.util.Map, java.util.Map)
Copyright © 1995-2015 Webtide. All Rights Reserved.