Bhardwaj, Ashutosh wrote:
I am trying to customize the login process.
My requirement is :
* In request I get a user id.(no password)
* I check if this id exists in db, if not show an error page.
* if the user id exists the authenticate user in jetspeed portal
with a default password
* If authentication fails add the user and then authenticate.
For doing this I have written My own login module and testing it using
the default Login Portlet that ships with jetspeed by giving an empty
password.
The code is somehat like :
========================================================================
====================================
public boolean login() throws LoginException {
if (callbackHandler == null) {
throw new LoginException("Error: no
CallbackHandler available "
+ "to garner authentication
information from the user");
}
try {
// Setup default callback handlers.
Callback[] callbacks = new Callback[] {
new NameCallback("Username: ")
};
callbackHandler.handle(callbacks);
username = ((NameCallback)
callbacks[0]).getName();
refreshProxy();
success = ums.authenticate(this.username,
this.username);
Is "ums" the Jetspeed User Manager or your own User Manager?
I am assuming its your own User Manager.
Are you aware that Jetspeed also has a Login Module, and that all Login
Modules are called during the authentication process?
Most likely the Jetspeed Login Module is failing.
If you do NOT want to use the Jetspeed Login Module, then you will need
to disable it by removing the login.conf from the security jar.
This will not fully integrate your security system into Jetspeed, but
lets see how far that gets you...
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]