com.tagish.auth
Class BasicLogin
java.lang.Object
|
+--com.tagish.auth.BasicLogin
- All Implemented Interfaces:
- javax.security.auth.spi.LoginModule
- Direct Known Subclasses:
- NTSystemLogin, SimpleLogin
- public abstract class BasicLogin
- extends Object
- implements javax.security.auth.spi.LoginModule
Superclass for all the com.tagish.auth.* authorisation modules. Provides
utility methods for reading the module's configuration options and a
default implementation of initialize() that fetches the value of a boolean
option called 'debug'.
- Version:
- 1.0.3
- Author:
- Andy Armstrong, andy@tagish.com
Method Summary |
protected boolean |
getOption(String name,
boolean dflt)
Get a boolean option from the module's options. |
protected int |
getOption(String name,
int dflt)
Get a numeric option from the module's options. |
protected String |
getOption(String name,
String dflt)
Get a String option from the module's options. |
void |
initialize(javax.security.auth.Subject subject,
javax.security.auth.callback.CallbackHandler callbackHandler,
Map sharedState,
Map options)
Module initialization. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface javax.security.auth.spi.LoginModule |
abort, commit, login, logout |
subject
protected javax.security.auth.Subject subject
callbackHandler
protected javax.security.auth.callback.CallbackHandler callbackHandler
sharedState
protected Map sharedState
options
protected Map options
debug
protected boolean debug
BasicLogin
public BasicLogin()
initialize
public void initialize(javax.security.auth.Subject subject,
javax.security.auth.callback.CallbackHandler callbackHandler,
Map sharedState,
Map options)
- Module initialization.
- Specified by:
initialize
in interface javax.security.auth.spi.LoginModule
getOption
protected boolean getOption(String name,
boolean dflt)
- Get a boolean option from the module's options.
- Parameters:
name
- Name of the optiondflt
- Default value for the option- Returns:
- The boolean value of the options object.
getOption
protected int getOption(String name,
int dflt)
- Get a numeric option from the module's options.
- Parameters:
name
- Name of the optiondflt
- Default value for the option- Returns:
- The boolean value of the options object.
getOption
protected String getOption(String name,
String dflt)
- Get a String option from the module's options.
- Parameters:
name
- Name of the optiondflt
- Default value for the option- Returns:
- The String value of the options object.