public class SftpPasswordAuthentication extends java.lang.Object implements SftpAuthenticationProvider
SftpAuthenticationProvider
using a password.In the adapter configuration file this class is aliased as sftp-password-authentication which is the preferred alternative to the fully qualified classname when building your configuration.
Constructor and Description |
---|
SftpPasswordAuthentication() |
SftpPasswordAuthentication(java.lang.String pw) |
Modifier and Type | Method and Description |
---|---|
SftpClient |
connect(SftpClient sftp,
FileTransferConnection.UserInfo ui) |
java.lang.String |
getDefaultPassword()
Get the password.
|
void |
setDefaultPassword(java.lang.String s)
Set the default password (supports encoded passwords).
|
public SftpPasswordAuthentication()
public SftpPasswordAuthentication(java.lang.String pw)
public SftpClient connect(SftpClient sftp, FileTransferConnection.UserInfo ui) throws FileTransferException, java.io.IOException, PasswordException
connect
in interface SftpAuthenticationProvider
FileTransferException
java.io.IOException
PasswordException
public java.lang.String getDefaultPassword()
public void setDefaultPassword(java.lang.String s)
s
- the password to be used if not overridden as part of the destination.Password.MSCAPI_STYLE
,
Password.NON_PORTABLE_PASSWORD
,
Password.PORTABLE_PASSWORD