proxy

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2016 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler func(r *http.Request, ctx *goproxy.ProxyCtx) (*http.Request, *http.Response)

type Proxy

type Proxy struct {
	*goproxy.ProxyHttpServer
	// contains filtered or unexported fields
}

func NewProxy

func NewProxy(proxyHandler Handler, caKeyPath, caCertPath string, trustedCertificatePaths []string) (*Proxy, error)

func NewReverseProxy

func NewReverseProxy(proxyHandler Handler) (*Proxy, error)

func (*Proxy) Serve

func (proxy *Proxy) Serve(listenAddr, crtFile, keyFile string, shutdownTimeout time.Duration) error

func (*Proxy) Stop

func (proxy *Proxy) Stop() <-chan struct{}

Jump to

Keyboard shortcuts

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