org.jboss.security
Class SimpleServerLoginModule
java.lang.Object
|
+--org.jboss.security.SimpleServerLoginModule
- All Implemented Interfaces:
- javax.security.auth.spi.LoginModule
- public class SimpleServerLoginModule
- extends java.lang.Object
- implements javax.security.auth.spi.LoginModule
This server login module implements the following simple algorithm:
if password is null, authenticate the user and assign the "guest" role
else if password is equal to the user name, assign both "user" and "guest" roles
else don't authenticate.
Method Summary |
boolean |
abort()
Method to abort the authentication process (phase 2). |
boolean |
commit()
Method to commit the authentication process (phase 2). |
void |
initialize(javax.security.auth.Subject subject,
javax.security.auth.callback.CallbackHandler callbackHandler,
java.util.Map sharedState,
java.util.Map options)
Initialize this LoginModule. |
boolean |
login()
Method to authenticate a Subject (phase 1). |
boolean |
logout()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SimpleServerLoginModule
public SimpleServerLoginModule()
initialize
public void initialize(javax.security.auth.Subject subject,
javax.security.auth.callback.CallbackHandler callbackHandler,
java.util.Map sharedState,
java.util.Map options)
- Initialize this LoginModule.
- Specified by:
initialize
in interface javax.security.auth.spi.LoginModule
login
public boolean login()
throws javax.security.auth.login.LoginException
- Method to authenticate a Subject (phase 1).
- Specified by:
login
in interface javax.security.auth.spi.LoginModule
commit
public boolean commit()
throws javax.security.auth.login.LoginException
- Method to commit the authentication process (phase 2).
- Specified by:
commit
in interface javax.security.auth.spi.LoginModule
abort
public boolean abort()
throws javax.security.auth.login.LoginException
- Method to abort the authentication process (phase 2).
- Specified by:
abort
in interface javax.security.auth.spi.LoginModule
logout
public boolean logout()
throws javax.security.auth.login.LoginException
- Specified by:
logout
in interface javax.security.auth.spi.LoginModule
Copyright © 2000 The jBoss Organization. All Rights Reserved.