add this to your session session.setConfig( "PreferredAuthentications", "keyboard-interactive,password");