Trying to catch login exception when password expires in IPlanet
Hi all
I am running Weblogic 8.1 and I am trying to write a logon web client.
I am using the IPlanet Authentication Provider. We would like to
implement the password expiration on the LDAP server. The logon client
works fine for a successful logon, throws a FailedLoginException with an
invalid username/password, throws a LoginException with to many failed
logon attempts. When I test an expired password, it should throw an
AccountExpiredException but the logon succeeds. Is their something else
I need to do? I can get this to work with the IPlanet API. Code is
below. Thanks.
try {
CallbackHandler handler = new URLCallbackHandler(username,
password);
Subject mySubject = Authentication.login(handler);
} catch (CredentialExpiredException e) {
errors.add(ActionErrors.GLOBAL_ERROR, new
ActionError("error.login.credentialexpired"));
} catch (AccountExpiredException e) {
errors.add(ActionErrors.GLOBAL_ERROR, new
ActionError("error.login.passwordexpired"));
} catch (FailedLoginException e) {
errors.add(ActionErrors.GLOBAL_ERROR, new
ActionError("error.login.invalidusernamepassword"));
} catch (LoginException e) {
errors.add(ActionErrors.GLOBAL_ERROR, new
ActionError("error.login.lockout",e.getLocalizedMessage()));
}
Re: Trying to catch login exception when password expires in IPlanet
<sotto@sddpc.org> wrote in message news:3ffeffd2@newsgroups.bea.com...[color=blue]
> Hi all
>
> I am running Weblogic 8.1 and I am trying to write a logon web client.
> I am using the IPlanet Authentication Provider. We would like to
> implement the password expiration on the LDAP server. The logon client
> works fine for a successful logon, throws a FailedLoginException with an
> invalid username/password, throws a LoginException with to many failed
> logon attempts. When I test an expired password, it should throw an
> AccountExpiredException but the logon succeeds. Is their something else
> I need to do? I can get this to work with the IPlanet API. Code is
> below. Thanks.
>
>[/color]
The LDAP provider binds to the external LDAP server. It sounds like the ldap
server
is not throwing an exception. Are you sure the password has expired?
I would turn on DebugSecurityAtn="true" attribute in the ServerDebug Mbean
and then
look at the ldap_trace.log file for the results from the bind operation.
You could also use an ldap browser and try the bind operation outside of WLS
and see
if you get the error result for the expired password error.
Re: Trying to catch login exception when password expires in IPlanet
Hi,
How I configure weblogic expiration password in weblogic 9.2?
Thanks all.