transport

package
v0.3.8 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2022 License: MIT Imports: 9 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Options

type Options struct {
	// TLSVerify is the same as !InsecureSkipVerify in tls.Config
	TLSVerify bool
	// Certs is a list of TLS certificates to use
	Certs []tls.Certificate
	// Timeout is the maximum time for new connections
	Timeout time.Duration
}

Options is a struct which contains options for initializing a T.

type T

type T struct{ *http.Transport }

T is a complete Wireleap network transport which can dial to other wireleap-relays via H/2 over TCP and targets via TCP or UDP.

func New

func New(opts Options) *T

New creates a default T with the supplied options.

func (*T) DialWL

func (t *T) DialWL(c0 net.Conn, protocol string, remote *url.URL, payload *wlnet.Init) (c net.Conn, err error)

DialWL creates a new connection to relay or target.

Jump to

Keyboard shortcuts

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