I need to administratively change passwords from a java app, and as I
have not found a nice Java API for this yet, I am shelling to the MIT
kadmin binary. I am essentially shelling: kadmin -q "change_password
-pw " This works very well, but if the
change_password fails (for example, a non-existent principal), I still
get a return code of zero. Is there a simple way (without coding a
Java JNI wrapper, and if possible, without parsing stdout/stderr) for
me to determine the exit status of the change_password action?

Is anyone aware of a Java API for this process, preferably FOSS?

Thank you,