proxy

package module
v0.0.0-...-4c5a6f4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 19, 2017 License: Apache-2.0 Imports: 9 Imported by: 0

README

socks5-proxy

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func StartTestSSHServer

func StartTestSSHServer(httpServerURL, sshPrivateKey string) string

Types

type DialFunc

type DialFunc func(network, address string) (net.Conn, error)

type HostKeyGetter

type HostKeyGetter struct {
	// contains filtered or unexported fields
}

func NewHostKeyGetter

func NewHostKeyGetter() HostKeyGetter

func (HostKeyGetter) Get

func (h HostKeyGetter) Get(key, serverURL string) (ssh.PublicKey, error)

type KeyGetter

type KeyGetter interface {
	Get(string, string) (ssh.PublicKey, error)
}

type Proxy

type Proxy interface {
	Start(string, string) error
	Addr() (string, error)
}

type Socks5Proxy

type Socks5Proxy struct {
	// contains filtered or unexported fields
}

func NewSocks5Proxy

func NewSocks5Proxy(hostKeyGetter KeyGetter) *Socks5Proxy

func (*Socks5Proxy) Addr

func (s *Socks5Proxy) Addr() (string, error)

func (*Socks5Proxy) Dialer

func (s *Socks5Proxy) Dialer(key, url string) (DialFunc, error)

func (*Socks5Proxy) Start

func (s *Socks5Proxy) Start(key, url string) error

func (*Socks5Proxy) StartWithDialer

func (s *Socks5Proxy) StartWithDialer(dialer DialFunc) error

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL