Movatterモバイル変換


[0]ホーム

URL:


tshttpproxy

package
v1.92.2Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2025 License:BSD-3-ClauseImports:19Imported by:32

Details

Repository

github.com/tailscale/tailscale

Links

Documentation

Overview

Package tshttpproxy contains Tailscale additions to httpproxy not availablein golang.org/x/net/http/httpproxy. Notably, it aims to support Windows better.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

funcGetAuthHeader

func GetAuthHeader(u *url.URL) (string,error)

GetAuthHeader returns the Authorization header value to send to proxy u.

funcInvalidateCache

func InvalidateCache()

InvalidateCache invalidates the package-level cache for ProxyFromEnvironment.

It's intended to be called on network link/routing table changes.

funcProxyFromEnvironment

func ProxyFromEnvironment(req *http.Request) (ret *url.URL, _error)

ProxyFromEnvironment is like the standard library's http.ProxyFromEnvironmentbut additionally does OS-specific proxy lookups if the environment variablesalone don't specify a proxy.

funcSetProxyFuncadded inv1.88.0

func SetProxyFunc(fn func(*url.URL) (*url.URL,error))error

SetProxyFunc can be used by clients to set a platform-specific function for proxy resolution.If config is set when this function is called, an error will be returned.The provided function should return a proxy URL for the given request URL,nil if no proxy is enabled for the request URL, or an error if proxy settings cannot be resolved.

funcSetSelfProxyadded inv1.40.0

func SetSelfProxy(addrs ...string)

SetSelfProxy configures this package to avoid proxying through any of theprovided addresses–e.g. if they refer to proxies being run by this process.

funcSetTransportGetProxyConnectHeader

func SetTransportGetProxyConnectHeader(tr *http.Transport)

SetTransportGetProxyConnectHeader sets the provided Transport'sGetProxyConnectHeader field, and adds logging of the received response.

Types

This section is empty.

Source Files

View all Source files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f orF : Jump to
y orY : Canonical URL
go.dev uses cookies from Google to deliver and enhance the quality of its services and to analyze traffic.Learn more.

[8]ページ先頭

©2009-2025 Movatter.jp