protected int showAuthenticationPrompt(SshAuthenticationClient instance)
throws IOException {
instance.setUsername(getCurrentConnectionProfile().getUsername());
if (instance instanceof PasswordAuthenticationClient) {
PasswordAuthenticationDialog dialog = new PasswordAuthenticationDialog((Frame) SwingUtilities.getAncestorOfClass(
Frame.class, SshToolsApplicationClientPanel.this));
instance.setAuthenticationPrompt(dialog);
((PasswordAuthenticationClient) instance).setPasswordChangePrompt(PasswordChange.getInstance());
PasswordChange.getInstance().setParentComponent(SshToolsApplicationClientPanel.this);
} else if (instance instanceof PublicKeyAuthenticationClient) {