Description
There is a known "issue" with the Jsch library and Java 1.7, in that it prompts for a kerberos username and password (which are then ignored if other credentials have already been supplied). This doesn't stop the Ant ssh tasks from working, but it does stop them from being completely automated (e.g. scripts invoked by a CI server like Jenkins)
The workaround is either of two:
- Move back to Java 1.6
- Use old enough Jsch version (0.1.31 seems to be ok).
Jsch author, Atsuhiko Yamanaka, suggests to configure Jsch Session as following to avoid the issue:
session.setConfig("PreferredAuthentications", "publickey,keyboard-interactive,password");