Versions in this module Expand all Collapse all v1 v1.0.1 Jul 5, 2023 Changes in this version + const DefaultPort + const DefaultUsername + const KeyboardInteractiveName + const PasswordCallbackName + const PasswordName + const PublicKeysCallbackName + const PublicKeysName + var DefaultAuthBuilder = func(user string) (AuthMethod, error) + var DefaultClient = NewClient(nil) + var DefaultSSHConfig sshConfig = ssh_config.DefaultUserSettings + func NewClient(config *ssh.ClientConfig) transport.Transport + func NewKnownHostsCallback(files ...string) (ssh.HostKeyCallback, error) + type AuthMethod interface + ClientConfig func() (*ssh.ClientConfig, error) + type HostKeyCallbackHelper struct + HostKeyCallback ssh.HostKeyCallback + func (m *HostKeyCallbackHelper) SetHostKeyCallback(cfg *ssh.ClientConfig) (*ssh.ClientConfig, error) + type KeyboardInteractive struct + Challenge ssh.KeyboardInteractiveChallenge + User string + func (a *KeyboardInteractive) ClientConfig() (*ssh.ClientConfig, error) + func (a *KeyboardInteractive) Name() string + func (a *KeyboardInteractive) String() string + type Password struct + Password string + User string + func (a *Password) ClientConfig() (*ssh.ClientConfig, error) + func (a *Password) Name() string + func (a *Password) String() string + type PasswordCallback struct + Callback func() (pass string, err error) + User string + func (a *PasswordCallback) ClientConfig() (*ssh.ClientConfig, error) + func (a *PasswordCallback) Name() string + func (a *PasswordCallback) String() string + type PublicKeys struct + Signer ssh.Signer + User string + func NewPublicKeys(user string, pemBytes []byte, password string) (*PublicKeys, error) + func NewPublicKeysFromFile(user, pemFile, password string) (*PublicKeys, error) + func (a *PublicKeys) ClientConfig() (*ssh.ClientConfig, error) + func (a *PublicKeys) Name() string + func (a *PublicKeys) String() string + type PublicKeysCallback struct + Callback func() (signers []ssh.Signer, err error) + User string + func NewSSHAgentAuth(u string) (*PublicKeysCallback, error) + func (a *PublicKeysCallback) ClientConfig() (*ssh.ClientConfig, error) + func (a *PublicKeysCallback) Name() string + func (a *PublicKeysCallback) String() string