| IBM WebSphere Extended Deployment (XD)TM
Release 6.0.1 |
java.lang.Object
|
+--com.ibm.websphere.objectgrid.security.plugins.builtins.LDAPLoginModule
This LDAPLoginModule authenticates a user with a password to the configured LDAP server.
A login configuration should provide at least the following two options:
Here is a Login module configuration example used by the sample LDAPAuthenticator:
LDAPLogin {
com.ibm.websphere.objectgrid.security.plugins.builtins.LDAPLoginModule required
providerURL="ldap://bluepages.ibm.com:389/"
factoryClass="com.sun.jndi.ldap.LdapCtxFactory"
debug=true;
};
The providerURL points to the IBM bluepages LDAP server with the port number
389. The initial context factory is com.sun.jndi.ldap.LdapCtxFactory.
LoginModule
Field Summary | |
---|---|
public String | PROVIDER_URL
|
public String | FACTORY_CLASS
|
Constructor Summary | |
---|---|
LDAPLoginModule()
|
Method Summary | |
---|---|
public
void | initialize(javax.security.auth.Subject, javax.security.auth.callback.CallbackHandler, java.util.Map, java.util.Map)
Initialize this LoginModule ..
|
public
boolean | login()
Authenticate the user by a user name and password..
|
public
boolean | commit()
This method is called if the LoginContext's overall authentication succeeded (the relevant REQUIRED, REQUISITE, SUFFICIENT and OPTIONAL LoginModules succeeded). |
public
boolean | abort()
This method is called if the LoginContext's overall authentication failed. |
public
boolean | logout()
Logout the user..
|
Methods inherited from java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static PROVIDER_URL
public static FACTORY_CLASS
Constructor Detail |
public LDAPLoginModule( | ) |
Method Detail |
public void initialize( | Subject _subject , | CallbackHandler _callbackHandler ,
| Map _sharedState ,
| Map _options )
|
LoginModule
.
_subject
-
the Subject
to be authenticated.
_callbackHandler
-
a CallbackHandler
for communicating
with the end user (prompting for user names and
passwords, for example).
_sharedState
-
shared LoginModule
state.
_options
-
options specified in the login
Configuration
for this particular
LoginModule
.
public boolean login( | ) |
LoginModule
should not be ignored.
javax.security.auth.login.FailedLoginExceptionjavax.security.auth.login.LoginException
public boolean commit( | ) |
This method is called if the LoginContext's overall authentication succeeded (the relevant REQUIRED, REQUISITE, SUFFICIENT and OPTIONAL LoginModules succeeded).
If this LoginModule's own authentication attempt
succeeded (checked by retrieving the private state saved by the
login
method), then this method associates a
SamplePrincipal
with the Subject
located in the
LoginModule
. If this LoginModule's own
authentication attempted failed, then this method removes
any state that was originally saved.
javax.security.auth.login.LoginException
public boolean abort( | ) |
This method is called if the LoginContext's overall authentication failed. (the relevant REQUIRED, REQUISITE, SUFFICIENT and OPTIONAL LoginModules did not succeed).
If this LoginModule's own authentication attempt
succeeded (checked by retrieving the private state saved by the
login
and commit
methods),
then this method cleans up any state that was originally saved.
javax.security.auth.login.LoginException
public boolean logout( | ) |
This method removes the SamplePrincipal
that was added by the commit
method.
LoginModule
should not be ignored.
javax.security.auth.login.LoginException
| IBM WebSphere Extended Deployment (XD)TM
Release 6.0.1 |