Documentation
¶
Index ¶
- type SshTunnel
- type SshTunnelDialer
- func (d *SshTunnelDialer) Close() error
- func (d *SshTunnelDialer) Dial(network, address string) (net.Conn, error)
- func (d *SshTunnelDialer) DialContext(ctx context.Context, network, address string) (net.Conn, error)
- func (d *SshTunnelDialer) DialTimeout(network, address string, timeout time.Duration) (net.Conn, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SshTunnel ¶
type SshTunnel struct {
Host string
Port int
User string
// PrivateKeys are the keys offered to the server, most preferred first. SSH
// public-key auth tries them in order and the server accepts the first one
// it trusts, so a caller rotating its key can offer the new key alongside
// the one it replaces and no handshake breaks while the server's
// authorized_keys is being updated.
//
// Offer only the keys that are still meant to work: OpenSSH counts every
// attempt against MaxAuthTries (6 by default) and drops the connection once
// it is exhausted, so a long list of retired keys can fail a handshake the
// first entry would have completed.
PrivateKeys [][]byte
Timeout time.Duration
}
type SshTunnelDialer ¶
type SshTunnelDialer struct {
// contains filtered or unexported fields
}
func NewSshTunnelDialer ¶
func NewSshTunnelDialer(tunnel *SshTunnel) (*SshTunnelDialer, error)
func (*SshTunnelDialer) Close ¶
func (d *SshTunnelDialer) Close() error
func (*SshTunnelDialer) Dial ¶
func (d *SshTunnelDialer) Dial(network, address string) (net.Conn, error)
func (*SshTunnelDialer) DialContext ¶
func (*SshTunnelDialer) DialTimeout ¶
Click to show internal directories.
Click to hide internal directories.