Search code examples
javaibm-midrangejtopen

Expired password change fails


I am using JTOpen API to access an AS400 system.

I can successfully change an active AS400 user password like this:

AS400 system = new AS400("AS400SYSTEM", "AS400USER");
system.changePassword("OLDPASSWORD", "NEWPASSWORD");

On the other hand, when I try to change an expired user password in the same way I get the following exception thrown from the 2nd line:

com.ibm.as400.access.AS400SecurityException: Password is incorrect.

What do I need to do first?


Solution

  • Yes the user was not disabled (enabled then :P) only the password was expired.

    As it turned out the problem was that the first character of the new password was numeric. AS400 console doesn't like that at all...

    http://search400.techtarget.com/answer/Setting-iSeries-passwords

    Thanks!