proxyclient

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2019 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetURLScheme

func GetURLScheme(rawURL string) (string, error)

GetURLScheme returns the scheme of a URL

Types

type AuthMethod

type AuthMethod struct {
	Type   string            `yaml:"type"`
	Params map[string]string `yaml:"params"`
}

AuthMethod represent a method to authenticate with a proxy

type PreparedRequest

type PreparedRequest struct {
	Client   *http.Client
	Request  *http.Request
	ProxyURL *url.URL
}

PreparedRequest contains everything needed to make a request through a proxy

func MakeClientAndRequest

func MakeClientAndRequest(target string, proxy string, auth *AuthMethod, insecure bool) (*PreparedRequest, error)

MakeClientAndRequest prepares a client and a request

Jump to

Keyboard shortcuts

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